8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4dd9b04 commit 80ca9b7Copy full SHA for 80ca9b7
command/iptables.md
@@ -71,6 +71,24 @@ iptables(选项)(参数)
71
-h:显示帮助信息;
72
```
73
74
+## 基本参数
75
+
76
+| 参数 | 作用 |
77
+| ---- | ---- |
78
+| -P | 设置默认策略:iptables -P INPUT (DROP|ACCEPT) |
79
+| -F | 清空规则链 |
80
+| -L | 查看规则链 |
81
+| -A | 在规则链的末尾加入新规则 |
82
+| -I | num 在规则链的头部加入新规则 |
83
+| -D | num 删除某一条规则 |
84
+| -s | 匹配来源地址IP/MASK,加叹号"!"表示除这个IP外。 |
85
+| -d | 匹配目标地址 |
86
+| -i | 网卡名称 匹配从这块网卡流入的数据 |
87
+| -o | 网卡名称 匹配从这块网卡流出的数据 |
88
+| -p | 匹配协议,如tcp,udp,icmp |
89
+| --dport num | 匹配目标端口号 |
90
+| --sport num | 匹配来源端口号 |
91
92
#### 命令选项输入顺序
93
94
0 commit comments