Wg0 routing to LAN

I have 2 routers : main router 192.168.1.1 and second router ( behind main router ) 192.168. 3.1
the second router based old modified Openwrt ( 12RC1 ) and never supported by Openwrt . On second router I installed entware ipk wireguard-go and tools, the wg0 tunneling is working by manually started wg, meaning I have response ping with traceroute -i wg0 www.example.com and showing vpn provider local IP address as start point. But I have no luck to find inside wg-tools ipk to define routing the tunnel wg0 to LAN neither script to run service /etc/init.d , so I tried with

root@AC2300:/etc/config# ip route del default
root@AC2300:/etc/config# ip route add default dev wg0
root@AC2300:/etc/config# ip route add 152.XX.XX.100/32 via 192.168.1.1 dev eth0
root@AC2300:/etc/config# ip route
10.5.0.0/16 dev wg0 scope link  src 10.5.0.2
152.XX.XX.100 via 192.168.1.1 dev eth0
192.168.1.0/24 dev eth0 scope link  src 192.168.1.50
192.168.3.0/24 dev br-lan scope link  src 192.168.3.1

But vpn tunneling to second router LAN still not working, Is it possible to configure in /etc/config/network for routing wg0 to LAN ? Please advise and thank you

  • Is there a reason you're not installing from the official repository...that also includes packages for: the Wireguard web GUI, tools, etc.?
  • It's just normal routing...and if your router knows of the LAN, no route is needed locally, only on the remote WG router/device
opkg update
opkg install kmod-udptunnel4 kmod-udptunnel6 kmod-wireguard wireguard-tools wireguard luci-proto-wireguard luci-app-wireguard

The reason not installing from official repository, because

Downloading http://downloads.openwrt.org/attitude_adjustment/12.09-rc1/model_brcm_bcm490x/generic/packages/Packages.gz.
wget: server returned error: HTTP/1.1 404 Not Found
Collected errors:
 * opkg_download: Failed to download http://downloads.openwrt.org/attitude_adjustment/12.09-rc1/model_brcm_bcm490x/generic/packages/Packages.gz, wget returned 1

neither find on Openwrt Archive for bcm490x . thanks

:open_mouth:

WTF?

OK, yes, Wireguard didn't exist then Attitude Adjustment was created. Fruther, that version is old with known vulnerabilities - I don't suggest its use. Nor would an RC version's repository be available today (you're not even running a final version of 12.09).

You should upgrade your device to a current version of OpenWrt.

Hummmm...disregard, it seems you're asking about an unsupported device. You should inquire with the person who built the firmware.

1 Like