From c1415bbb67297f3eeb7c8c167e9d1ff6c1eeb3b4 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Thu, 30 Sep 2021 20:28:31 +0300 Subject: add index.html --- index.html | 105 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 index.html diff --git a/index.html b/index.html new file mode 100644 index 0000000..832fb1b --- /dev/null +++ b/index.html @@ -0,0 +1,105 @@ +--- +title: Main page +layout: plain +navbar: + link: Main + icon: home + +params: + - id: server + desc: Server + items: + - id: public_key + name: Public key + placeholder: "Server's public key" + help: | + Query using wg show wg0 public-key. + - id: endpoint + name: Endpoint + placeholder: "Server's endpoint in the HOST:PORT format" + help: | + Server's public IP address or a hostname, accessible from the client. + Query the current port using wg show wg0 listen-port. + - id: preshared_key + name: Preshared key + placeholder: Preshared key (shared between server and client) + help: | + Generate using wg genpsk. + - id: client + desc: Client + items: + - id: public_key + name: Public key + placeholder: "Client's public key" + help: | + Generate both the private and the public keys using wg genkey | tee private.key | wg pubkey > public.key. + - id: private_key + name: Private key + placeholder: "Client's private key" + help: | + Unless generated in one go with the public key, generate one using wg genkey. + - id: ipv4 + name: IPv4 + placeholder: IPv4 address and netmask, like 192.168.123.5/24 + help: | + IPv4 address to assign to the client and its netmask in the CIDR format. + - id: ipv6 + name: IPv6 + placeholder: IPv6 address and netmask, like fd01:2345:6789::5/48 + help: | + IPv6 address to assign to the client and its netmask in the CIDR format. +--- +

WireGuard configuration

+ +
+
+

WireGuard is incredibly flexible. +For one thing, there's no built-in notion of a "server" and its "clients". +However, I believe that there being a central server and a number of clients +connected to it is a common use-case. +Adding a client might not be easy, since their configuration is typically +distributed in a file adhering to a WireGuard-specific format; these files can +be tedious to write by hand. +This page tries to make this task easier.

+

This page assumes that you have a WireGuard server +configured on interface wg0. +You can then generate the new client's keys, feed them to this page and it will +show the configuration that can be easily consumed by the new client.

+
+
+ +
+
+{% for grp in page.params %} +
+
+
+
+

{{ grp.desc }}

+
+
+
+ {% for param in grp.items %} +
+
+ +
+ + {{ param.help }} +
+
+
+ {% endfor %} +
+{% endfor %} +
+
+
+
+ +
+
+
+
+
+
-- cgit v1.2.3