Supported cipher suites by OpenVPN Connect (iOS) app

Post Reply
AurelM
OpenVpn Newbie
Posts: 3
Joined: Wed Nov 11, 2020 9:11 pm

Supported cipher suites by OpenVPN Connect (iOS) app

Post by AurelM » Wed Nov 11, 2020 10:06 pm

Hi,

I've searched this forum, in the faqs and on the internet itself and can't find an answer to this question: what cipher suites are supported by the OpenVPN Connect app on iOS?

I have an Asus RT-AC68U hw version A1 with AsusWRT-Merlin 386.1_alpha2-g9675e20696 firmware used as an OpenVPN server. This latest alpha version has OpenVPN v2.5.0 on it:

Code: Select all

openvpn --version
OpenVPN 2.5.0 arm-unknown-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [MH/PKTINFO] [AEAD] built on Nov  2 2020
library versions: OpenSSL 1.1.1h  22 Sep 2020, LZO 2.08
Originally developed by James Yonan
Copyright (C) 2002-2018 OpenVPN Inc <sales@openvpn.net>
Compile time defines: enable_async_push=no enable_comp_stub=no enable_crypto_ofb_cfb=yes enable_debug=no enable_def_auth=yes enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown enable_fast_install=yes enable_fragment=yes enable_iproute2=no enable_libtool_lock=yes enable_lz4=yes enable_lzo=yes enable_management=yes enable_multihome=yes enable_pam_dlopen=no enable_pedantic=no enable_pf=yes enable_pkcs11=no enable_plugin_auth_pam=yes enable_plugin_down_root=yes enable_plugins=yes enable_port_share=yes enable_selinux=no enable_shared=yes enable_shared_with_static_runtimes=no enable_small=no enable_static=yes enable_strict=no enable_strict_options=no enable_systemd=no enable_werror=no enable_win32_dll=yes enable_x509_alt_username=no with_aix_soname=aix with_crypto_library=openssl with_gnu_ld=yes with_mem_check=no with_sysroot=no
I also have an iPhone 6 with iOS v12.4.9 (latest) and OpenVPN Connect v3.2.2(3507) (latest).

I've used the AES-128-CBC cipher suite since it had the best speed on the router, but read that it's that not that secure anymore and should use AES-128-GCM instead. I didn't make this change since this router lacks AES hardware acceleration and the speed was much lower.

However recently I've read upon CHACHA20-POLY1305 cipher suite and that it has better throughput than AES-128-CBC (without hardware acceleration for AES) and also better security so I've changed the cipher to it, but when I've loaded an updated client config on the phone it refused to connect; from the router's log:

Code: Select all

PUSH: No common cipher between server and client. Server data-ciphers: 'CHACHA20-POLY1305:AES-128-CBC', client supported ciphers 'AES-256-GCM:AES-128-GCM'
I don't know how accurate the information from the log is as it says that the client only supports AES-256-GCM and AES-128-GCM, but I've used AES-128-CBC as I've said previously.
Now I've switched the phone to use AES-128-GCM, but would like to use CHACHA20:POLY1305 instead.

Other clients, an Asus RT-AC66U B1 (similar hardware to the Asus RT-AC68U) running the same firmware and an Windows client, run happily with CHACHA20:POLY1305 cipher suites.

Can anybody shed any light on this? Thank you.

300000
OpenVPN Super User
Posts: 430
Joined: Tue May 01, 2012 9:30 pm

Re: Supported cipher suites by OpenVPN Connect (iOS) app

Post by 300000 » Mon Nov 16, 2020 8:42 pm

I got ipad and it connect with CHACHA20:POLY1305 .so on iphone I think it support too. make sure it contain this in server config it should work ok

tls-cipher TLS-ECDHE-ECDSA-WITH-AES-256-GCM-SHA384
tls-ciphersuites TLS_CHACHA20_POLY1305_SHA256:TLS_AES_128_GCM_SHA256
tls-cipher TLS-ECDHE-ECDSA-WITH-CHACHA20-POLY1305-SHA256:TLS-ECDHE-RSA-WITH-CHACHA20-POLY1305-SHA256:TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256:TLS-ECDHE-RSA-WITH-AES-128-GCM-SHA256

AurelM
OpenVpn Newbie
Posts: 3
Joined: Wed Nov 11, 2020 9:11 pm

Re: Supported cipher suites by OpenVPN Connect (iOS) app

Post by AurelM » Tue Nov 17, 2020 12:26 pm

Thank you for your response.
After making the changes on the server it still doesn't work. While the control channel uses TLS_CHACHA20_POLY1305_SHA256, the data channel still uses AES-128-GCM.

It's my fault for not specifying this correctly in the first post, I want the data channel to use CHACHA20-POLY1305.

Going through the OpenVPN Connect app's log, this caught my attention:

Code: Select all

UNUSED OPTIONS
4 [resolv-retry] [infinite] 
5 [nobind] 
7 [ncp-ciphers] [CHACHA20-POLY1305:AES-128-GCM] 
So instead of using –ncp-ciphers cipher_list option, I tried using the old –cipher alg option in a new client configuration file.
This new profile failed to import in the OpenVPN Connect app with the following error:
Image
This makes me think that the OpenVPN Connect app for iOS really doesn't support data channel encryption using the CHACHA20-POLY1305 cipher suite.

300000
OpenVPN Super User
Posts: 430
Joined: Tue May 01, 2012 9:30 pm

Re: Supported cipher suites by OpenVPN Connect (iOS) app

Post by 300000 » Wed Nov 18, 2020 11:23 pm

TLS_CHACHA20_POLY1305_SHA256 that is for Control Channel only there is no TLS_CHACHA20_POLY1305_SHA256 for data channel . when do you hear it use for data channel can you tell me? the way it work little difference so you never find it use on data channel . if they do the speed will be slow down alot . just enjoy the better speed on new TLS_CHACHA20_POLY1305_SHA256 bring to openvpn compare to old one.

AurelM
OpenVpn Newbie
Posts: 3
Joined: Wed Nov 11, 2020 9:11 pm

Re: Supported cipher suites by OpenVPN Connect (iOS) app

Post by AurelM » Thu Nov 19, 2020 4:34 pm

I think I found the answer.

Going through the changes of the OpenVPN 2.5.0 in COMMUNITY - Downloads it points to the full changes on github at Changes.rst and, more relevant, the Data channel cipher negotiation document. In the latter there's the following paragraph that pertains to the OpenVPN 3 clients (on which OpenVPN Connect app for iOS is based, according to readme.rst):
____________________
OpenVPN 3 clients

Clients based on the OpenVPN 3.x library (https://github.com/openvpn/openvpn3/) do not have a configurable --ncp-ciphers or --data-ciphers option. Instead these clients will announce support for all their supported AEAD ciphers (AES-256-GCM, AES-128-GCM and in newer versions also Chacha20-Poly1305).

To support OpenVPN 3.x based clients at least one of these ciphers needs to be included in the server's --data-ciphers option.

____________________

So there it is, the list of cipher suites supported by the OpenVPN Connect app for iOS. It seems that my searching skills and/or patience to go through documents need some improvement. :oops:

Now, for CHACHA20-POLY1305 cipher not working, I think there needs to be a newer version of OpenVPN Connect app for iOS than 3.2.2 that support it, as this was released on the 21st of October 2020, while OpenVPN 2.5.0, which added support for the cipher, was released on the 28th of October 2020.

Post Reply