Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| networking:linux:iptables [20 years ago - 2005/11/23 20:27] – created aogail | networking:linux:iptables [19 years ago - 2007/05/28 06:45] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 2: | Line 2: | ||
| ===== Accept a Port/range ===== | ===== Accept a Port/range ===== | ||
| - | # iptables -A INPUT -p tcp -m tcp --dport 80 -j ACCEPT | + | |
| + | |||
| + | ===== Forward a Port/range ===== | ||
| + | * **Add the forwarding rule** | ||
| + | |||
| + | # iptables -t nat -I PREROUTING -i ethExternal -p tcp --dport 4662 -j DNAT --to 192.168.0.11: | ||
| + | |||
| + | * **Enable forwarding rule** | ||
| + | |||
| + | # iptables -I FORWARD -i ethExternal -p tcp -d 192.168.0.11/ | ||
| + | |||
| + | * **Add forwarding rule for internal hosts** | ||
| + | |||
| + | # iptables -I FORWARD -i ethExternal -p tcp -s 192.168.0.11/ | ||
| + | |||
| + | ===== Reference Links ===== | ||
| + | * [[http:// | ||