I am currently connected to the internet with an ISP that only provides IPv4 with CGNAT, so I have no way of redirecting ports.
I was given a WireGuard VPN that points directly to a public IP, and my goal is to use this VPN on my RB5009 to be able to forward ports, but without routing internet traffic through the VPN.
I have tried adding the VPN to the router, but I can't access the public IP from external networks. If I ping from other networks, it doesn't respond, but if I ping from the Mikrotik via the wireguard1 interface, it works fine. In practice, traffic from the router to the outside works, but from the outside to the router, it doesn't.
I am attaching the configuration I made to add the WireGuard VPN.
Code: Select all
/interface wireguard add name=wireguard1 mtu=1380 listen-port=51820 private-key="xxxxx"
/ip address add address=PublicIP/32 interface=wireguard1
/interface wireguard peers add interface=wireguard1 public-key="redacted" endpoint-address=xxx.xxx.xxx.xxx endpoint-port=65331 allowed-address=0.0.0.0/0 persistent-keepalive=25
/ip route add dst-address=WGEndpointAdress/32 gateway=pppoe-out1 routing-table=main
/ip firewall nat add chain=srcnat action=masquerade out-interface=wireguard1
/ip firewall nat add chain=dstnat action=dst-nat in-interface=wireguard1 protocol=tcp dst-port=8 to-addresses=192.168.87.100 to-ports=80
/ip firewall filter add chain=forward action=accept in-interface=wireguard1 out-interface=bridge1 dst-address=192.168.87.0/24
/ip firewall filter add chain=forward action=accept in-interface=bridge1 out-interface=wireguard1 src-address=192.168.87.0/24
Any help is appreciated.