Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
docs:guide-user:services:vpn:wireguard:start [2020/06/02 20:27] – [Creating a Wireguard interface] Spaces not legal richb-hanoverdocs:guide-user:services:vpn:wireguard:start [2021/03/21 07:17] – flush cache vgaetera
Line 1: Line 1:
-====== WireGuard VPN ====== +====== WireGuard ====== 
-WireGuard is an open-source software application and protocol that implements virtual private network (VPN) techniques to create secure point-to-point connections in routed or bridged configurations. +{{pagequery>@:docs:guide-user:services:vpn:wireguard *;sort=ns,title;group;cols=1;hidestart;hidejump;display={title};filter=!name:sidebar}}
-It is run as a module inside the Linux kernel and aims for better performance than the IPsec and OpenVPN tunneling protocols. +
-It is designed as a general purpose VPN for running on embedded interfaces and super computers alike, fit for many different circumstances. +
-It uses UDP. +
- +
-===== VPN Server or VPN Client ===== +
- +
-Wireguard is a peer-to-peer VPN service. Each endpoint talks to the other, tunneling/encrypting the data between them. For example, Wireguard can provide: +
- +
-  * **VPN Server:** If you install Wireguard on your OpenWrt router, you can use Wireguard on your laptop to administer services "inside" your local network +
-  * **VPN Client:** Installing Wireguard on your laptop lets you connect into a Wireguard endpoint (say, on your OpenWrt router) +
-  * **Peer-to-Peer VPN"** You can install Wireguard to encrypt traffic between two OpenWrt routers to make them "on the same network"+
- +
-===== Installation ===== +
-WireGuard can be installed through the package [[packages:pkgdata:wireguard|wireguard]] and [[packages:pkgdata:luci-app-wireguard|luci-app-wireguard]] for integration with LuCI. +
-You'll need to reboot the router. +
- +
-==== Creating a Wireguard interface ==== +
-To create a new Wireguard interface go to Network > Interfaces > Add new interface... and select "WireguardVPN" from the "Protocol of the new interface" dropdown menu. +
- +
-==== Generate a key pair ===== +
-To generate a key pair of private and public keys, and store them to the files "privkey" and "pubkey" respectively, run: +
- +
-<code bash> +
-wg genkey | tee privkey | wg pubkey > pubkey +
-</code> +
- +
-  * The private key ("privkey") must be kept secret and safe; It's the key you enter into the config, for example in LuCI. +
-  * The public key ("pubkey") is shared with peers (the other end that gets connected with). +
- +
-If you are using LuCI to configure WireGuard, it's enough to run "wg genkey" and copy the output into the field "Private Key"; The public key is then later shown in the LuCI interface under Status > WireGuard status. +
- +
-===== Internal links ===== +
-{{pagequery>@:docs:guide-user:services:vpn:wireguard *;sort=ns,title;cols=1;hidestart;hidejump;display={title};filter=!name:sidebar;bullet=square}} +
- +
-See also: +
-  * [[docs:guide-user:network:tunneling_interface_protocols#static_addressing_of_wireguard_tunnel|WireGuard configuration example]] +
- +
-===== External links ===== +
-  * [[https://www.wireguard.com/|WireGuard Homepage]] +
-  * [[https://www.wireguard.com/papers/wireguard.pdf|WireGuard's technical whitepaper]] +
-  * [[https://git.zx2c4.com/WireGuard/|WireGuard's repository]] +
-  * [[http://chrisbuchan.co.uk/uncategorized/wireguard-setup-openwrt/|WireGuard setup walkthrough]]+
  
  • Last modified: 2021/08/02 17:11
  • by vgaetera