码迷,mamicode.com
首页 > 其他好文 > 详细

iptables详细参数讲解

时间:2017-08-19 14:27:01      阅读:191      评论:0      收藏:0      [点我收藏+]

标签:port   tin   ble   option   列表   接口   端口   flush   interface   

table 表 --> chain 链 --->rule 规则
Commands:
Either long or short options are allowed.
--append -A chain 添加规则到链上
[!]--proto -p proto 指定过滤的协议tcp udp icmp all
[!]--source -s address[/mask][...]指定源地址
[!] --destination -d address[/mask][...]指定目标地址
[!] --in-interface -i input name[+] 进入的网络接口(eth1 eth0)
[!] --out-interface -o output name[+]出去的网络接口
--dport 指定目的端口
--jump -j target 对规则的具体处理方法(ACCEPT DROP REJECT)
(SNAT DNAT
--policy -P chain target 指定链的默认规则
--sport 指定源端口

--delete -D chain 删除链上的规则
--delete -D chain rulenum 根据规则号删除链
--insert -I chain [rulenum] 插入规则到第一行
--list -L [chain [rulenum]] 列表链里的所有规则
--numeric -n 以数字的形式显示规则 iptables -nL
--line-number 打印规则序号iptables -nL --line-num
--flush -F [chain] 清除一个链或所有链上的规则
--zero -Z [chain [rulenum]] 链的计数器
--new -N chain 用户自定义链
--delete-chain -X [chain] 删除用户自定义的链

iptables详细参数讲解

标签:port   tin   ble   option   列表   接口   端口   flush   interface   

原文地址:http://www.cnblogs.com/Carr/p/7396025.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!