Hello,
I followed a tutorial to setup the community version of openvpn on my ubuntu 18.04 server:
https://linuxconfig.org/openvpn-setup-on-ubuntu-18-04-bionic-beaver-linux#h7-step-2-server-infrastructure-setup
I created 2 client configs: one for my computer (Windows 10) and one for my mobile phone (Samsung S20). On the computer, it works well but on the phone, the connection seems to work but I can't load any web page and the bandwith is about few Bytes/s (upload and download).
Here is my server config:
port 1194
proto udp
dev tun
ca ca.crt
cert server.crt
key server.key # This file should be kept secret
dh dh2048.pem
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist /var/log/openvpn/ipp.txt
push "redirect-gateway def1 bypass-dhcp"
keepalive 10 120
tls-auth ta.key 0 # This file is secret
cipher AES-256-CBC
persist-key
persist-tun
status /var/log/openvpn/openvpn-status.log
verb 3
explicit-exit-notify 1
The ovpn client file:
client
dev tun
proto udp
remote XXXX 1194
resolv-retry infinite
nobind
user nobody
group nogroup
persist-key
persist-tun
<ca>
...
</ca>
<cert>
...
</cert>
<key>
...
</key>
remote-cert-tls server
key-direction 1
<tls-auth>
...
</tls-auth>
cipher AES-256-CBC
verb 3
And the Android logs:
18:46:55.341 -- ----- OpenVPN Start -----
18:46:55.341 -- EVENT: CORE_THREAD_ACTIVE
18:46:55.343 -- OpenVPN core 3.git::f225fcd0:Release android arm64 64-bit PT_PROXY built on Mar 3 2020 21:07:24
18:46:55.343 -- Frame=512/2048/512 mssfix-ctrl=1250
18:46:55.344 -- UNUSED OPTIONS
4 [resolv-retry] [infinite]
5 [nobind]
6 [user] [nobody]
7 [group] [nogroup]
8 [persist-key]
9 [persist-tun]
17 [verb] [3]
18:46:55.345 -- EVENT: RESOLVE
18:46:55.349 -- Contacting XXXX:1194 via UDP
18:46:55.349 -- EVENT: WAIT
18:46:55.351 -- Connecting to [XXXX]:1194 (XXXX) via UDPv4
18:46:55.362 -- EVENT: CONNECTING
18:46:55.364 -- Tunnel Options:V4,dev-type tun,link-mtu 1557,tun-mtu 1500,proto UDPv4,keydir 1,cipher AES-256-CBC,auth SHA1,keysize 256,tls-auth,key-method 2,tls-client
18:46:55.364 -- Creds: UsernameEmpty/PasswordEmpty
18:46:55.365 -- Peer Info:
IV_GUI_VER=OC30Android
IV_VER=3.git::f225fcd0:Release
IV_PLAT=android
IV_NCP=2
IV_TCPNL=1
IV_PROTO=2
IV_AUTO_SESS=1
18:46:55.377 -- VERIFY OK : depth=1
cert. version : 3
serial number : XXX
issuer name : XXX
subject name : XXX
issued on : 2020-03-29 12:14:12
expires on : 2030-03-27 12:14:12
signed using : RSA with SHA-256
RSA key size : 2048 bits
basic constraints : CA=true
18:46:55.377 -- VERIFY OK : depth=0
cert. version : 3
serial number : 01
issuer name : XXX
subject name : XXX
issued on : 2020-03-29 12:14:27
expires on : 2030-03-27 12:14:27
signed using : RSA with SHA-256
RSA key size : 2048 bits
basic constraints : CA=false
subject alt name : server
cert. type : SSL Server
key usage : Digital Signature, Key Encipherment
ext key usage : TLS Web Server Authentication
18:46:55.413 -- SSL Handshake: TLSv1.2/TLS-ECDHE-RSA-WITH-AES-256-GCM-SHA384
18:46:55.413 -- Session is ACTIVE
18:46:55.414 -- EVENT: GET_CONFIG
18:46:55.416 -- Sending PUSH_REQUEST to server...
18:46:55.421 -- OPTIONS:
0 [redirect-gateway] [def1] [bypass-dhcp]
1 [route] [10.8.0.1]
2 [topology] [net30]
3 [ping] [10]
4 [ping-restart] [120]
5 [ifconfig] [10.8.0.6] [10.8.0.5]
6 [peer-id] [0]
7 [cipher] [AES-256-GCM]
18:46:55.421 -- PROTOCOL OPTIONS:
cipher: AES-256-GCM
digest: SHA1
compress: NONE
peer ID: 0
18:46:55.422 -- EVENT: ASSIGN_IP
18:46:55.462 -- Connected via tun
18:46:55.463 -- EVENT: CONNECTED info='XXX:1194 (XXX) via /UDPv4 on tun/10.8.0.6/ gw=[10.8.0.5/]'
What is wrong for the connection on the Android phone? How can I solve that?
Thank you for your help