IOS zone-pair 防火墙的配置解析

本文涉及的产品
云防火墙,500元 1000GB
云解析DNS-重点域名监控,免费拨测 20万次(价值200元)
简介:

关于zone-pair 防火墙是把ios路由器的接口分为若干个区域,不同区域之间的流量是不能通讯的,这点类似与ASA的接口类型!这里我们要注意一下几点

1.确定相同的安全接口划分到同一zone。

2.运用class-map 抓住不同zone之间的流量,可以提供3-7层的流量检测

 

ZBF(config-pmap-c)#?
Policy-map class configuration commands:
  drop            Drop the packet
  exit            Exit from class action configuration mode
  inspect         Context-based Access Control Engine
  no              Negate or set default values of a command
  pass            Pass the packet
  police          Police                       对流量执行限速
  service-policy  Deep Packet Inspection Engine  深度包检测
  urlfilter       URL Filtering Engine    URL过滤

3.对于那个方向没有流量就不用配置了,因为默认的就是不同zone之间不允许通讯

4.policy-map  service-map的运用

我们就结合下面的例子说下

 

要求:

Hosts in Internet zone can reach DNS, SMTP, and SSH services on one server in the DMZ. The other server
will offer SMTP, HTTP, and HTTPS services. The firewall policy will restrict access to the specific services
available on each host.
 The DMZ hosts cannot connect to hosts in any other zone.
 Hosts in the client zone can connect to hosts in the server zone on all TCP, UDP, and ICMP services.
 Hosts in the server zone cannot connect to hosts in the client zone, except a UNIX-based application server
can open X Windows client sessions to X Windows servers on desktop PCs in the client zone on ports 6900 to
6910.
 All hosts in the private zone (combination of clients and servers) can access hosts in the DMZ on SSH, FTP,
POP, IMAP, ESMTP, and HTTP services, and in the Internet zone on HTTP, HTTPS, and DNS services and
ICMP. Furthermore, application inspection will be applied on HTTP connections from the private zone to the
Internet zone in order to assure that supported instant messaging and P2P applications are not carried on port
80. (See Figure 3.)

配置

class-map type inspect match-any pr-to-DMZ-class
 match protocol ssh
 match protocol http
 match protocol pop3
 match protocol imap
class-map type inspect match-any pr-to-bublic
 match protocol http
 match protocol https
 match protocol dns
 match protocol icmp
class-map type inspect match-any dns-http-class
 match protocol dns
 match protocol http
class-map type inspect match-any smtp-class
 match protocol smtp
class-map type inspect match-all smtp-acl-class
 match access-group 111
 match class-map smtp-class
class-map type inspect match-any x-class
 match protocol uucp
class-map type inspect match-all client-to-server-class
 match protocol tcp
 match protocol udp
 match protocol icmp
class-map type inspect match-all dns-http-acl-class
 match access-group 110
 match class-map dns-http-class
!
!
policy-map type inspect server-to-client-policy
 class type inspect x-class
 class class-default
policy-map type inspect clinet-to-server-policy
 class type inspect client-to-server-class
  inspect
 class class-default
policy-map type inspect pr-to-public-policy
 class type inspect pr-to-bublic
  inspect
 class class-default
policy-map type inspect pr-to-DMZ-policy
 class type inspect pr-to-DMZ-class
  inspect
 class class-default
policy-map type inspect internet-dmz-policy
 class type inspect dns-http-acl-class
  inspect
 class type inspect smtp-acl-class
  inspect
 class class-default
!
zone security DMZ
zone security pr
zone security public
zone security server
zone security client
zone-pair security pr-to-public source pr destination public
 service-policy type inspect pr-to-public-policy
zone-pair security pr-to-DMZ source pr destination DMZ
 service-policy type inspect pr-to-DMZ-policy
zone-pair security public-to-DMZ source public destination DMZ
 service-policy type inspect internet-dmz-policy
zone-pair security servers-clients source server destination client
 service-policy type inspect server-to-client-policy
zone-pair security client-to-server source client destination server
 service-policy type inspect clinet-to-server-policy

interface FastEthernet0/0
 ip address 172.16.1.1 255.255.255.0
 zone-member security public
 duplex auto
 speed auto
interface FastEthernet0/1
 no ip address
 shutdown
 duplex auto
 speed auto
interface FastEthernet1/0
!
interface FastEthernet1/1
!
interface FastEthernet1/2
!
interface FastEthernet1/3
!
interface FastEthernet1/4
!
interface FastEthernet1/5
!
interface FastEthernet1/6
!
interface FastEthernet1/7
!
interface FastEthernet1/8
!
interface FastEthernet1/9
!
interface FastEthernet1/10
!
interface FastEthernet1/11
!
interface FastEthernet1/12
!
interface FastEthernet1/13
 no switchport
 ip address 172.16.2.1 255.255.255.0
 zone-member security DMZ
!
interface FastEthernet1/14
 switchport access vlan 2
!
interface FastEthernet1/15
!
interface Vlan1
 ip address 192.168.1.1 255.255.255.0
 zone-member security server
!
interface Vlan2
 ip address 192.168.2.1 255.255.255.0
 zone-member security client
!
router rip
 version 2
 network 172.16.0.0
 network 192.168.1.0
 network 192.168.2.0
 no auto-summary
!
ip route 0.0.0.0 0.0.0.0 172.16.1.2
!         
!
ip http server
no ip http secure-server
!
access-list 110 permit ip any host 172.16.2.2
access-list 111 permit ip any host 172.16.2.3

总结:这个配置挺麻烦的,其实核心不过是几个策略的应用,学过QOS的应该不陌生这不是和MQC有异曲同工之处吗

