我有 CentOS 6 x86_64 vps 服务器。我刚刚创建了以下 iptables。但它给出了一条错误消息。我在这里做错了什么?
*filter
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [0:0]
:SERVICE - [0:0]
-A INPUT -i lo -j ACCEPT
-A INPUT -p icmp --icmp-type echo-request -m limit --limit 1/s --limit-burst 4 -j ACCEPT
-A INPUT -p tcp -m state --state ESTABLISHED,RELATED -j ACCEPT
-A INPUT -p tcp -m state --state NEW -j SERVICES
-A INPUT -p udp --sport 53 -j ACCEPT
-A INPUT -p udp --sport 123 --dport 123 -j ACCEPT
-A SERVICES -p tcp --dport 61203 -j ACCEPT
-A SERVICES -p tcp --dport 80 -j ACCEPT
-A SERVICES -p tcp --dport 443 -j ACCEPT
COMMIT
# service iptables start
iptables: Applying firewall rules: iptables-restore v1.4.7: Couldn't load target `SERVICES':/lib64/xtables/libipt_SERVICES.so: cannot open shared object file: No such file or directory
Error occurred at line: 9
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
答案1
:SERVICE - [0:0]
...
-A SERVICES -p tcp --dport 61203 -j ACCEPT
-A SERVICES -p tcp --dport 80 -j ACCEPT
-A SERVICES -p tcp --dport 443 -j ACCEPT
注意到这个问题了吗?
:)
提示:(鼠标悬停)
您的单数/复数不匹配。