New on LowEndTalk? Please Register and read our Community Rules.
WireGuard IPv4 Routing HELP
Hi!
I'm trying to learn wireguard. And need some help, i'm a beginner at networking.
Server A:
[Interface]
Address = 192.168.1.1/24
ListenPort = 51820
PrivateKey = key
[Peer]
PublicKey = key
AllowedIPs = 192.168.1.2/32, AdditionalIP/32
Endpoint = ServerB:51820
Server B:
[Interface]
Address = 192.168.1.2/24, AdditionalIP/32
ListenPort = 51820
PrivateKey = key
[Peer]
PublicKey = key
AllowedIPs = 192.168.1.1/32
Endpoint = ServerA:51820
I want to use the AdditionalIP/32 which belongs to Server A on Server B
I can ping both 192.168.1.x from servers, also AdditionalIP.
However, I cant access to ServerB with AdditionalIP.
root@ServerA:~# ip ro show dev wg0
AdditionalIP scope link
192.168.1.0/24 proto kernel scope link src 192.168.1.1
root@ServerB:
3: wg0: <POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1420 qdisc noqueue state UNKNOWN group default qlen 1000
link/none
inet 192.168.1.2/24 scope global wg0
valid_lft forever preferred_lft forever
inet AdditionalIP/32 scope global wg0
valid_lft forever preferred_lft forever
When ping AdditionalIP from outside.
Request timed out.
Reply from 10.0.1.174: Destination host unreachable.
Request timed out.
Comments
To use AdditionalIP on Server B it needs to be routed to Server A. If AdditionallIP isn't routed to Server A but instead is supposed to be assigned to the external interface, then proxy-ARP is needed.
It is not routed to Server A. Also I have tried proxy-arp but still not working.
It gone. And only shows:
Request timed out.
Tracert has changed and ServerA is the next hop after 10.0.1.174:
Not WireGuard, but I made moving IPv4 via IP6GRE tunnel.
https://yoursunny.com/t/2023/borrow-ipv4/
Gre protocol is blocked and can’t be used. Also i want to do that with wg.