VLAN to VLAN SNAT

Started by rdy, July 03, 2023, 09:20:09 PM

Previous topic - Next topic
July 03, 2023, 09:20:09 PM Last Edit: July 03, 2023, 09:22:06 PM by rdy
Hello,

I am coming from a Sophos UTM and I was able to change my source IP when connecting from one PC in my network to another on a different VLAN.

Basically it was like this,

PC (192.168.10.8.) to VM (192.168.70.20) but changing my source IP to 192.168.70.20 so that VM would see think the traffic was coming from 192.168.70.254 when going to 192.168.70.20.

If it helps, on a WatchGuard I believe it was called a dynamic NAT.

If someone knows how to do this, I would be very grateful.

Cheers,
Rdy.

Pls explain, why do you want that odd  behavior.

I cannot easily change the network settings on the docker instances, and they only allow traffic from the same subnet.

I wouldn't consider it odd behavior, every firewall I have used before Opnsense, it has been something you could do. Though they were enterprise FW's and I have hit the home license limit on the Sophos UTM I was previously using.

So far though I am enjoying Opnsense so it would be upsetting if it can't do this.

Quote from: rdy on July 03, 2023, 09:20:09 PM
PC (192.168.10.8.) to VM (192.168.70.20) but changing my source IP to 192.168.70.20 so
You wouldn't change it to the destination PC but to the OPNSense interface I think. You can create such a mapping where you configure outbound NAT.

Could you please give me an example or instructions? I am not quite sure how to do that sorry.

Please disregard I have worked it out :).

Quote from: rdy on July 04, 2023, 12:47:06 PM
Please disregard I have worked it out :).

Damn.... Posts like these always piss me off.

First begging help from others.

Then when you solve whatever problem you had instead of posting the actual solution so others with the same issue could benefit from it they just post "I have worked it out :)" 

FFS ::) ::) ::) ::) ::)
2x 23.7 VMs & CARP, 4x 2.1GHz, 8GB
Cisco L3 switch, ESXi, VDS, vmxnet3
DoT, Chrony, HAProxy + NAXSI, Suricata
VPN: IPSec, OpenVPN, Wireguard
MultiWAN: Fiber 500/500Mbit dual stack + 4G failover

--
Available for private support.
Did my answer help you? Feel free to click [applaud] to the left