Wireguard routes

Started by Friend4all, March 25, 2025, 06:01:21 AM

Previous topic - Next topic
March 25, 2025, 06:01:21 AM Last Edit: March 25, 2025, 06:24:59 AM by Friend4all
How do I create routes through wg tunnel?
Here is my network:

                                                                             ISP1                       
             /-----10.2.2.0/24 (wg)------\            |
10.10.20.0/24 ---10.50.50.0/24  ---   10.10.10.0/24 - 172.16.100.0/24
   LAN3                           ISP2                         LAN1                  LAN2

I have working wg tunnel through ISP2, and I have access from LAN3 to LAN1 and back. But I need acces from LAN3 to LAN2
In allowed IP on LAN3 router I have 10.2.2.0/24(tunnel address), 10.10.10.0/24 and 172.16.100.0/24 (route for 10.10.10.0/24 created by wg, but no routes for 172.16.100.0/24)
on LAN1 I have 10.2.2.0/24 and 10.10.20.0/24. for LAN2 there is static route (172.16.100.0/24 via 10.10.10.30) on router LAN1 (there is no problem with routing between LAN1 and LAN2)

Place the respective remote networks into the "AllowedIPs" field on each side.
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Quote from: Patrick M. Hausen on March 25, 2025, 07:10:32 AMPlace the respective remote networks into the "AllowedIPs" field on each side.
I have done that (on LAN3 router there is 10.2.2.0/24,10.10.10.0/24 and 172.16.64.0/24, on LAN1 there is 10.2.2.0/24,10.10.20.0/24). didnt work

Type

wg
netstat -rn

If the routes are there, probably firewall rules are missing.
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

I removed networks from allowedIP, then added them again, and now routes work. Thanks