Skip to main content

Wireguard

Protocol standard

Sample

Unlike other proxy which can be defined in single line, wireguard proxy use a standalone config section to define proxy detail, and use section name to link proxy detail in proxy definition.

[Proxy]
wireguard-home = wireguard, section-name = HomeServer

[WireGuard HomeServer]
private-key = sDEZLACT3zgNCS0CyClgcBC2eYROqYrwLT4wdtAJj3s=
self-ip = 10.0.2.2
dns-server = 8.8.8.8
mtu = 1280
peer = (public-key = fWO8XS9/nwUQcqnkfBpKeqIqbzclQ6EKP20Pgvzwclg=, allowed-ips = 0.0.0.0/0, endpoint = 192.168.20.6:51820)

Format

[Proxy]
{proxy name} = wireguard, section-name = {section name}

[WireGuard {section name}]
private-key = {private key}
self-ip = {self ip}
dns-server = {dns server ip}
mtu = {mtu size}
peer = (public-key = {public key}, allowed-ips = {allowed ip routes}, endpoint = {endpoint address})

Params

NameValueMandatoryNote
proxy name-true
section name-trueSupport domain and ip format
private keybase64 encoded formattrue
self ipIPv4 formattrue
dns server ipIPv4 formattrueSupport multiple value divided with comma
mtu sizeinteger greater than zerotrue
public keybase64 encoded formattrue
allowed ip routesIPv4 route formattrue
endpoint addressIPv4 IP:PORT formattrue