Hi,
I've question regarding the OpenVPN.
I have FreeBSD 13 running OpenVPN. The FreeBSD server has tun0 (10.8.0.0/24) and geneth0 (192.168.1.0/24 -"server network"). On the client (with subnet 192.168.1.0/24 - no relation to "server network"), I'm connecting to the OpenVPN. Now I want connect from the client through OpenVPN to some host on "server network" (192.168.1.0/24). What I want is to remap server's network 192.168.1.0/24 to 10.8.1.0/24. On debian this was done using this:
Is something like this possible also using FreeBSD? I'm using PF and try to used NAT there, but it didn't worked.
Appreciate any help.
I've question regarding the OpenVPN.
I have FreeBSD 13 running OpenVPN. The FreeBSD server has tun0 (10.8.0.0/24) and geneth0 (192.168.1.0/24 -"server network"). On the client (with subnet 192.168.1.0/24 - no relation to "server network"), I'm connecting to the OpenVPN. Now I want connect from the client through OpenVPN to some host on "server network" (192.168.1.0/24). What I want is to remap server's network 192.168.1.0/24 to 10.8.1.0/24. On debian this was done using this:
Code:
# Remap our network 1:1 to a different IP space. Update openvpn.conf file too
# push "route 10.8.1.0 255.255.0.0"
iptables -w -t nat -A PREROUTING -i $WLAN -d 10.8.1.0/24 -j NETMAP --to 192.168.1.0/24
iptables -w -t nat -A POSTROUTING -o vmbr0 -j MASQUERADE
Is something like this possible also using FreeBSD? I'm using PF and try to used NAT there, but it didn't worked.
Appreciate any help.