忍者ブログ

Mechatronics and Life

There is simply nothing of importance whatsoever.

[PR]

×

[PR]上記の広告は3ヶ月以上新規記事投稿のないブログに表示されています。新しい記事を書く事で広告が消えます。

IPv4 NAT on Ubuntu

Setting up my Ubuntu Router Box does require a bit of port forwarding and NAT work. I am glad that there's only 2 or 3 clients on my network at any moment of time.  Now I just have to get those configuration to come up when the router boots.  So far I have got ipv6 default route ppp0 working wherever ppp0 comes up. (ppp1 is my PPTP VPN which is useless at the moment)

-A PREROUTING -i ppp0 -p udp -m udp --dport 16384:16482 -j DNAT --to-destination 192.168.0.20
-A PREROUTING -i ppp0 -p udp -m udp --dport 5060:5061 -j DNAT --to-destination 192.168.0.20
-A POSTROUTING -o ppp0 -j MASQUERADE
-A POSTROUTING -o ppp1 -j MASQUERADE

I don't think I need "-A POSTROUTING -o ppp1 -j MASQUERADE" on my iptables anymore. I am not using my PPTP VPN anymore. It's not stable compared to OpenVPN which uses TLS/SSL and as such much more stable connection can be made over Windows/Linux.

PR