I have properly working IPv4 and IPv6 networks. IPv4 is NATed, IPv6 /64 prefix comes from WAN (PPPoE) via DHCPv6 PD and it is then Router Advertised to my LAN.
I wan’t to route some of the outgoing traffic via a WireGuard VPN using NAT. To do that I’ve:
created a new routing table;
added the 0.0.0.0/0 and ::/0 routes via the VPN interface to this new routing table;
added the nat rules;
added the mangle rules to do the mark-routing.
I can see the mangle firewall rule increasing the packets counter, but this is not working for IPv6. The marked IPv6 traffic is still going directly to the Internet, not via the VPN.
Interestingly, this same configuration is working fine for IPv4.
Am I doing anything wrong here? Or is it a bug with RouterOS v7?
I also discovered by accident that if I mess with /routing/rule/ (like add and then remove some rules) the marked traffic will start going through the VPN, even after removing all rules in there. This makes me guess it is something related to routing cache?
(This config is slightly different from the other one I posted before. In this one I’m using address-lists to mark which traffic should and should not go through the VPN interface.)
I have the same problem as topic author.
Connection mark didn’t help.
The marked IPv6 traffic is still going directly to the Internet, not via the VPN.
Can anyone suggest the solution?
In this example I’m using a destination address list (dst-address-list=nordvpn) to mark which connections I want to go through the VPN, but you can use other methods too (like source IP address, for example).
The last rule is important to make sure the traffic that went through the VPN comes back to the main table (where my LAN is).
Thank you, but this didn’t help me.
ipv4 works without problem but ipv6 not.
I try mark the connection before and try now again. Connection is marked, packets are marked, but routing is ignored.
Can it be a routing problem. Is routing require a more complex setting that for ipv4?