全部博文(1144)
分类: LINUX
2008-11-28 01:21:43
成功的IPTABLES
echo "1" > /proc/sys/net/ipv4/ip_forward
echo "1" > /proc/sys/net/ipv4/tcp_syncookies
modprobe ip_tables
modprobe ip_nat_ftp
modprobe ip_conntrack
modprobe ip_conntrack_ftp
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
iptables -A FORWARD -s 192.168.0.98 -j ACCEPT
iptables -A FORWARD -d 192.168.0.98 -j ACCEPT
iptables -t nat -P PREROUTING ACCEPT
iptables -t nat -P POSTROUTING ACCEPT
iptables -t nat -P OUTPUT ACCEPT
iptables -t nat -A POSTROUTING -s 192.168.0.0/255.255.255.0 -j SNAT --to 116.6.47.11
chinaunix网友2008-11-28 13:42:58
iptables -P INPUT ACCEPT iptables -P FORWARD ACCEPT iptables -P OUTPUT ACCEPT 不清楚为啥楼主的默认策略如此设置。。。。。