【发布时间】:2012-02-03 21:19:01
【问题描述】:
我的网络系统 ip 在 192.168.211.0/24 范围内。我在 192.168.211.50 上有一个 Web 服务器。我只想从 192.168.211.0/24 范围接收数据包到我的 Web 服务器。如何在 Ubuntu 中使用 iptable 进行配置?
【问题讨论】:
标签: security networking ubuntu iptables
我的网络系统 ip 在 192.168.211.0/24 范围内。我在 192.168.211.50 上有一个 Web 服务器。我只想从 192.168.211.0/24 范围接收数据包到我的 Web 服务器。如何在 Ubuntu 中使用 iptable 进行配置?
【问题讨论】:
标签: security networking ubuntu iptables
iptables -I INPUT 1 -s 192.168.211.0/24 -j ACCEPT
iptables -I INPUT 2 -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -I INPUT 3 -j DROP
【讨论】: