Failed to connect OpenVPN from Android client
Posted: Wed Nov 07, 2018 1:31 pm
We use a custom built CA to issue certificates, which is built on Python’s `cryptography` module. The certs generated by the CA works everywhere except on Android and iOS client. It works from other third party clients on mobile and from Tunnelbear on Mac and Linux native openvpn clients. The issue is only from OpenVPN Connect app on iOS and Android. I tried downgrading the mobile app from 3.0.* version to 1.2.* but that did not help.
I imported client configs as ovpn file with inline certificates and it follows just certificate authentication, no user/pass authentication. The same file was imported on other platforms where it worked well.
Below is the error reported in logs:
===========================
15:39:15.321 -- EVENT: CONNECTING
15:39:15.324 -- Tunnel Options:V4,dev-type tun,link-mtu 1542,tun-mtu 1500,proto UDPv4,comp-lzo,cipher BF-CBC,auth SHA1,keysize 128,key-method 2,tls-client
15:39:15.325 -- Creds: UsernameEmpty/PasswordEmpty
15:39:15.326 -- Peer Info:
IV_GUI_VER=OC30Android
IV_VER=3.2
IV_PLAT=android
IV_NCP=2
IV_TCPNL=1
IV_PROTO=2
IV_LZO=1
IV_IPv6=0
IV_AUTO_SESS=1
IV_BS64DL=1
15:39:15.741 -- VERIFY OK : depth=1
cert. version : 3
serial number : 3B:C1:DD:92:E0:B5:02
issuer name : O=XXXXX, OU=VPN Server, CN=Jj20181022-CA
subject name : O=XXXX, OU=VPN Server, CN=Jj20181022-CA
issued on : 2018-10-21 06:18:31
expires on : 2048-10-14 06:18:31
signed using : RSA with SHA-256
RSA key size : 4096 bits
basic constraints : CA=true
key usage : Key Cert Sign, CRL Sign
15:39:15.743 -- VERIFY OK : depth=0
cert. version : 3
serial number : E9:6D:49:85:BD:C4:8F:52
issuer name : O=XXXXX, OU=VPN Server, CN=Jj20181022-CA
subject name : O=XXXXX, OU=VPN Server, CN=JJ20181022.xxxxxxx.com
issued on : 2018-10-21 06:19:26
expires on : 2021-10-21 06:19:26
signed using : RSA with SHA-256
RSA key size : 2048 bits
basic constraints : CA=false
subject alt name : JJ20181022.xxxxxxx.com
key usage : Non Repudiation, Key Encipherment, Key Agreement
ext key usage : TLS Web Server Authentication
15:39:15.744 -- Client exception in transport_recv_excode: mbed TLS: SSL read error : SSL - Processing of the Certificate handshake message failed
Please help.. thanks in advance.
I imported client configs as ovpn file with inline certificates and it follows just certificate authentication, no user/pass authentication. The same file was imported on other platforms where it worked well.
Below is the error reported in logs:
===========================
15:39:15.321 -- EVENT: CONNECTING
15:39:15.324 -- Tunnel Options:V4,dev-type tun,link-mtu 1542,tun-mtu 1500,proto UDPv4,comp-lzo,cipher BF-CBC,auth SHA1,keysize 128,key-method 2,tls-client
15:39:15.325 -- Creds: UsernameEmpty/PasswordEmpty
15:39:15.326 -- Peer Info:
IV_GUI_VER=OC30Android
IV_VER=3.2
IV_PLAT=android
IV_NCP=2
IV_TCPNL=1
IV_PROTO=2
IV_LZO=1
IV_IPv6=0
IV_AUTO_SESS=1
IV_BS64DL=1
15:39:15.741 -- VERIFY OK : depth=1
cert. version : 3
serial number : 3B:C1:DD:92:E0:B5:02
issuer name : O=XXXXX, OU=VPN Server, CN=Jj20181022-CA
subject name : O=XXXX, OU=VPN Server, CN=Jj20181022-CA
issued on : 2018-10-21 06:18:31
expires on : 2048-10-14 06:18:31
signed using : RSA with SHA-256
RSA key size : 4096 bits
basic constraints : CA=true
key usage : Key Cert Sign, CRL Sign
15:39:15.743 -- VERIFY OK : depth=0
cert. version : 3
serial number : E9:6D:49:85:BD:C4:8F:52
issuer name : O=XXXXX, OU=VPN Server, CN=Jj20181022-CA
subject name : O=XXXXX, OU=VPN Server, CN=JJ20181022.xxxxxxx.com
issued on : 2018-10-21 06:19:26
expires on : 2021-10-21 06:19:26
signed using : RSA with SHA-256
RSA key size : 2048 bits
basic constraints : CA=false
subject alt name : JJ20181022.xxxxxxx.com
key usage : Non Repudiation, Key Encipherment, Key Agreement
ext key usage : TLS Web Server Authentication
15:39:15.744 -- Client exception in transport_recv_excode: mbed TLS: SSL read error : SSL - Processing of the Certificate handshake message failed
Please help.. thanks in advance.