Can resolve Internet DNS and ping anything, can't browse Internet or LAN servers
Posted: Tue Sep 24, 2019 10:15 pm
Somewhat new user of linux, but longtime network engineer here. I installed openvpn on Centos 7 on my home server. Got everything working to the point that I can connect from my Galaxy S9. But there's this one little problem...
Pings work, to both IP address and DNS name, anywhere on the Internet. But when I attempt to browse, nothing shows up in my phone's browser. I ran tcpdump on the tun0 interface on my openvpn server, and it shows traffic in both directions to/from the server I am trying to reach on my phone, but still nothing.
***************************************
Service.conf file contents:
# OpenVPN Port, Protocol and the Tun
port 1194
proto udp
dev tun
# OpenVPN Server Certificate - CA, server key and certificate
ca /etc/openvpn/server/ca.crt
cert /etc/openvpn/server/homelan-server.crt
key /etc/openvpn/server/homelan-server.key
#DH and CRL key
dh /etc/openvpn/server/dh.pem
crl-verify /etc/openvpn/easy-rsa/3/pki/crl.pem
# Network Configuration - Internal network
# Redirect all Connection through OpenVPN Server
server 192.168.71.0 255.255.255.0
push "redirect-gateway def1"
# Using the DNS from https://dns.watch
push "dhcp-option DNS 192.168.20.21"
push "dhcp-option DNS 192.168.20.22"
# TLS Security
cipher AES-256-CBC
tls-version-min 1.2
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-256-CBC-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-CBC-SHA256
auth SHA512
auth-nocache
# Other Configuration
keepalive 10 60
persist-key
persist-tun
comp-lzo
daemon
user nobody
group nobody
# tcp-nodelay
# OpenVPN Log
log-append /var/log/openvpn.log
verb 3
***************************************
client.ovpn file contents:
client
dev tun
proto udp
remote us.***.com 1194
ca ca.crt
cert Mobile01.crt
key Mobile01.key
cipher AES-256-CBC
auth SHA512
auth-nocache
tls-version-min 1.2
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-256-CBC-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-CBC-SHA256
resolv-retry infinite
comp-lzo
persist-key
persist-tun
mute-replay-warnings
verb 6
***************************************
Also, I am unable to use my internal bind servers to resolve servers on my local network. This works from my laptop and phone when they are on wifi, but not from my phone when it is connected via OpenVPN.
Soooo, what am I doing wrong?
Pings work, to both IP address and DNS name, anywhere on the Internet. But when I attempt to browse, nothing shows up in my phone's browser. I ran tcpdump on the tun0 interface on my openvpn server, and it shows traffic in both directions to/from the server I am trying to reach on my phone, but still nothing.
***************************************
Service.conf file contents:
# OpenVPN Port, Protocol and the Tun
port 1194
proto udp
dev tun
# OpenVPN Server Certificate - CA, server key and certificate
ca /etc/openvpn/server/ca.crt
cert /etc/openvpn/server/homelan-server.crt
key /etc/openvpn/server/homelan-server.key
#DH and CRL key
dh /etc/openvpn/server/dh.pem
crl-verify /etc/openvpn/easy-rsa/3/pki/crl.pem
# Network Configuration - Internal network
# Redirect all Connection through OpenVPN Server
server 192.168.71.0 255.255.255.0
push "redirect-gateway def1"
# Using the DNS from https://dns.watch
push "dhcp-option DNS 192.168.20.21"
push "dhcp-option DNS 192.168.20.22"
# TLS Security
cipher AES-256-CBC
tls-version-min 1.2
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-256-CBC-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-CBC-SHA256
auth SHA512
auth-nocache
# Other Configuration
keepalive 10 60
persist-key
persist-tun
comp-lzo
daemon
user nobody
group nobody
# tcp-nodelay
# OpenVPN Log
log-append /var/log/openvpn.log
verb 3
***************************************
client.ovpn file contents:
client
dev tun
proto udp
remote us.***.com 1194
ca ca.crt
cert Mobile01.crt
key Mobile01.key
cipher AES-256-CBC
auth SHA512
auth-nocache
tls-version-min 1.2
tls-cipher TLS-DHE-RSA-WITH-AES-256-GCM-SHA384:TLS-DHE-RSA-WITH-AES-256-CBC-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-CBC-SHA256
resolv-retry infinite
comp-lzo
persist-key
persist-tun
mute-replay-warnings
verb 6
***************************************
Also, I am unable to use my internal bind servers to resolve servers on my local network. This works from my laptop and phone when they are on wifi, but not from my phone when it is connected via OpenVPN.
Soooo, what am I doing wrong?