Hi to all,
I need to route all traffic to an ip through my vpn. I see outbound request packets to vpn server but I get no response.
I try also with a public websites ip instead of the ip i'dlike to reach in order to exclude firewalls or other filters on the destination ip.
I try also to enable all traffic through vpn (as described here
https://openvpn.net/community-resources/how-to/#routing-all-client-traffic-including-web-traffic-through-the-vpn) but no work also, i can't reach any website.
I replaced username with "vpnuser", server ip with "serverIpAddress", domain name with "domainName".
Server config:
server 192.168.255.0 255.255.255.0
verb 6
key /etc/openvpn/pki/private/domainName.key
ca /etc/openvpn/pki/ca.crt
cert /etc/openvpn/pki/issued/domainName.crt
dh /etc/openvpn/pki/dh.pem
tls-auth /etc/openvpn/pki/ta.key
key-direction 0
keepalive 10 60
persist-key
persist-tun
#Logs
status /etc/openvpn/logs/openvpn-status.log
log /etc/openvpn/logs/openvpn.log
proto udp
port 1194
dev tun0
user nobody
group nogroup
### Route Configurations Below
route 192.168.254.0 255.255.255.0
## Test with single ip www.mio-ip.it
push "route 116.203.39.239"
## Test with all traffic through vpn
#push "redirect-gateway def1"
Client config:
client
nobind
dev tun
remote-cert-tls server
remote domainName 1194 udp
<cert>
-----BEGIN CERTIFICATE-----
-----END CERTIFICATE-----
</cert>
<ca>
-----BEGIN CERTIFICATE-----
-----END CERTIFICATE-----
</ca>
key-direction 1
Server openvpn logs:
Tue Sep 3 09:14:41 2019 us=102358 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:14:41 2019 us=132577 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:14:51 2019 us=183384 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:14:51 2019 us=183460 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:01 2019 us=294409 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:01 2019 us=294479 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:11 2019 us=413883 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:11 2019 us=413983 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:21 2019 us=425333 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:21 2019 us=605378 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:31 2019 us=661471 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:31 2019 us=742766 vpnuser/serverIpAddress:50452 UDPv4 READ [40] from [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:41 2019 us=781105 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:15:51 2019 us=826340 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:02 2019 us=61135 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:12 2019 us=297576 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:22 2019 us=474377 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:32 2019 us=500211 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:42 2019 us=798997 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:16:52 2019 us=844284 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:17:02 2019 us=943292 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:17:12 2019 us=251099 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:17:22 2019 us=342287 vpnuser/serverIpAddress:50452 UDPv4 WRITE [40] to [AF_INET]serverIpAddress:50452: P_DATA_V2 kid=0 DATA len=39
Tue Sep 3 09:17:31 2019 us=383036 vpnuser/serverIpAddress:50452 [vpnuser] Inactivity timeout (--ping-restart), restarting
Tue Sep 3 09:17:31 2019 us=383072 vpnuser/serverIpAddress:50452 SIGUSR1[soft,ping-restart] received, client-instance restarting
Tue Sep 3 09:17:41 2019 us=352137 MULTI: multi_create_instance called
Tue Sep 3 09:17:41 2019 us=352199 serverIpAddress:60738 Re-using SSL/TLS context
Tue Sep 3 09:17:41 2019 us=352278 serverIpAddress:60738 Control Channel MTU parms [ L:1621 D:1184 EF:66 EB:0 ET:0 EL:3 ]
Tue Sep 3 09:17:41 2019 us=352289 serverIpAddress:60738 Data Channel MTU parms [ L:1621 D:1450 EF:121 EB:406 ET:0 EL:3 ]
Tue Sep 3 09:17:41 2019 us=352334 serverIpAddress:60738 Local Options String (VER=V4): 'V4,dev-type tun,link-mtu 1541,tun-mtu 1500,proto UDPv4,keydir 0,cipher BF-CBC,auth SHA1,keysize 128,tls-auth,key-method 2,tls-server'
Tue Sep 3 09:17:41 2019 us=352354 serverIpAddress:60738 Expected Remote Options String (VER=V4): 'V4,dev-type tun,link-mtu 1541,tun-mtu 1500,proto UDPv4,keydir 1,cipher BF-CBC,auth SHA1,keysize 128,tls-auth,key-method 2,tls-client'
Tue Sep 3 09:17:41 2019 us=352384 serverIpAddress:60738 UDPv4 READ [42] from [AF_INET]serverIpAddress:60738: P_CONTROL_HARD_RESET_CLIENT_V2 kid=0 pid=[ #1 ] [ ] pid=0 DATA len=0
Tue Sep 3 09:17:41 2019 us=352399 serverIpAddress:60738 TLS: Initial packet from [AF_INET]serverIpAddress:60738, sid=8e0eed1e 03cf3dbb
Tue Sep 3 09:17:41 2019 us=352429 serverIpAddress:60738 UDPv4 WRITE [54] to [AF_INET]serverIpAddress:60738: P_CONTROL_HARD_RESET_SERVER_V2 kid=0 pid=[ #1 ] [ 0 ] pid=0 DATA len=0
Tue Sep 3 09:17:41 2019 us=383605 serverIpAddress:60738 UDPv4 READ [50] from [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #2 ] [ 0 ]
Tue Sep 3 09:17:41 2019 us=572205 serverIpAddress:60738 UDPv4 READ [215] from [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #3 ] [ ] pid=1 DATA len=173
Tue Sep 3 09:17:41 2019 us=574090 serverIpAddress:60738 UDPv4 WRITE [1172] to [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #2 ] [ 1 ] pid=1 DATA len=1118
Tue Sep 3 09:17:41 2019 us=574207 serverIpAddress:60738 UDPv4 WRITE [1145] to [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #3 ] [ ] pid=2 DATA len=1103
Tue Sep 3 09:17:41 2019 us=692384 serverIpAddress:60738 UDPv4 READ [50] from [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #4 ] [ 1 ]
Tue Sep 3 09:17:41 2019 us=711001 serverIpAddress:60738 UDPv4 READ [1172] from [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #5 ] [ 2 ] pid=2 DATA len=1118
Tue Sep 3 09:17:41 2019 us=711131 serverIpAddress:60738 UDPv4 WRITE [50] to [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #4 ] [ 2 ]
Tue Sep 3 09:17:41 2019 us=711211 serverIpAddress:60738 UDPv4 READ [1000] from [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #6 ] [ ] pid=3 DATA len=958
Tue Sep 3 09:17:41 2019 us=711627 serverIpAddress:60738 VERIFY OK: depth=1, CN=domus.vpn
Tue Sep 3 09:17:41 2019 us=711796 serverIpAddress:60738 VERIFY OK: depth=0, CN=vpnuser
Tue Sep 3 09:17:41 2019 us=712319 serverIpAddress:60738 UDPv4 WRITE [105] to [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #5 ] [ 3 ] pid=3 DATA len=51
Tue Sep 3 09:17:41 2019 us=743074 serverIpAddress:60738 UDPv4 READ [459] from [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #7 ] [ 3 ] pid=4 DATA len=405
Tue Sep 3 09:17:41 2019 us=743147 serverIpAddress:60738 peer info: IV_VER=2.4.3
Tue Sep 3 09:17:41 2019 us=743161 serverIpAddress:60738 peer info: IV_PLAT=mac
Tue Sep 3 09:17:41 2019 us=743169 serverIpAddress:60738 peer info: IV_PROTO=2
Tue Sep 3 09:17:41 2019 us=743176 serverIpAddress:60738 peer info: IV_NCP=2
Tue Sep 3 09:17:41 2019 us=743183 serverIpAddress:60738 peer info: IV_LZ4=1
Tue Sep 3 09:17:41 2019 us=743190 serverIpAddress:60738 peer info: IV_LZ4v2=1
Tue Sep 3 09:17:41 2019 us=743197 serverIpAddress:60738 peer info: IV_LZO=1
Tue Sep 3 09:17:41 2019 us=743204 serverIpAddress:60738 peer info: IV_COMP_STUB=1
Tue Sep 3 09:17:41 2019 us=743211 serverIpAddress:60738 peer info: IV_COMP_STUBv2=1
Tue Sep 3 09:17:41 2019 us=743218 serverIpAddress:60738 peer info: IV_TCPNL=1
Tue Sep 3 09:17:41 2019 us=743281 serverIpAddress:60738 UDPv4 WRITE [293] to [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #6 ] [ 4 ] pid=4 DATA len=239
Tue Sep 3 09:17:41 2019 us=774347 serverIpAddress:60738 UDPv4 READ [50] from [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #8 ] [ 4 ]
Tue Sep 3 09:17:41 2019 us=774407 serverIpAddress:60738 Control Channel: TLSv1.2, cipher TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384, 2048 bit RSA
Tue Sep 3 09:17:41 2019 us=774435 serverIpAddress:60738 [vpnuser] Peer Connection Initiated with [AF_INET]serverIpAddress:60738
Tue Sep 3 09:17:41 2019 us=774470 vpnuser/serverIpAddress:60738 MULTI_sva: pool returned IPv4=192.168.255.6, IPv6=(Not enabled)
Tue Sep 3 09:17:41 2019 us=774534 vpnuser/serverIpAddress:60738 MULTI: Learn: 192.168.255.6 -> vpnuser/serverIpAddress:60738
Tue Sep 3 09:17:41 2019 us=774550 vpnuser/serverIpAddress:60738 MULTI: primary virtual IP for vpnuser/serverIpAddress:60738: 192.168.255.6
Tue Sep 3 09:17:42 2019 us=916973 vpnuser/serverIpAddress:60738 UDPv4 READ [84] from [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #9 ] [ ] pid=5 DATA len=42
Tue Sep 3 09:17:42 2019 us=917051 vpnuser/serverIpAddress:60738 PUSH: Received control message: 'PUSH_REQUEST'
Tue Sep 3 09:17:42 2019 us=917092 vpnuser/serverIpAddress:60738 SENT CONTROL [vpnuser]: 'PUSH_REPLY,route 116.203.39.239,route 192.168.255.1,topology net30,ping 10,ping-restart 60,ifconfig 192.168.255.6 192.168.255.5,peer-id 0,cipher AES-256-GCM' (status=1)
Tue Sep 3 09:17:42 2019 us=917101 vpnuser/serverIpAddress:60738 Data Channel: using negotiated cipher 'AES-256-GCM'
Tue Sep 3 09:17:42 2019 us=917122 vpnuser/serverIpAddress:60738 Data Channel MTU parms [ L:1549 D:1450 EF:49 EB:406 ET:0 EL:3 ]
Tue Sep 3 09:17:42 2019 us=917209 vpnuser/serverIpAddress:60738 Outgoing Data Channel: Cipher 'AES-256-GCM' initialized with 256 bit key
Tue Sep 3 09:17:42 2019 us=917218 vpnuser/serverIpAddress:60738 Incoming Data Channel: Cipher 'AES-256-GCM' initialized with 256 bit key
Tue Sep 3 09:17:42 2019 us=917242 vpnuser/serverIpAddress:60738 UDPv4 WRITE [50] to [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #7 ] [ 5 ]
Tue Sep 3 09:17:42 2019 us=917389 vpnuser/serverIpAddress:60738 UDPv4 WRITE [249] to [AF_INET]serverIpAddress:60738: P_CONTROL_V1 kid=0 pid=[ #8 ] [ ] pid=5 DATA len=207
Tue Sep 3 09:17:43 2019 us=4348 vpnuser/serverIpAddress:60738 UDPv4 READ [50] from [AF_INET]serverIpAddress:60738: P_ACK_V1 kid=0 pid=[ #10 ] [ 5 ]
Server logs:
+ set -e
+ cd /etc/openvpn
+ USER_ARGS=("${@}")
+ ARGS=()
+ addArg --config /etc/openvpn/openvpn.conf
+ local arg=--config
+ '[' 2 -ge 1 ']'
+ local val=/etc/openvpn/openvpn.conf
+ hasArg --config
+ local element
+ return 1
+ ARGS+=("${arg}")
+ '[' 2 -ge 1 ']'
+ ARGS+=("${val}")
+ source /etc/openvpn/ovpn_env.sh
++ declare -x OVPN_AUTH=
++ declare -x OVPN_CIPHER=
++ declare -x OVPN_CLIENT_TO_CLIENT=
++ declare -x OVPN_CN=domainName
++ declare -x OVPN_COMP_LZO=0
++ declare -x OVPN_DEFROUTE=1
++ declare -x OVPN_DEVICE=tun
++ declare -x OVPN_DEVICEN=0
++ declare -x OVPN_DISABLE_PUSH_BLOCK_DNS=0
++ declare -x OVPN_DNS=1
++ OVPN_DNS_SERVERS=([0]="8.8.8.8" [1]="8.8.4.4")
++ declare -x OVPN_DNS_SERVERS
++ declare -x OVPN_ENV=/etc/openvpn/ovpn_env.sh
++ OVPN_EXTRA_CLIENT_CONFIG=()
++ declare -x OVPN_EXTRA_CLIENT_CONFIG
++ OVPN_EXTRA_SERVER_CONFIG=()
++ declare -x OVPN_EXTRA_SERVER_CONFIG
++ declare -x OVPN_FRAGMENT=
++ declare -x 'OVPN_KEEPALIVE=10 60'
++ declare -x OVPN_MTU=
++ declare -x OVPN_NAT=0
++ declare -x OVPN_PORT=1194
++ declare -x OVPN_PROTO=udp
++ OVPN_PUSH=()
++ declare -x OVPN_PUSH
++ OVPN_ROUTES=([0]="192.168.254.0/24")
++ declare -x OVPN_ROUTES
++ declare -x OVPN_SERVER=192.168.255.0/24
++ declare -x OVPN_SERVER_URL=udp://domainName
++ declare -x OVPN_TLS_CIPHER=
+ mkdir -p /dev/net
+ '[' '!' -c /dev/net/tun ']'
+ mknod /dev/net/tun c 10 200
+ '[' -d /etc/openvpn/ccd ']'
+ '[' -z '' ']'
+ OVPN_NATDEVICE=eth0
+ '[' 1 '!=' 0 ']'
+ setupIptablesAndRouting
+ iptables -t nat -C POSTROUTING -s 192.168.255.0/24 -o eth0 -j MASQUERADE
iptables: No chain/target/match by that name.
+ iptables -t nat -A POSTROUTING -s 192.168.255.0/24 -o eth0 -j MASQUERADE
+ for i in "${OVPN_ROUTES[@]}"
+ iptables -t nat -C POSTROUTING -s 192.168.254.0/24 -o eth0 -j MASQUERADE
iptables: No chain/target/match by that name.
+ iptables -t nat -A POSTROUTING -s 192.168.254.0/24 -o eth0 -j MASQUERADE
+ '[' /etc/openvpn/pki/crl.pem -nt /etc/openvpn/crl.pem ']'
+ '[' -r /etc/openvpn/crl.pem ']'
+ addArg --crl-verify /etc/openvpn/crl.pem
+ local arg=--crl-verify
+ '[' 2 -ge 1 ']'
+ local val=/etc/openvpn/crl.pem
+ hasArg --crl-verify
+ local element
+ return 1
+ ARGS+=("${arg}")
+ '[' 2 -ge 1 ']'
+ ARGS+=("${val}")
+ ip -6 route show default
+ '[' 0 = 0 ']'
+ echo 'Enabling IPv6 Forwarding'
Enabling IPv6 Forwarding
+ sysctl -w net.ipv6.conf.all.disable_ipv6=0
sysctl: error setting key 'net.ipv6.conf.all.disable_ipv6': Read-only file system
+ echo 'Failed to enable IPv6 support'
Failed to enable IPv6 support
+ sysctl -w net.ipv6.conf.default.forwarding=1
sysctl: error setting key 'net.ipv6.conf.default.forwarding': Read-only file system
+ echo 'Failed to enable IPv6 Forwarding default'
Failed to enable IPv6 Forwarding default
+ sysctl -w net.ipv6.conf.all.forwarding=1
sysctl: error setting key 'net.ipv6.conf.all.forwarding': Read-only file system
+ echo 'Failed to enable IPv6 Forwarding'
Failed to enable IPv6 Forwarding
+ echo 'Running '\''openvpn --config' /etc/openvpn/openvpn.conf --crl-verify '/etc/openvpn/crl.pem '\'''
Running 'openvpn --config /etc/openvpn/openvpn.conf --crl-verify /etc/openvpn/crl.pem '
+ exec openvpn --config /etc/openvpn/openvpn.conf --crl-verify /etc/openvpn/crl.pem
Client logs:
Tue Sep 3 11:17:41 2019 OpenVPN 2.4.3 x86_64-apple-darwin16.6.0 [SSL (OpenSSL)] [LZO] [LZ4] [MH/RECVDA] [AEAD] built on Jun 23 2017
Tue Sep 3 11:17:41 2019 library versions: OpenSSL 1.0.2l 25 May 2017, LZO 2.10
Tue Sep 3 11:17:41 2019 NOTE: the current --script-security setting may allow this configuration to call user-defined scripts
Tue Sep 3 11:17:41 2019 Outgoing Control Channel Authentication: Using 160 bit message hash 'SHA1' for HMAC authentication
Tue Sep 3 11:17:41 2019 Incoming Control Channel Authentication: Using 160 bit message hash 'SHA1' for HMAC authentication
Tue Sep 3 11:17:41 2019 TCP/UDP: Preserving recently used remote address: [AF_INET]serverIpAddress:1194
Tue Sep 3 11:17:41 2019 UDP link local: (not bound)
Tue Sep 3 11:17:41 2019 UDP link remote: [AF_INET]serverIpAddress:1194
Tue Sep 3 11:17:41 2019 VERIFY SCRIPT OK: depth=1, CN=domus.vpn
Tue Sep 3 11:17:41 2019 VERIFY OK: depth=1, CN=domus.vpn
Tue Sep 3 11:17:41 2019 VERIFY KU OK
Tue Sep 3 11:17:41 2019 Validating certificate extended key usage
Tue Sep 3 11:17:41 2019 ++ Certificate has EKU (str) TLS Web Server Authentication, expects TLS Web Server Authentication
Tue Sep 3 11:17:41 2019 VERIFY EKU OK
Tue Sep 3 11:17:41 2019 VERIFY SCRIPT OK: depth=0, CN=domainName
Tue Sep 3 11:17:41 2019 VERIFY OK: depth=0, CN=domainName
Tue Sep 3 11:17:41 2019 Control Channel: TLSv1.2, cipher TLSv1/SSLv3 ECDHE-RSA-AES256-GCM-SHA384, 2048 bit RSA
Tue Sep 3 11:17:41 2019 [domainName] Peer Connection Initiated with [AF_INET]serverIpAddress:1194
Tue Sep 3 11:17:42 2019 Data Channel: using negotiated cipher 'AES-256-GCM'
Tue Sep 3 11:17:42 2019 Data Channel Encrypt: Cipher 'AES-256-GCM' initialized with 256 bit key
Tue Sep 3 11:17:42 2019 Data Channel Decrypt: Cipher 'AES-256-GCM' initialized with 256 bit key
Tue Sep 3 11:17:42 2019 Opening utun (connect(AF_SYS_CONTROL)): Resource busy
Tue Sep 3 11:17:42 2019 Opened utun device utun1
Tue Sep 3 11:17:42 2019 do_ifconfig, tt->did_ifconfig_ipv6_setup=0
Tue Sep 3 11:17:42 2019 /sbin/ifconfig utun1 delete
ifconfig: ioctl (SIOCDIFADDR): Can't assign requested address
Tue Sep 3 11:17:42 2019 NOTE: Tried to delete pre-existing tun/tap instance -- No Problem if failure
Tue Sep 3 11:17:42 2019 /sbin/ifconfig utun1 192.168.255.6 192.168.255.5 mtu 1500 netmask 255.255.255.255 up
Tue Sep 3 11:17:42 2019 /tmp/pritunl/518cdfe78a1b218dff8d9c234251ea38-up.sh utun1 1500 1552 192.168.255.6 192.168.255.5 init
add net 116.203.39.239: gateway 192.168.255.5
add net 192.168.255.1: gateway 192.168.255.5
Tue Sep 3 11:17:42 2019 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
Tue Sep 3 11:17:42 2019 Initialization Sequence Completed
Client routing table:
Routing tables
Internet:
Destination Gateway Flags Refs Use Netif Expire
default 10.10.10.1 UGSc 87 9 en0
10.10.10/26 link#5 UCS 2 0 en0 !
10.10.10.1/32 link#5 UCS 1 0 en0 !
10.10.10.1 64:59:f8:79:47:90 UHLWIir 37 20 en0 1173
10.10.10.13 b8:27:eb:7f:dd:39 UHLWI 0 21 en0 1194
10.10.10.14/32 link#5 UCS 0 0 en0 !
10.10.10.15 44:d9:e7:5:dd:1 UHLWI 0 266 en0 1172
116.203.39.239/32 192.168.255.5 UGSc 0 0 utun1
127 127.0.0.1 UCS 0 0 lo0
127.0.0.1 127.0.0.1 UH 49 2773618 lo0
169.254 link#5 UCS 0 0 en0 !
192.168.255.1/32 192.168.255.5 UGSc 0 0 utun1
192.168.255.5 192.168.255.6 UH 3 0 utun1
224.0.0/4 link#5 UmCS 2 0 en0 !
224.0.0.251 1:0:5e:0:0:fb UHmLWI 0 0 en0
239.255.255.250 1:0:5e:7f:ff:fa UHmLWI 0 288 en0
255.255.255.255/32 link#5 UCS 0 0 en0 !
Server ip route:
ip route
default via 169.254.1.1 dev eth0
169.254.1.1 dev eth0 scope link
192.168.254.0/24 via 192.168.255.2 dev tun0
192.168.255.0/24 via 192.168.255.2 dev tun0
192.168.255.2 dev tun0 proto kernel scope link src 192.168.255.1
Server route:
route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 169.254.1.1 0.0.0.0 UG 0 0 0 eth0
169.254.1.1 * 255.255.255.255 UH 0 0 0 eth0
192.168.254.0 192.168.255.2 255.255.255.0 UG 0 0 0 tun0
192.168.255.0 192.168.255.2 255.255.255.0 UG 0 0 0 tun0
192.168.255.2 * 255.255.255.255 UH 0 0 0 tun0
TCPDUMP on server:
listening on any, link-type LINUX_SLL (Linux cooked), capture size 262144 bytes
09:44:00.245237 In ethertype IPv4 (0x0800), length 64: 192.168.255.6.50130 > 116.203.39.239.443: Flags [S], seq 1419886521, win 65535, options [mss 1358,sackOK,eol], length 0
09:44:00.245291 In ethertype IPv4 (0x0800), length 64: 192.168.255.6.50129 > 116.203.39.239.443: Flags [S], seq 997517613, win 65535, options [mss 1358,sackOK,eol], length 0
09:44:00.489500 In ethertype IPv4 (0x0800), length 64: 192.168.255.6.50133 > 116.203.39.239.443: Flags [S], seq 1204533842, win 65535, options [mss 1358,sackOK,eol], length 0
09:44:08.406822 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [SEW], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789759155 ecr 0,sackOK,eol], length 0
09:44:09.389371 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789760156 ecr 0,sackOK,eol], length 0
09:44:10.394046 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789761156 ecr 0,sackOK,eol], length 0
09:44:11.398104 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789762156 ecr 0,sackOK,eol], length 0
09:44:12.401935 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789763156 ecr 0,sackOK,eol], length 0
09:44:13.417204 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789764156 ecr 0,sackOK,eol], length 0
09:44:13.590324 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [SEW], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789764309 ecr 0,sackOK,eol], length 0
09:44:14.579101 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789765309 ecr 0,sackOK,eol], length 0
09:44:15.432663 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789766156 ecr 0,sackOK,eol], length 0
09:44:15.587123 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789766309 ecr 0,sackOK,eol], length 0
09:44:16.594146 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789767309 ecr 0,sackOK,eol], length 0
09:44:17.698711 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789768309 ecr 0,sackOK,eol], length 0
09:44:18.904494 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789769309 ecr 0,sackOK,eol], length 0
09:44:19.553841 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789770156 ecr 0,sackOK,eol], length 0
09:44:20.640355 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789771309 ecr 0,sackOK,eol], length 0
09:44:24.657187 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789775309 ecr 0,sackOK,eol], length 0
09:44:27.512705 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789778156 ecr 0,sackOK,eol], length 0
09:44:32.688796 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789783309 ecr 0,sackOK,eol], length 0
09:44:43.601342 In ethertype IPv4 (0x0800), length 80: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1358,nop,wscale 6,nop,nop,TS val 789794156 ecr 0,sackOK,eol], length 0
TCPDUMP on client:
tcpdump: data link type PKTAP
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on any, link-type PKTAP (Apple DLT_PKTAP), capture size 262144 bytes
11:44:00.223638 AF IPv4 (2), length 52: 192.168.255.6.50130 > 116.203.39.239.443: Flags [S], seq 1419886521, win 65535, options [mss 1460,sackOK,eol], length 0
11:44:00.223649 AF IPv4 (2), length 52: 192.168.255.6.50129 > 116.203.39.239.443: Flags [S], seq 997517613, win 65535, options [mss 1460,sackOK,eol], length 0
11:44:00.467512 AF IPv4 (2), length 52: 192.168.255.6.50133 > 116.203.39.239.443: Flags [S], seq 1204533842, win 65535, options [mss 1460,sackOK,eol], length 0
11:44:02.386531 64:59:f8:79:47:90 > ac:bc:32:a0:d4:93, ethertype IPv4 (0x0800), length 103: 208.67.222.222.53 > 10.10.10.14.17196: 64672 2/0/0 CNAME mio-ip.it., A 116.203.39.239 (61)
11:44:08.360452 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [SEW], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789759155 ecr 0,sackOK,eol], length 0
11:44:09.366714 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789760156 ecr 0,sackOK,eol], length 0
11:44:10.369932 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789761156 ecr 0,sackOK,eol], length 0
11:44:11.375519 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789762156 ecr 0,sackOK,eol], length 0
11:44:12.379996 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789763156 ecr 0,sackOK,eol], length 0
11:44:13.395279 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789764156 ecr 0,sackOK,eol], length 0
11:44:13.549938 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [SEW], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789764309 ecr 0,sackOK,eol], length 0
11:44:14.557202 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789765309 ecr 0,sackOK,eol], length 0
11:44:15.410954 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789766156 ecr 0,sackOK,eol], length 0
11:44:15.565134 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789766309 ecr 0,sackOK,eol], length 0
11:44:16.572224 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789767309 ecr 0,sackOK,eol], length 0
11:44:17.579461 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789768309 ecr 0,sackOK,eol], length 0
11:44:18.593332 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789769309 ecr 0,sackOK,eol], length 0
11:44:19.449030 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789770156 ecr 0,sackOK,eol], length 0
11:44:20.618384 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789771309 ecr 0,sackOK,eol], length 0
11:44:24.634407 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789775309 ecr 0,sackOK,eol], length 0
11:44:27.489488 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789778156 ecr 0,sackOK,eol], length 0
11:44:32.666752 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789783309 ecr 0,sackOK,eol], length 0
11:44:43.579045 AF IPv4 (2), length 68: 192.168.255.6.50213 > 116.203.39.239.443: Flags [S], seq 3582988739, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789794156 ecr 0,sackOK,eol], length 0
11:44:48.752352 AF IPv4 (2), length 68: 192.168.255.6.50221 > 116.203.39.239.443: Flags [S], seq 3316043486, win 65535, options [mss 1460,nop,wscale 6,nop,nop,TS val 789799309 ecr 0,sackOK,eol], length 0
Server can access to internet, can ping the requested ip.
If i comment out push "route 116.203.39.239" and enable push "redirect-gateway def1" in the server config the results are the same.
I can't find the problem, can anyone help me, please?
Thanks, bye to all.