当前位置: 首页 > news >正文

深圳网站建设 卓培训销售网站建设

深圳网站建设 卓,培训销售网站建设,云南网络公司网站建设,山东网络优化目录 1.命令行手册查缺补漏 2.开始练习,从最陌生的参数练习开启 2.1 --list-rules -S :打印链或所有链中的规则 2.2 --zero -Z 链或所有链中的零计数器 2.3 --policy -P 修改默认链的默认规则 2.4 --new -N 接下来练习添加和删除自定义链 1.命令行手册查缺补…

目录

1.命令行手册查缺补漏

2.开始练习,从最陌生的参数练习开启

2.1 --list-rules  -S :打印链或所有链中的规则

2.2 --zero -Z 链或所有链中的零计数器

 2.3 --policy  -P 修改默认链的默认规则

2.4 --new -N 接下来练习添加和删除自定义链


1.命令行手册查缺补漏

[root@ovn-center ~]# iptables --help
iptables v1.4.21Usage: iptables -[ACD] chain rule-specification [options]iptables -I chain [rulenum] rule-specification [options]iptables -R chain rulenum rule-specification [options]iptables -D chain rulenum [options]iptables -[LS] [chain [rulenum]] [options]iptables -[FZ] [chain] [options]iptables -[NX] chainiptables -E old-chain-name new-chain-nameiptables -P chain target [options]iptables -h (print this help information)Commands:
Either long or short options are allowed.--append  -A chain            Append to chain--check   -C chain            Check for the existence of a rule--delete  -D chain            Delete matching rule from chain--delete  -D chain rulenumDelete rule rulenum (1 = first) from chain--insert  -I chain [rulenum]Insert in chain as rulenum (default 1=first)--replace -R chain rulenumReplace rule rulenum (1 = first) in chain--list    -L [chain [rulenum]]List the rules in a chain or all chains--list-rules -S [chain [rulenum]]Print the rules in a chain or all chains--flush   -F [chain]          Delete all rules in  chain or all chains--zero    -Z [chain [rulenum]]Zero counters in chain or all chains--new     -N chain            Create a new user-defined chain--delete-chain-X [chain]          Delete a user-defined chain--policy  -P chain targetChange policy on chain to target--rename-chain-E old-chain new-chainChange chain name, (moving any references)
Options:--ipv4      -4              Nothing (line is ignored by ip6tables-restore)--ipv6      -6              Error (line is ignored by iptables-restore)
[!] --protocol  -p proto        protocol: by number or name, eg. `tcp'
[!] --source    -s address[/mask][...]source specification
[!] --destination -d address[/mask][...]destination specification
[!] --in-interface -i input name[+]network interface name ([+] for wildcard)--jump -j targettarget for rule (may load target extension)--goto      -g chainjump to chain with no return--match       -m matchextended match (may load extension)--numeric     -n              numeric output of addresses and ports
[!] --out-interface -o output name[+]network interface name ([+] for wildcard)--table       -t table        table to manipulate (default: `filter')--verbose     -v              verbose mode--wait        -w [seconds]    maximum wait to acquire xtables lock before give up--wait-interval -W [usecs]    wait time to try to acquire xtables lockdefault is 1 second--line-numbers                print line numbers when listing--exact       -x              expand numbers (display exact values)
[!] --fragment  -f              match second or further fragments only--modprobe=<command>          try to insert modules using this command--set-counters PKTS BYTES     set the counter during insert/append
[!] --version   -V              print package version.

2.开始练习,从最陌生的参数练习开启

2.1 --list-rules  -S :打印链或所有链中的规则

[root@ovn-center ~]# iptables --list-rules
-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
[root@ovn-center ~]# iptables -t nat --list-rules
-P PREROUTING ACCEPT
-P INPUT ACCEPT
-P OUTPUT ACCEPT
-P POSTROUTING ACCEPT
[root@ovn-center ~]# iptables -t filter -S
-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-A INPUT -s 10.10.10.3/32 -j DROP

2.2 --zero -Z 链或所有链中的零计数器

 2.3 --policy  -P 修改默认链的默认规则

在修改了filter表的INPUT默认规则为DROP时,直接断网 ,

也就是丢弃了所有一切进入主机的数据包

 需要给指定的链修改默认规则,而无法一次性全部修改

我们恢复规则继续测试

2.4 --new -N 接下来练习添加和删除自定义链

在filter表上添加一个链

iptables -t filter -N WEB

接着将WEB引用到filter表INPUT链,这样凡是目标端口是80,443的流量都将经过WEB链的规则

 删除自定义链表的时候,不能有引用和规则,需要清理关系和内部的规则

 

http://www.yayakq.cn/news/122077/

相关文章:

  • 盘锦市住房和城乡建设厅网站校园微信网站模板
  • 自己搭建一个网站网店推广实训标题优化答案
  • 在线商城网站建设seo费用
  • 石家庄网站建设雨点牛定制网络教研系统
  • 山东省建设局网站首页门户网站建设费用
  • 网站开发android客户端discuz x3 wordpress
  • 网站做nat映射需要哪些端口详情页设计要求
  • 在某网站被骗钱该怎么做青岛seo
  • 惠州网站建设公司排名网络推广公司营销策划
  • 做竞价可以让网站提高快速排名吗浙江杰立建设集团网站
  • 2024年还有新冠吗深圳公关公司首荐乐云seo
  • 青岛小型网站建设广州会议室租用
  • 深圳网站建设网页推广网站设计seo百度关键词优化软件
  • 廊坊市建设局网站seo综合查询国产
  • 网站主机类型wordpress rightlock
  • 网站带薪歌手都要怎样做呀帮企业建网站
  • 站点创建成功有影响吗wordpress chinacd
  • 大型的网站建设公司wordpress xml
  • 没有做网站地图影响大吗吗网站建设礼品
  • 杭州网站优化效果宁志网站两学一做
  • 网站个人备案做企业网站谷歌google
  • 年轻人必备的十大网站做彩妆网站的公司
  • 金泉网做网站电话个人网站一般做多大
  • 天津建设网站c2成绩查询网站运营学习
  • 科技网站建设+长沙石家庄软件开发定制
  • 云南网站设计联系方式中国招标信息网
  • 内销常用网站python3 做网站
  • 如何建立自己的购物网站自己创建网站要钱吗
  • 在线网站建设哪个正规华茂达建设集团网站
  • 怎么提高网站加载速度慢网站建站推广