当前位置: 首页 > 图文教程 > 操作系统 > Unix/Linux > Linux下用Iptables配置简单网关

Unix/Linux
HP工程师经验分享(15)
HP工程师经验分享(14)
HP工程师经验分享(13)
HP工程师经验分享(12)
HP工程师经验分享(11)
HP工程师经验分享(10)
HP工程师经验分享(9)
HP工程师经验分享(8)
HP工程师经验分享(7)
HP工程师经验分享(6)
HP工程师经验分享(5)
HP工程师经验分享(4)
HP工程师经验分享(3)
HP工程师经验分享(1)
HP-UX常见问题解答(28)
HP-UX常见问题解答(27)
HP-UX常见问题解答(26)
HP-UX常见问题解答(25)
HP-UX常见问题解答(24)
HP-UX常见问题解答(23)

Unix/Linux 中的 Linux下用Iptables配置简单网关


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-01   浏览: 85 ::
收藏到网摘: n/a

##################echo 1 >/proc/sys/net/ipv4/ip_forward/sbin/modprobe ip_tables/sbin/modprobe iptable_filter/sbin/modprobe iptable_nat/sbin/modprobe ip_conntrack/sbin/modprobe ip_conntrack_ftp/sbin/modprobe ip_nat_ftp/sbin/iptables --flush INPUT/sbin/iptables --flush FORWARD/sbin/iptables --flush POSTROUTING --table nat/sbin/iptables --policy FORWARD DROP/sbin/iptables --table nat --append POSTROUTING --out-interface eth1 --source 192.168.2.0/24 --jump MASQUERADE/sbin/iptables --append FORWARD --in-interface eth1 --match state --state ESTABLISHED,RELATED --jump ACCEPT/sbin/iptables --append FORWARD --source 192.168.2.0/24 --jump ACCEPT###################