computers:firewall_configuration
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| computers:firewall_configuration [2011/08/31 12:24] – chkuo | computers:firewall_configuration [2020/08/16 00:13] (current) – [References] chkuo | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| net.ipv4.ip_forward=1 | net.ipv4.ip_forward=1 | ||
| </ | </ | ||
| + | Apply by '' | ||
| Then add the following lines to ''/ | Then add the following lines to ''/ | ||
| Line 12: | Line 13: | ||
| Ext_IF=" | Ext_IF=" | ||
| Ext_IP=" | Ext_IP=" | ||
| - | Int_IF=" | + | Int_IF=" |
| - | iptables -t nat -A POSTROUTING -s 192.168.1.0/ | + | Int_Net=" |
| - | iptables -A FORWARD -s 192.168.1.0/ | + | iptables -t nat -A POSTROUTING -s $Int_Net |
| - | iptables -A FORWARD -d 192.168.1.0/ | + | iptables -A FORWARD -s $Int_Net |
| + | iptables -A FORWARD -d $Int_Net | ||
| </ | </ | ||
| Line 21: | Line 23: | ||
| <code bash> | <code bash> | ||
| # destination NAT | # destination NAT | ||
| - | # forward ssh to Int_IP if the public | + | # forward ssh to Int_IP if the external IP Ext_IP_2 was used |
| Ext_IP_2=" | Ext_IP_2=" | ||
| Int_IP=" | Int_IP=" | ||
| Line 39: | Line 41: | ||
| ===== References ===== | ===== References ===== | ||
| * [[https:// | * [[https:// | ||
| + | * [[https:// | ||
computers/firewall_configuration.1314764641.txt.gz · Last modified: by chkuo