IPFW IPFW port forwarding reach from local network

Dear All,

My wan ip: igb0: 192.168.19.2
Gateway: 192.168.19.1

Local Network: igb1: 192.168.75.0/24

I am using IPFW. I created port forwarding

ipfw nat 1 config if igb0 log redirect_port tcp 192.168.75.4:554 554

[root@FreeBSDBox ~]# ipfw list|grep nat

14500 nat 1 ip from any to any in recv igb0
14500 nat 1 ip from any to any out xmit igb0


from outside; port forwarding works well

I want to connect port forwarding from inside network with outside ip 192.168.19.2:554 but I cant.

What must I do?

Thanks for your help
 
1. run a tcp proxy and forget about nat alltogether
2. use something like named views so the name translates for diff ips when asked from outside,inside
3. try ipfw fwd but im not sure that will work
 
3. try ipfw fwd but im not sure that will work
It does not work because the destination address within the packet is not rewritten by fwd.
It does actually work with nat, but only in the special case when clients and servers are connected to the router (so that we can catch the answering traffic and translate it back), and the router does routing on layer-3 (no bridge). In that case the nat has to be placed additionally on igb1 (the inside facing interface), with proper ipfw rules selecting only the concerned traffic.
 
It does not work because the destination address within the packet is not rewritten by fwd.
It does actually work with nat, but only in the special case when clients and servers are connected to the router (so that we can catch the answering traffic and translate it back), and the router does routing on layer-3 (no bridge). In that case the nat has to be placed additionally on igb1 (the inside facing interface), with proper ipfw rules selecting only the concerned traffic.
tcpproxy works well without ipfw
 
Back
Top