vath
Why does every user get 10.8.0.6 for when they connect?
I have OpenVPN running on a Windows 7 box. I can connect from a remote location and see files on the machine. There are separate cert/keys for each user, with one ca.crt on the server. But when I connect a second machine, I get the same subnet IP as the first user connection: 10.8.0.6:
server console/log looks like:
x.x.x.x:63215 TLS: Initial packet from [AF_INET]x.x.x.x:63215, sid=ec616bb1 e9c29a7c
x.x.x.x:63215 VERIFY OK: depth=1, C=US, ST=x, L=x, O=x, OU=x, CN=server, name=x, emailAddress=x
x.x.x.x:63215 VERIFY OK: depth=0, C=US, ST=x, L=x, O=x, OU=x, CN=server, name=x, emailAddress=x
x.x.x.x:63215 Data Channel Encrypt: Cipher 'BF-CBC' initialized with 128 bit key
x.x.x.x:63215 Data Channel Encrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
x.x.x.x:63215 Data Channel Decrypt: Cipher 'BF-CBC' initialized with 128 bit key
x.x.x.x:63215 Data Channel Decrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
x.x.x.x:63215 Control Channel: TLSv1.2, cipher TLSv1/SSLv3 DHE-RSA-AES256-GCM-SHA384, 1024 bit RSA
x.x.x.x:63215 [server] Peer Connection Initiated with [AF_INET]x.x.x.x:63215
server/x.x.x.x:63215 MULTI_sva: pool returned IPv4=10.8.0.6, IPv6=(Not enabled)
server/x.x.x.x:63215 MULTI: Learn: 10.8.0.6 -> server/x.x.x.x:63215
server/x.x.x.x:63215 MULTI: primary virtual IP for server/x.x.x.x:63215: 10.8.0.6
server/x.x.x.x:63215 PUSH: Received control message: 'PUSH_REQUEST'
server/x.x.x.x:63215 send_push_reply(): safe_cap=940
server/x.x.x.x:63215 SENT CONTROL [server]: 'PUSH_REPLY,?route-metric 512?,?route 0.0.0.0 0.0.0.0?,route 10.8.0.1,topology net30,ping 10,ping-restart 120,ifconfig 10.8.0.6 10.8.0.5' (status=1)
server/x.x.x.x:63215 [server] Inactivity timeout (--ping-restart), restarting
server/x.x.x.x:63215 SIGUSR1[soft,ping-restart] received, client-instance restarting
I followed https://community.openvpn.net/openvpn/wiki/Easy_Windows_Guide to get it working. The only changes being from http://asktheoracle.com/blog/how-to-make-openvpn-work-with-the-windows-7-firewall/
port 1194
proto udp
dev tun
ca "C:\\Program Files\\OpenVPN\\config\\ca.crt"
cert "C:\\Program Files\\OpenVPN\\config\\server.crt"
key "C:\\Program Files\\OpenVPN\\config\\server.key"
dh "C:\\Program Files\\OpenVPN\\config\\dh1024.pem"
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
keepalive 10 120
comp-lzo
max-clients 6
persist-key
persist-tun
status openvpn-status.log
verb 3
push “route-metric 512”
push “route 0.0.0.0 0.0.0.0”
client
dev tun
proto udp
remote x.x.x.x 1194
float
resolv-retry infinite
nobind
persist-key
persist-tun
ca "C:\\Program Files\\OpenVPN\\config\\ca.crt"
cert "C:\\Program Files\\OpenVPN\\config\\x.crt"
key "C:\\Program Files\\OpenVPN\\config\\x.key"
remote-cert-tls server
comp-lzo
verb 3