SYSTEM WARNING: 'date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone.' in '/usr/share/mantis/www/core.php' line 264

0004396: openvpnbridge.py: error: Invalid ip or netmask - MantisBT Endian Bugtracker
Endian Issue Tracker





Please see now our new Bugtracker system: JIRA








View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004396Endian FirewallOpenVPN Client and Serverpublic2012-07-20 12:342012-08-08 14:29
Reporterardit-endian 
Assigned Toandrea-endian 
PrioritynormalSeveritymajorReproducibilityhave not tried
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version2.4 
Target VersionFixed in Version2.5 
Summary0004396: openvpnbridge.py: error: Invalid ip or netmask
DescriptionWhen using tun in openvpngw2gw with endian as Client server this is shown on the log:



Jul 20 14:29:07 efw tix[6483]: Fri Jul 20 14:29:07 2012 event_wait : Interrupted system call (code=4)
Jul 20 14:29:07 efw tix[6483]: Fri Jul 20 14:29:07 2012 /usr/local/bin/dir.d-exec /etc/openvpn/ifdown.client.d/ openvpntun0 1500 1542 172.17.67.6 172.17.67.5 init
Jul 20 14:29:07 efw tix[6483]: usage: openvpnbridge.py <options> <device> <mtu> <mru> <local_ip> <local_netmask|remote_ip> [init|restart]
Jul 20 14:29:07 efw tix[6483]:
Jul 20 14:29:07 efw tix[6483]: openvpnbridge.py: error: Invalid ip or netmask '172.17.67.6 172.17.67.5'
Jul 20 14:29:07 efw tix[6483]: run-parts: /etc/openvpn/ifdown.client.d//00bridge exited with return code 2
Jul 20 14:29:07 efw tix[6483]: Fri Jul 20 14:29:07 2012 /sbin/ip addr del dev openvpntun0 local 172.17.67.6 peer 172.17.67.5


Not knowing the code noticed however something that may cause this issue:

 except ValueError:
        debug(traceback.format_exc())
        parser.error("Invalid ip or netmask '%s %s'"%(ip, mask))

should the "mask" be there?
as the script is expeting ip,mask but it's pushed '172.17.67.6 172.17.67.5'
Tagspurple
Attached Files

- Relationships

-  Notes
(0007998)
andrea-endian (developer)
2012-08-08 12:15
edited on: 2012-08-08 12:38

According to the OpenVPN documentation, for tun, the openvpnbridge script is execute with the following parameters:
tun_dev tun_mtu link_mtu ifconfig_local_ip ifconfig_remote_ip [ init | restart ]

For tap, the parameters are:
tap_dev tap_mtu link_mtu ifconfig_local_ip ifconfig_netmask [ init | restart ]

openvpnbridge.py accepts both the tun/tap parameters:
usage: openvpnbridge.py <options> <device> <mtu> <mru> <local_ip> <local_netmask|remote_ip> [init|restart]

When I disconnect the client, the script is called with the following parameters:
--remove openvpntun0 1500 1542 192.168.100.2 255.255.255.0 init

(0007999)
andrea-endian (developer)
2012-08-08 14:29

Fixed in 2.5, 2.4-arm and 2.4

- Issue History
Date Modified Username Field Change
2012-07-20 12:34 ardit-endian New Issue
2012-07-20 12:34 ardit-endian Tag Attached: purple
2012-08-08 12:15 andrea-endian Note Added: 0007998
2012-08-08 12:38 andrea-endian Note Edited: 0007998
2012-08-08 14:28 andrea-endian Assigned To => andrea-endian
2012-08-08 14:29 andrea-endian Note Added: 0007999
2012-08-08 14:29 andrea-endian Status new => resolved
2012-08-08 14:29 andrea-endian Fixed in Version => 2.5
2012-08-08 14:29 andrea-endian Resolution open => fixed

Copyright © 2005-2008 Endian, SRL. All rights reserved.


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker