@sgtpepperaut said in NAT through OpenVPN? How to set up outbound NAT?:
Anyways unfortunately pfsense is only running on site A ...site B runs OpenWrt in the router/modem.
The point here is that pfSense has the the reply-to function, which directs response packets back to the gateway where the requests came from. This function would be helpful at site B.
Another way to get it work is by adding an outbound NAT rule on site A:
interface: <that one you have assigned to the site-to-site VPN or even OpenVPN>
Protocol: TCP (or what you need)
source: any
destination: 192.168.20.89, port: 80
Translation address: Interface address
However, with that rule in place there is no possibility to determine at the destination host the origin source IP of concerned connections.
If you don't want that masquerading rule to be applied to connections from site A, copy that rule, and enter the site A LAN at source and check "Do not NAT". Then put the new rule above the other one.