How To Install Algo VPN On Ubuntu 18.04

Algo VPN easily facilitates a secure, encrypted tunnel between a client and a VPN server. One Algo VPN setup can handle all of your devices, including, Windows, Linux, OSX, Android, and iOS. You will need to install and configure Wireguard on all your devices once Algo VPN is configured.

A VPN connection is a secure tunnel between your device and your server. All unencrypted traffic is encrypted before being sent through the tunnel. When it arrives at the VPN server it is routed so all requests are returned back to you through the encrypted tunnel.

There are many uses for a VPN connection. An American working in France might use a USA based VPN to access Netflix, Hulu, or watch NFL football that is otherwise “blacked out”.

The most common reason for using a VPN is privacy. A VPN does not provide anonymity – it redirects your traffic so that all requests point back to your server, not your local IP. Your ISP can see a secure encrypted tunnel to your servers IP, but that’s all they can see. Without a VPN your ISP can see all of your DNS requests and unencrypted data. Companies can target you with behavioral-based advertising, and hackers can infiltrate your ISP to gain access to your personal information.

up to 6x faster than chrome or firefox, brave browser image

With Algo VPN, only you know where your encrypted tunnel ends. As far as your ISP is concerned, they see a tunnel to an endpoint, but they can’t see anything more. If you use a cloud provider like Vultr or Digital Ocean, you can destroy and create VPN instances as much as you want – making it almost impossible for your ISP or anyone else, to know your true identity and location.

VPN services offer many of the benefits of running Algo VPN, but you share IP’s with other people who use the VPN service. This leads to slow downloads, and can also put you in the position where the VPN provider is selling your personal information. Using an IP address that was likely used by someone else could leave you banned from certain sites, or worse – getting a warning for something you didn’t do. By creating your own VPN, you are the administrator of the server, you are the person who decides whether to hand over server logs or not, and your service provider has no clue you are using the server for VPN (unless you get a complaint). In which case, you can simply destroy the instance and make a new one.

To get started, set up a new cloud instance or server running Ubuntu 18.04. The commands below will work if you “copy and paste” them on a clean server with no errors. The only input you will need is the IP address of the server – which is explained below.

How To Install Algo VPN :

If you are not at the Linux command line us Putty to connect to your server. This works on a fresh Ubuntu 18.04 install.

  1. Switch to superuser and create a download directory. Download the latest version of Algo (master.zip) to your download folder.
sudo su

mkdir /downloads

cd /downloads

wget https://github.com/trailofbits/algo/archive/master.zip

2. Update apt-get, install unzip, and virtualenv.

apt-get update

apt-get install unzip

unzip master.zip

apt-get install virtualenv

3. Navigate to your Algo directory and use virtualenv to create and activate a virtual Python environment.

cd algo-master

virtualenv env --python=python3.6

source env/bin/activate

4. Create a file called packages.txt using nano. Copy the “sudo apt-get” commands below to the packages file. Give it execute permissions and run it. Finally, run the python3 command to install the contents fo requirements.txt.

nano packages.txt


#Copy all the apt-get commands below to packages.txt
sudo apt-get install build-essential -y
sudo apt-get install ansible -y
sudo apt-get install libssl-dev -y
sudo apt-get install libffi-dev -y
sudo apt-get install python3-dev -y
sudo apt-get install python3-pip -y
sudo apt-get install python3-setuptools -y
sudo apt-get install python3-virtualenv -y
sudo apt-get install wireguard-dkms -y

chmod 755 packages.txt

./packages.txt

python3 -m pip install -U -r requirements.txt

5. Find the external IP address for your server. If you aren’t sure what it is use ifconfig or “ip a” to find it. If you get stuck try reading How To Find An IP Address.

ifconfig

6. Open config.cfg using nano. Make a list of the users you want created in the Users list. If you plan on using different devices or multiple users you will want to edit the config. For a simple single-user install move on to the next set.

nano config.cfg

7. Run the Algo config file. Select option 11 when prompted to install on the existing server. When asked if you want SSH tunneling for each account say yes, otherwise you can hit enter to accept defaults through the prompts except the ones asking for your IP.

./algo

#Select 11. Install to existing Ubuntu 18.04
11

#Do you want each user to have their own account for SSH Tunneling

yes

#Read through the rest of the prompts. Hit enter for the defaults

8. When asked for your server IP the first time enter localhost. When you are asked for your IP a second time, use your external IP address (can be found via ifconfig or ip). Hit enter to accept the rest of the defaults when prompted.

#When asked for your server IP the first time enter: 

localhost 

#It will ask you a second time for an IP address, put your #public IP address in

198.72.X.X

#Hit enter again to accept the defaults

9. Navigate to the key files Algo VPN created for your server.

cd configs

ls

---------------------------------------------------------
#You should see your external IP as a directory
---------------------------------------------------------

cd 198.72.X.X

cd wireguard

ls

10. You will now see your keys and QR images listed in your directory. If you used the default config you will have a file called laptop.conf, copy the contents of the file, you will need to paste it into Wiregaurd to connect via VPN.

nano laptop.conf

11. If you need a QR image and you don’t want to SFTP to your server, open the file using nano, copy the data, and paste it to a notepad on your local machine. Save the code as an image (eg. filename.png) by using the proper file extension. You should then be able to open the file and use it to setup your mobile devices.

nano filename.png

Proceed to the How To Install And Use Wireguard page.