Stunnel + OpenVPN on Android

Jayden Chua
4 min readJun 26, 2019

Connecting your Android with Stunnel and OpenVPN is possible

Pre-requisites

Before you read on, just a quick note that this article assumes you have already set up a Stunnel and OpenVPN server. If not, please ensure you already have that set up. Here’s how I managed to set mine up.

Also, I haven’t really got round to full test this on the rest of the Android version. So, as a disclaimer, I’ve managed to get it working on Android Pie (v9) and Android Oreo (v8).

Installing the Apps

Get the following apps from the Google Play Store. There might be different clients available for OpenVPN, but this was the one that worked for me and I really like the fact that I am able to do split tunneling on the different apps.

  1. SSLDroid
  2. OpenVPN for Android

Download your Keys and Configs

Download the following files from your server.

  1. openvpn.conf — To keep things simple I place my ca.crt , client.key and client.crt into the config file, so that I can directly import into the client
  2. stunnel.p12 — If you have the pem file, this won’t work, you need to generate the p12 on the server and download it to your device.

--

--

Jayden Chua
Jayden Chua

Written by Jayden Chua

An avid web developer constantly looking for new web technologies to dabble in, more information can be found on bit.ly/jayden-chua