[Interface]Address = 10.8.8.2/32DNS = 10.0.0.14MTU = 1390PrivateKey = SUPERSECRFETPRIVATEKEY[Peer]AllowedIPs = 0.0.0.0/0Endpoint = IP:51820PublicKey = SUPERSECRFETPUBLICKEY
sudo wg quick-up wg0
penguin@saturn:~$ ip routedefault via 192.168.5.1 dev wlp58s0 proto dhcp metric 600169.254.0.0/16 dev wlp58s0 scope link metric 1000192.168.5.0/24 dev wlp58s0 proto kernel scope link src 192.168.5.186 metric 600
penguin@saturn:~$ sudo wg-quick up wg0[sudo] password for penguin:wg-quick: `wg0' already exists
penguin@saturn:~$ sudo wg-quick down wg0[#] ip -4 rule delete table 51820[#] ip -4 rule delete table main suppress_prefixlength 0[#] ip link delete dev wg0[#] nft -f /dev/fd/63
penguin@saturn:~$ sudo wg-quick up wg0[#] ip link add wg0 type wireguard[#] wg setconf wg0 /dev/fd/63[#] ip -4 address add 10.0.0.4/32 dev wg0[#] ip link set mtu 1390 up dev wg0[#] wg set wg0 fwmark 51820[#] ip -4 route add 0.0.0.0/0 dev wg0 table 51820[#] ip -4 rule add not fwmark 51820 table 51820[#] ip -4 rule add table main suppress_prefixlength 0[#] sysctl -q net.ipv4.conf.all.src_valid_mark=1[#] nft -f /dev/fd/63
penguin@saturn:~$ nmcli --overview connection show wg0connection.id: wg0connection.uuid: 27491c38-6366-433b-913a-6728cdc79fb0connection.type: wireguardconnection.interface-name: wg0connection.autoconnect: noconnection.timestamp: 1719830174ipv4.method: manualipv4.addresses: 10.0.0.4/32ipv6.method: disabledwireguard.private-key-flags: 0 (none)wireguard.listen-port: 47700GENERAL.NAME: wg0GENERAL.UUID: 27491c38-6366-433b-913a-6728cdc79fb0GENERAL.DEVICES: wg0GENERAL.IP-IFACE: wg0GENERAL.STATE: activatedGENERAL.DEFAULT: noGENERAL.DEFAULT6: noGENERAL.SPEC-OBJECT: --GENERAL.VPN: noGENERAL.DBUS-PATH: /org/freedesktop/NetworkManager/ActiveConnection/11GENERAL.CON-PATH: /org/freedesktop/NetworkManager/Settings/15GENERAL.ZONE: --GENERAL.MASTER-PATH: --IP4.ADDRESS[1]: 10.0.0.4/32IP4.ROUTE[1]: dst = 0.0.0.0/0, nh = 0.0.0.0, mt = 0, table=51820
penguin@saturn:~$ sudo wg showconf wg0[Interface]ListenPort = 47700FwMark = 0xca6cPrivateKey = AAAAA[Peer]PublicKey = BBBBBAllowedIPs = 0.0.0.0/0Endpoint = publicip:51820
[Interface]Address = 10.0.0.4/32PrivateKey = AAAAAAMTU = 1390[Peer]#PublicKey = BBBBBB#This one below is the server's public keyPublicKey = CCCCC#AllowedIPs = <Networks to which this client should have access>/<Netmask># // For example "10.11.0.0/24, 192.168.1.0/24"# // | |# // +--> The network area of the OPNsense WireGuard VPNs# // |# // +--> Network behind the firewallAllowedIPs = 0.0.0.0/0#Endpoint = <Public IP of the OPNsense firewall>:<WireGuard Port>Endpoint = endpoint:port