Benutzer-Werkzeuge

Webseiten-Werkzeuge


en:howtos:pivpn
Übersetzungen dieser Seite:

Dies ist eine alte Version des Dokuments!


PiVPN installation and configuration

The question why you need a VPN is easy to answer, it offers the possibility to use your own infrastructure sensibly on the go. Concrete examples:

  • Secure use of the Internet in public HotSpots
  • Access to the home network hard drive

VPNs are offered by a wide variety of providers, but are usually subject to a fee or limited in data volume. In addition, there is the consideration that you have to trust the provider, because all network traffic runs through their server and can be read there.
Come for your own VPN solution

  • your own (WLAN) router
  • a computer in the home network in question

Some router manufacturers offer the option of setting up a VPN in the device. I myself have a Fritz!Box and can set up a VPN there. The AVM website offers very good HowTo entries. However, the implementation only allows „IPsec“ with „Xauth“, which is not supported on many devices. An app from AVM helps on smartphones, but to connect a Windows 10 laptop, for example, requires software from third-party manufacturers. Running a computer at home sounds complicated, but it isn't. The RaspBerry Pi, a cheap (both to buy and run) home server. The range of software is overwhelming, as usual with Linux, and also free.

For your own VPN solution, OpenVPN comes into play. OpenVPN supports all common platforms and does not require a server from a provider.

So how does PiVPN come into play? Installing, configuring and operating an OpenVPN server requires specialist knowledge that not everyone wants to acquire. To get around this problem, a tool was made available with PiVPN that takes over these tasks in a simple way. The official website of the PiVPN project offers information about the project, on the GitHub page of the project the source code can be viewed.

Articles worth reading on this topic (including helpful sources from my first attempts with PiVPN):

Preparation

Before the installation, one should gather some information that will be needed during the installation. The most important ones are listed here, in most cases suitable suggestions are made.

  • Name of the network interface, usually eth0 or wlan0. Since the switch to version 9 (Stretch), the names have been changed by default. E.g. eth0 is just called „en“ followed by the MAC address
  • Port number on which OpenVPN should be addressed. This port number must also be forwarded to the RaspBerry Pi on the router. The manufacturer's documentation should be consulted to set up „port forwarding“ on the router.
  • The protocol to be used can be UDP or TCP, each with advantages and disadvantages. I personally prefer UDP as it is a connectionless protocol and offers better performance. TCP offers the advantage that it can be better hidden if a firewall has to be circumvented. In this case it is recommended to use TCP port 443 and port-sharing with the web server.
  • Setting up a dynamic address is also necessary. There are various free providers of such services, which is the best depends on the support in the home router.

Installation

curl -L https://install.pivpn.io | bash

That's it, a few questions are asked during the installation, the answers to which are pre-assigned for the „normal“ VPN user. It is advisable to take a look at the English step-by-step instructions. to get an impression of the answers to be selected.
After the installation, PiVPN is ready to use.

en/howtos/pivpn.1645169697.txt.gz · Zuletzt geändert: 2022/02/18 07:34 von morquai