比思論壇

標題: 查看本机关于IPTABLES的设置情况 [打印本頁]

作者: zhaoxu6679    時間: 2014-7-13 15:51
標題: 查看本机关于IPTABLES的设置情况
[root@tp ~]# iptables -L -n
Chain INPUT (policy ACCEPT)
target       prot opt source                 destination         

Chain FORWARD (policy ACCEPT)
target       prot opt source                 destination         

Chain OUTPUT (policy ACCEPT)
target       prot opt source                 destination         

Chain RH-Firewall-1-INPUT (0 references)
target       prot opt source                 destination         
ACCEPT       all    --    0.0.0.0/0              0.0.0.0/0           
ACCEPT       icmp --    0.0.0.0/0              0.0.0.0/0             icmp type 255
ACCEPT       esp    --    0.0.0.0/0              0.0.0.0/0           
ACCEPT       ah     --    0.0.0.0/0              0.0.0.0/0           
ACCEPT       udp    --    0.0.0.0/0              224.0.0.251           udp dpt:5353
ACCEPT       udp    --    0.0.0.0/0              0.0.0.0/0             udp dpt:631
ACCEPT       all    --    0.0.0.0/0              0.0.0.0/0             state RELATED,ESTABLISHED
ACCEPT       tcp    --    0.0.0.0/0              0.0.0.0/0             state NEW tcp dpt:22
ACCEPT       tcp    --    0.0.0.0/0              0.0.0.0/0             state NEW tcp dpt:80
ACCEPT       tcp    --    0.0.0.0/0              0.0.0.0/0             state NEW tcp dpt:25
REJECT       all    --    0.0.0.0/0              0.0.0.0/0             reject-with icmp-host-prohibited
可以看出我在安装linux时,选择了有防火墙,并且开放了22,80,25端口.

如果你在安装linux时没有选择启动防火墙,是这样的
[root@tp ~]# iptables -L -n
Chain INPUT (policy ACCEPT)
target       prot opt source                 destination         
Chain FORWARD (policy ACCEPT)
target       prot opt source                 destination         
Chain OUTPUT (policy ACCEPT)
target       prot opt source                 destination  
什么规则都没有.



作者: DoctorNo1    時間: 2014-7-13 16:02
还是linux啊
作者: zzs1993    時間: 2014-7-13 16:26
这是什么
作者: exal1234    時間: 2014-7-14 10:35
赞赞




歡迎光臨 比思論壇 (http://108.170.10.234/) Powered by Discuz! X2.5