Gateway for Wireguard VPN
Germano Massullo
germano.massullo at gmail.com
Tue Nov 21 01:09:54 CET 2017
I am experiencing some troubles in configuring Wireguard to communicate to an host that is behind a NAT. Here my use case:
Host A: my computer under ISP NAT
Host B server with public static IP address, that is also a gatway for a "natted" LAN,
Host C: machine running on such LAN
I do want to allow host A to communicate with C, but I cannot manage to do that. It can only ping host B
I attach some config files, if you have an idea, please let me know.
Thank you for your time
=== Host A (Fedora 26) ===
# cat /etc/wireguard/wg0.conf
[Interface]
Address = 10.1.0.21/24
PrivateKey = *censored*
[Peer]
PublicKey = *censored*
Endpoint = vpn.foo.xx:51820 # vpn.foo.xx is Host B
AllowedIPs = 10.1.0.2/32
[Peer]
PublicKey = *censored* # host C
Endpoint = vpn.foo.xx:51820
AllowedIPs = 10.1.0.22/32
=== Host B (vpn.foo.xx) (CentOS 7) ===
ip forwarding active: net.ipv4.ip_forward = 1
# cat wg0.conf
[Interface]
Address = 10.1.0.2/24
ListenPort = 51820
PrivateKey = *censored*
[Peer]
PublicKey = *censored*
AllowedIPs = 10.1.0.21/32
[Peer]
PublicKey = *censored*
AllowedIPs = 10.1.0.22/32
=== Host C (CentOS 7) ===
# cat wg0.conf
[Interface]
Address = 10.1.0.22/24
ListenPort = 51820
PrivateKey = *censored*
[Peer]
PublicKey = *censored*
Endpoint = 192.168.1.1:51820
AllowedIPs = 10.1.0.2/32
[Peer]
PublicKey = *censored*
AllowedIPs = 10.1.0.21/32
More information about the WireGuard
mailing list