wireplug

2 min read Original article ↗

Install on macOS

wireplug currently relies on Cargo for installation:

$ brew install rust wireguard-go
$ cargo install --git https://github.com/alpn/wireplug --tag v0.1.0 wireplugd

Use wireplugd to create a config file with a randomly generated private key:

# This requires root access to write the config file to /etc
$ sudo wireplugd wg0 --generate-config

The public key associated with your new private key will also appear in the config file.

  • Share this public key with your peers.
  • Edit the config file at /etc/wireplugd.wg0 as needed.

Finally, start wireplugd:

$ sudo wireplugd wg0

Install on Linux

wireplug currently relies on Cargo for installation:

$ cargo install --git https://github.com/alpn/wireplug --tag v0.1.0 wireplugd

Use wireplugd to create a config file with a randomly generated private key:

# This requires root access to write the config file to /etc
$ sudo wireplugd wg0 --generate-config

The public key associated with your new private key will also appear in the config file.

  • Share this public key with your peers.
  • Edit the config file at /etc/wireplugd.wg0 as needed.

Create a new WireGuard interface:

$ sudo ip link add dev wg0 type wireguard

Finally, start wireplugd:

$ sudo wireplugd wg0

Install on Windows

# TODO

Install on OpenBSD

wireplug currently relies on Cargo for installation:

$ cargo install --git https://github.com/alpn/wireplug --tag v0.1.0 wireplugd

Follow the example in man 4 wg to create a new WireGuard interface using ifconfig(8) and hostname.if(5). You don't need to specify values for wgport, wgpka, and wgendpoint. Once the interface is created, run the following command to retrieve the public key associated with your new private key (wgpubkey):

$ doas ifconfig wg0 | grep 'wgpubkey' | cut -d ' ' -f 2

Share this public key with your peers.
Finally, start wireplugd:

$ doas wireplugd wg0