我正在尝试通过发出以下命令将 CloudFlare 的 IP 地址列入我服务器上的白名单:
iptables -N whitelist
iptables -A whitelist -s 204.93.177.0/24 -j ACCEPT
iptables -A whitelist -s 199.27.128.0/21 -j ACCEPT
iptables -A whitelist -s 173.245.48.0/20 -j ACCEPT
iptables -A whitelist -s 103.22.200.0/22 -j ACCEPT
iptables -A whitelist -s 141.101.64.0/18 -j ACCEPT
iptables -A whitelist -s 108.162.192.0/18 -j ACCEPT
Run Code Online (Sandbox Code Playgroud)
当我输入:iptables -L我看到:
Chain whitelist (0 references)
target prot opt source destination
ACCEPT all -- network/24 anywhere
ACCEPT all -- 199.27.128.0/21 anywhere
ACCEPT all -- 173.245.48.0/20 anywhere
ACCEPT all …Run Code Online (Sandbox Code Playgroud)