IPTables 在启动时中断 WebServer 连接
IPTables disrupts WebServer Connections on Startup
好吧,在我过去编码和使用 Linux 的经验中,这种情况以前从未发生过,但现在,当我启动 IPTables 时,我无法以任何可能的方式访问我的网站。 SSH 仍然有效。
我的操作系统:
CentOS Linux release 7.2.1511 (Core)
我的 IPTables 里面的东西:
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall
# please do not ask us to add additional ports/services to this default configuration
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -p icmp -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -p tcp -m state --state NEW -m tcp --dport 22 -j ACCEPT
-A INPUT -j REJECT --reject-with icmp-host-prohibited
-A FORWARD -j REJECT --reject-with icmp-host-prohibited
COMMIT
如果有人能帮我解决这个问题,那就太好了。
iptables -I INPUT 3 -p tcp -m state --state NEW -m tcp -m multiport --dports 80,443 -j ACCEPT
要是能看一下iptables的说明书就好了
好吧,在我过去编码和使用 Linux 的经验中,这种情况以前从未发生过,但现在,当我启动 IPTables 时,我无法以任何可能的方式访问我的网站。 SSH 仍然有效。
我的操作系统:
CentOS Linux release 7.2.1511 (Core)
我的 IPTables 里面的东西:
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall
# please do not ask us to add additional ports/services to this default configuration
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -p icmp -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -p tcp -m state --state NEW -m tcp --dport 22 -j ACCEPT
-A INPUT -j REJECT --reject-with icmp-host-prohibited
-A FORWARD -j REJECT --reject-with icmp-host-prohibited
COMMIT
如果有人能帮我解决这个问题,那就太好了。
iptables -I INPUT 3 -p tcp -m state --state NEW -m tcp -m multiport --dports 80,443 -j ACCEPT
要是能看一下iptables的说明书就好了