This does not relate directly to Tunnelblick, as I experience this
issue on Windows OpenVPN clients, too. But I've become familiar with
this community, so I figured I'd see if anyone here knows what I'm
doing wrong.
I have a server set up with TAP and DHCP. I can connect to the server
just fine (on Windows clients I get an address automatically ... with
Tunnelblick I have to issue the command "sudo ipconfig set tap0 DHCP"
until that bug is fixed completely). The subnet for the VPN is
172.16.122.0/24. The server is also set up to push a route to a
different subnet behind the VPN (
192.168.122.0/24). Neither the
Windows nor the Mac OS X clients get the route, and OpenVPN complains
about not having a route-gateway. Here is the server configuration:
/usr/sbin/openvpn --daemon --verb 3 --writepid /var/run/openvpn-
vtun0.pid --status /opt/vyatta/etc/openvpn/status/vtun0.status 30 --
dev-type tap --dev vtun0 --mode server --tls-server --topology subnet
--keepalive 10 60 --ca /root/openvpn/keys/ca.crt --cert /root/openvpn/
keys/server.crt --key /root/openvpn/keys/server.key --dh /root/openvpn/
keys/dh1024.pem --push dhcp-option DNS 172.16.122.1 --push route
192.168.122.0 255.255.255.0 --server-bridge --client-config-dir /opt/
vyatta/etc/openvpn/ccd/vtun0 --comp-lzo --push dhcp-option DOMAIN
nickhq.com
And the client configuration:
client
dev tap
proto udp
remote ___ 1194
resolv-retry infinite
nobind
persist-key
persist-tun
ca ___.crt
cert __.crt
key ___.key
ns-cert-type server
comp-lzo
verb 3
The full log output is at the bottom. The items that stick out to me
are:
2011-05-01 14:45:19 PUSH: Received control message: 'PUSH_REPLY,dhcp-
option DNS 172.16.122.1,route 192.168.122.0 255.255.255.0,dhcp-option
DOMAIN
nickhq.com,route-gateway dhcp,ping 10,ping-restart 60'
2011-05-01 14:45:19 OPTIONS IMPORT: route options modified
2011-05-01 14:45:19 ROUTE default_gateway=10.0.1.1
2011-05-01 14:45:19 OpenVPN ROUTE: OpenVPN needs a gateway parameter
for a --route option and no default was specified by either --route-
gateway or --ifconfig options
2011-05-01 14:45:19 OpenVPN ROUTE: failed to parse/resolve route for
host/network: 192.168.122.0
I've done some Googling and everyone seems to agree that this means
I'm not including a route-gateway command. But as you can clearly see
in the PUSH reply, I'm sending "route-gateway dhcp."
Any ideas as to why I can't push this route? I was able to
successfully push the route when I was using TUN, but when I switched
to TAP with DHCP, I can no longer push it.
Thanks,
Nick
2011-05-01 14:45:15 *Tunnelblick: OS X 10.6.7; Tunnelblick 3.2beta10
(build 2466); OpenVPN 2.2.0
2011-05-01 14:45:15 *Tunnelblick: Attempting connection with ___; Set
nameserver = 1; monitoring connection
2011-05-01 14:45:15 *Tunnelblick: /Applications/Tunnelblick.app/
Contents/Resources/openvpnstart start ___.tblk 1337 1 0 3 0 114
2011-05-01 14:45:15 *Tunnelblick: openvpnstart: /Applications/
Tunnelblick.app/Contents/Resources/openvpn --cd /Library/Application
Support/Tunnelblick/Shared/___.tblk/Contents/Resources --daemon --
management 127.0.0.1 1337 --config /Library/Application Support/
Tunnelblick/Shared/___.tblk/Contents/Resources/config.ovpn --log /
Library/Application Support/Tunnelblick/Logs/-SLibrary-SApplication
Support-STunnelblick-SShared-S___.tblk-SContents-SResources-
Sconfig.ovpn.1_0_3_0_114.1337.openvpn.log --management-query-passwords
--management-hold --script-security 2 --up /Applications/
Tunnelblick.app/Contents/Resources/
client.up.tunnelblick.sh -m -w -d -
a --down /Applications/Tunnelblick.app/Contents/Resources/
client.down.tunnelblick.sh -m -w -d -a --up-restart
2011-05-01 14:45:16 OpenVPN 2.2.0 i386-apple-darwin10.7.3 [SSL] [LZO2]
[PKCS11] [eurephia] built on Apr 28 2011
2011-05-01 14:45:16 MANAGEMENT: TCP Socket listening on
127.0.0.1:1337
2011-05-01 14:45:16 Need hold release from management interface,
waiting...
2011-05-01 14:45:16 MANAGEMENT: Client connected from
127.0.0.1:1337
2011-05-01 14:45:16 MANAGEMENT: CMD 'pid'
2011-05-01 14:45:16 MANAGEMENT: CMD 'state on'
2011-05-01 14:45:16 MANAGEMENT: CMD 'state'
2011-05-01 14:45:16 MANAGEMENT: CMD 'hold release'
2011-05-01 14:45:16 NOTE: the current --script-security setting may
allow this configuration to call user-defined scripts
2011-05-01 14:45:16 LZO compression initialized
2011-05-01 14:45:16 Control Channel MTU parms [ L:1574 D:138 EF:38 EB:
0 ET:0 EL:0 ]
2011-05-01 14:45:16 Socket Buffers: R=[42080->65536] S=[9216->65536]
2011-05-01 14:45:16 MANAGEMENT: >STATE:1304279116,RESOLVE,,,
2011-05-01 14:45:16 *Tunnelblick: Established communication with
OpenVPN
2011-05-01 14:45:16 Data Channel MTU parms [ L:1574 D:1450 EF:42 EB:
135 ET:32 EL:0 AF:3/1 ]
2011-05-01 14:45:16 Local Options hash (VER=V4): 'd79ca330'
2011-05-01 14:45:16 Expected Remote Options hash (VER=V4): 'f7df56b8'
2011-05-01 14:45:16 UDPv4 link local: [undef]
2011-05-01 14:45:16 UDPv4 link remote: ___:1194
2011-05-01 14:45:16 MANAGEMENT: >STATE:1304279116,WAIT,,,
2011-05-01 14:45:16 MANAGEMENT: >STATE:1304279116,AUTH,,,
2011-05-01 14:45:16 TLS: Initial packet from ___:1194, sid=49ce516e
4391cbf5
2011-05-01 14:45:16 VERIFY OK: depth=1, /C=US/ST=TN/L=___/O=___/CN=___/
name=___/emailAddress=___
2011-05-01 14:45:16 VERIFY OK: nsCertType=SERVER
2011-05-01 14:45:16 VERIFY OK: depth=0, /C=US/ST=TN/L=___/O=___/
CN=server/name=___/emailAddress=___
2011-05-01 14:45:17 Data Channel Encrypt: Cipher 'BF-CBC' initialized
with 128 bit key
2011-05-01 14:45:17 Data Channel Encrypt: Using 160 bit message hash
'SHA1' for HMAC authentication
2011-05-01 14:45:17 Data Channel Decrypt: Cipher 'BF-CBC' initialized
with 128 bit key
2011-05-01 14:45:17 Data Channel Decrypt: Using 160 bit message hash
'SHA1' for HMAC authentication
2011-05-01 14:45:17 Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-
AES256-SHA, 1024 bit RSA
2011-05-01 14:45:17 [server] Peer Connection Initiated with ___:1194
2011-05-01 14:45:18 MANAGEMENT: >STATE:1304279118,GET_CONFIG,,,
2011-05-01 14:45:19 SENT CONTROL [server]: 'PUSH_REQUEST' (status=1)
2011-05-01 14:45:19 PUSH: Received control message: 'PUSH_REPLY,dhcp-
option DNS 172.16.122.1,route 192.168.122.0 255.255.255.0,dhcp-option
DOMAIN
nickhq.com,route-gateway dhcp,ping 10,ping-restart 60'
2011-05-01 14:45:19 OPTIONS IMPORT: timers and/or timeouts modified
2011-05-01 14:45:19 OPTIONS IMPORT: route options modified
2011-05-01 14:45:19 OPTIONS IMPORT: route-related options modified
2011-05-01 14:45:19 OPTIONS IMPORT: --ip-win32 and/or --dhcp-option
options modified
2011-05-01 14:45:19 ROUTE default_gateway=10.0.1.1
2011-05-01 14:45:19 OpenVPN ROUTE: OpenVPN needs a gateway parameter
for a --route option and no default was specified by either --route-
gateway or --ifconfig options
2011-05-01 14:45:19 OpenVPN ROUTE: failed to parse/resolve route for
host/network: 192.168.122.0
2011-05-01 14:45:19 TUN/TAP device /dev/tap0 opened
2011-05-01 14:45:19 /Applications/Tunnelblick.app/Contents/Resources/
client.up.tunnelblick.sh -m -w -d -a tap0 1500 1574 init
No such key
2011-05-01 14:45:19 Initialization Sequence Completed
2011-05-01 14:45:19 MANAGEMENT: >STATE:
1304279119,CONNECTED,SUCCESS,,___
2011-05-01 14:45:19 *Tunnelblick
client.up.tunnelblick.sh: Up to two
'No such key' warnings are normal and may be ignored
2011-05-01 14:45:19 *Tunnelblick
client.up.tunnelblick.sh: Saved the
DNS and WINS configurations for later use
2011-05-01 14:45:19 *Tunnelblick
client.up.tunnelblick.sh: Set up to
monitor system configuration with leasewatch
2011-05-01 14:45:20 *Tunnelblick: Flushed the DNS cache
2011-05-01 14:45:27 Extracted DHCP router address: 172.16.122.1
2011-05-01 14:45:31 *Tunnelblick leasewatch: A system configuration
change was ignored because it was not relevant
2011-05-01 14:45:41 *Tunnelblick leasewatch: A system configuration
change was ignored because it was not relevant