After <ahref="https://github.com/hwdsl2/setup-ipsec-vpn"target="_blank">setting up your own VPN server</a>, follow these steps to configure your devices. IPsec/XAuth ("Cisco IPsec") is natively supported by Android, iOS and OS X. There is no additional software to install. Windows users can use the free <ahref="https://www.shrew.net/download/vpn"target="_blank">Shrew Soft client</a>. In case you are unable to connect, first check to make sure the VPN credentials were entered correctly.
Once connected, you will see **tunnel enabled** in the VPN Connect status window. Click the "Network" tab, and confirm that **Established - 1** is displayed under "Security Associations". You can verify that your traffic is being routed properly by <ahref="https://www.google.com/search?q=my+ip"target="_blank">looking up your IP address on Google</a>. It should say "Your public IP address is `Your VPN Server IP`".
To connect to the VPN: Use the menu bar icon, or go to the Network section of System Preferences, select the VPN and choose **Connect**. You can verify that your traffic is being routed properly by <ahref="https://www.google.com/search?q=my+ip"target="_blank">looking up your IP address on Google</a>. It should say "Your public IP address is `Your VPN Server IP`".
Once connected, you will see a VPN icon in the notification bar. You can verify that your traffic is being routed properly by <ahref="https://www.google.com/search?q=my+ip"target="_blank">looking up your IP address on Google</a>. It should say "Your public IP address is `Your VPN Server IP`".
Once connected, you will see a VPN icon in the status bar. You can verify that your traffic is being routed properly by <ahref="https://www.google.com/search?q=my+ip"target="_blank">looking up your IP address on Google</a>. It should say "Your public IP address is `Your VPN Server IP`".
Fedora 28 (and newer) and CentOS 7 users can install the <ahref="https://apps.fedoraproject.org/packages/s/libreswan"target="_blank">NetworkManager-libreswan-gnome</a> package, then configure the IPsec/XAuth VPN client using the GUI.
1. Go to Settings -> Network -> VPN. Click the **+** button.
1. Select **IPsec based VPN**.
1. Enter anything you like in the **Name** field.
1. Enter `Your VPN Server IP` for the **Gateway**.
1. Select **IKEv1 (XAUTH)** in the **Type** drop-down menu.
1. Enter `Your VPN Username` for the **User name**.
1. Right-click the **?** in the **User password** field, select **Store the password only for this user**.
1. Enter `Your VPN Password` for the **User password**.
1. Leave the **Group name** field blank.
1. Right-click the **?** in the **Secret** field, select **Store the password only for this user**.
1. Enter `Your VPN IPsec PSK` for the **Secret**.
1. Leave the **Remote ID** field blank.
1. Click **Add** to save the VPN connection information.
1. Turn the **VPN** switch ON.
Once connected, you can verify that your traffic is being routed properly by <ahref="https://www.google.com/search?q=my+ip"target="_blank">looking up your IP address on Google</a>. It should say "Your public IP address is `Your VPN Server IP`".
This document was adapted from the <ahref="https://github.com/StreisandEffect/streisand"target="_blank">Streisand</a> project, maintained by Joshua Lund and contributors.
Based on <ahref="https://github.com/StreisandEffect/streisand/blob/6aa6b6b2735dd829ca8c417d72eb2768a89b6639/playbooks/roles/l2tp-ipsec/templates/instructions.md.j2"target="_blank">the work of Joshua Lund</a> (Copyright 2014-2016)
This program is free software: you can redistribute it and/or modify it under the terms of the <ahref="https://www.gnu.org/licenses/gpl.html"target="_blank">GNU General Public License</a> as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.