I am trying to convert code I made on ubuntu work with osx. I do not know how to convert the iptables commands to ipfw commands. Any help would be appreciated.
Ubuntu Code:
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
ssh server -l root -w0:0
ifconfig tun0 10.0.0.1 netmask 255.0.0.0
route add -net 1.2.3.4 dev tun0
iptables -t nat -A OUTPUT -p all -d 15.0.0.5 -o tun0 -j DNAT --to-destination 10.0.0.5
route add -host 15.0.0.5 dev tun0
Mac OS X Code:
sysctl -w net.inet.ip.forwarding=1
HELP HERE PLEASE!
ssh server -l root -w0:0
ifconfig tun0 10.0.0.1 netmask 255.0.0.0
route add -net 1.2.3.4 dev tun0
HERE TOO HERE!
route add -host 15.0.0.5 dev tun0