Linux 防火墙命令一长就怕写错。做了个网页生成器:选引擎(iptables / nftables)、动作、链、协议、端口、来源,实时出命令,复制即用。
iptables 示例输出:
iptables -A INPUT -p tcp --dport 22 -s 192.168.1.0/24 -j ACCEPT
nftables 示例输出:
nft add rule inet filter INPUT ip protocol tcp th dport 22 ip saddr 192.168.1.0/24 accept
生成后请自己 review 再上机,别无脑贴。附件 fwgen.html 纯前端双击即用。开源。
楼主 · 2026-09-25 12:34 · 浏览 191
· 编辑于 2026-09-25 12:34

