Skip to content

Instantly share code, notes, and snippets.

View tomeduarte's full-sized avatar

Tomé Duarte tomeduarte

View GitHub Profile
@tomeduarte
tomeduarte / ovpn-writer.sh
Created August 23, 2016 17:53
Script to generate an OpenVPN client configuration file in the unified format
#!/bin/sh
##
## Usage: ./ovpn-writer.sh SERVER CA_CERT CLIENT_CERT CLIENT_KEY SHARED_SECRET > client.ovpn
##
## Example invocation (note it must be run as root since key and cert files are protected
## ./ovpnwritter titty.nipples.org /etc/easy-rsa/pki/ca.crt /etc/easy-rsa/pki/issued/client.crt /etc/easy-rsa/pki/private/client.key /etc/openvpn/ta.key > iphone.ovpn
##
## Tested and works with OpenVPN Connect 1.0.7 build 199 (iSO 64-bit) on iOS 9.3.3
##