还有一点一个接口可以属于多个zone 在这个配置中int vlan 1既属于zone- security pr 又属于zone-security server  只不过这两个是相包含的关系,不知道是不是因为这样,大家谁做实验欢迎补充下

还有个细节文章没有说就是parmeter-map的应用,这个是具体制定协议参数的举个例子

 

 audit-trail off
 alert on
 max-incomplete low 800
 max-incomplete high 1000
 one-minute low unlimited
 one-minute high unlimited
 udp idle-time 30
 icmp idle-time 10
 dns-timeout 5
 tcp idle-time 3600
 tcp finwait-time 5
 tcp synwait-time 15
 tcp max-incomplete host unlimited block-time 0
 sessions maximum 2147483647

 

policy-map type inspect inside-to-outside.policy
 class type inspect inside-to-outside.class
  inspect inside-to-outside.pa   挂在policy-map下
 class class-default

本文转自q狼的诱惑 51CTO博客,原文链接:http://blog.51cto.com/liangrui/636039,如需转载请自行联系原作者
相关文章
|
9月前
|
存储 缓存 网络协议
阿里云特惠云服务器99元与199元配置与性能和适用场景解析:高性价比之选
2025年,阿里云长效特惠活动继续推出两款极具吸引力的特惠云服务器套餐:99元1年的经济型e实例2核2G云服务器和199元1年的通用算力型u1实例2核4G云服务器。这两款云服务器不仅价格亲民,而且性能稳定可靠,为入门级用户和普通企业级用户提供了理想的选择。本文将对这两款云服务器进行深度剖析,包括配置介绍、实例规格、使用场景、性能表现以及购买策略等方面,帮助用户更好地了解这两款云服务器,以供参考和选择。
|
9月前
|
域名解析 监控 网络协议
DNS防火墙软件版发布上线
DNS防火墙软件版发布,支持私有化部署,通过实时过滤和监控DNS流量,阻断恶意域名解析请求,从而防止用户或系统访问网络钓鱼网站、恶意软件分发站点等高风险目标。欢迎咨询购买
|
7月前
|
域名解析 应用服务中间件 Shell
使用nps配置内网穿透加域名解析
使用nps配置内网穿透加域名解析
817 76
|
4月前
|
网络协议 Linux 网络安全
CentOS防火墙管理:查询与配置开放端口的技巧
遵循以上步骤,CentOS系统管理员能够灵活地查询和管理系统端口的开放情况,并且能适用于大多数防火墙管理场合。务必在改变防火墙规则后认真审核和测试,以确保网络安全性与服务的正常运行。
715 0
|
7月前
|
Ubuntu 安全 Linux
CentOS与Ubuntu中防火墙配置命令集汇
有了这些,你就能遨游在 CentOS 和 Ubuntu 的海洋中,频繁地改变你的防火墙设置,快速地应对各种安全威胁,同时也能保证你的系统可以正常工作。出发吧,勇敢的编程者,随着这些命令集的涌动,扬帆起航,走向安全的网络世界!
222 5
|
9月前
|
Swift iOS开发 开发者
苹果app上架-ios上架苹果商店app store 之苹果支付In - App Purchase内购配置-优雅草卓伊凡
苹果app上架-ios上架苹果商店app store 之苹果支付In - App Purchase内购配置-优雅草卓伊凡
1242 13
苹果app上架-ios上架苹果商店app store 之苹果支付In - App Purchase内购配置-优雅草卓伊凡
|
9月前
|
监控 Shell Linux
Android调试终极指南:ADB安装+多设备连接+ANR日志抓取全流程解析,覆盖环境变量配置/多设备调试/ANR日志分析全流程,附Win/Mac/Linux三平台解决方案
ADB(Android Debug Bridge)是安卓开发中的重要工具,用于连接电脑与安卓设备,实现文件传输、应用管理、日志抓取等功能。本文介绍了 ADB 的基本概念、安装配置及常用命令。包括:1) 基本命令如 `adb version` 和 `adb devices`;2) 权限操作如 `adb root` 和 `adb shell`;3) APK 操作如安装、卸载应用;4) 文件传输如 `adb push` 和 `adb pull`;5) 日志记录如 `adb logcat`;6) 系统信息获取如屏幕截图和录屏。通过这些功能,用户可高效调试和管理安卓设备。
|
10月前
|
域名解析 网络协议 Ubuntu
DHCP与DNS的配置
通过这些步骤,您可以在Linux环境下成功配置和验证DHCP和DNS服务。希望这些内容对您的学习和工作有所帮助。
863 27
|
9月前
|
监控 算法 安全
基于 C# 的内网行为管理软件入侵检测算法解析
当下数字化办公环境中,内网行为管理软件已成为企业维护网络安全、提高办公效率的关键工具。它宛如一位恪尽职守的网络守护者,持续监控内网中的各类活动,以确保数据安全及网络稳定。在其诸多功能实现的背后,先进的数据结构与算法发挥着至关重要的作用。本文将深入探究一种应用于内网行为管理软件的 C# 算法 —— 基于二叉搜索树的入侵检测算法,并借助具体代码例程予以解析。
150 4
|
10月前
|
Java 数据库 开发者
详细介绍SpringBoot启动流程及配置类解析原理
通过对 Spring Boot 启动流程及配置类解析原理的深入分析,我们可以看到 Spring Boot 在启动时的灵活性和可扩展性。理解这些机制不仅有助于开发者更好地使用 Spring Boot 进行应用开发,还能够在面对问题时,迅速定位和解决问题。希望本文能为您在 Spring Boot 开发过程中提供有效的指导和帮助。
1195 12

推荐镜像

更多
  • DNS