返回首页
网站导航
资讯首页> 网站公告 >产品资讯 > 汇总华为防火墙常见的几种配置案例

    汇总华为防火墙常见的几种配置案例

    产品资讯2018年07月31日
    分享
      华为防火墙的作用是通过静态IP地址接入Internet,并为内部网络提供网络访问服务。目前,某企业在网络边界处部署了NGFW作为安全网关,并从运营商处购买了宽带上网服务,实现内部网络接入Internet的需求。内部网络中的PC使用私网网段10.3.0.0/24实现互通,要求由NGFW为PC分配私网地址、 DNS服务器地址等网络参数,减少管理员手工配置的劳动量。而且内部网络中的PC可以访问Internet。那么,应该如何实现这种配置?
      
      一、配置思路
      
      1. 配置接口的地址,并将接口加入相应的安全区域。在配置接口GigabitEthernet 1/0/1
      
      的地址时,同时指定默认网关为1.1.1.254。
      
      2. 配置DHCP服务器功能,为内部网络中的PC分配IP地址和DNS服务器地址。
      
      3. 配置安全策略,允许内部网络中的PC访问Internet。
      
      4. 配置NAT策略, 提供源地址转换功能。由于使用运营商分配的固定公网地址作为转
      
      换后的地址,故采用Easy-IP方式的NAT策略,简化配置。
      
      5. 在运营商网络的设备上配置回程路由,该配置由运营商完成,本举例中不作介绍。
      
      二、操作步骤
      
      步骤1 配置接口GigabitEthernet 1/0/1。
      
      1. 选择“网络 > 接口”。
      
      2. 单击GE1/0/1对应的 ,按如下参数配置。
      
      安全区域
      
      untrust
      
      模式
      
      路由
      
      IPv4
      
      连接类型
      
      静态IP
      
      IP地址
      
      1.1.1.1/255.255.255.0
      
      默认网关
      
      1.1.1.254
      
      3. 单击“确定”。
      
      步骤2 配置接口GigabitEthernet 1/0/3。
      
      1. 选择“网络 > 接口”。
      
      2. 单击GE1/0/3对应的 ,按如下参数配置。
      
      安全区域
      
      trust
      
      模式
      
      路由
      
      IPv4
      
      连接类型
      
      静态IP
      
      HUAWEI USG6000 系列 & NGFW Module
      
      典型配置案例 2 接入 Internet
      
      IP地址
      
      10.3.0.1/255.255.255.0
      
      3. 单击“确定”。
      
      步骤3  配置DHCP服务器。
      
      1. 选择“网络 > DHCP服务器 > 服务”。
      
      2. 单击“新建”,按如下参数配置。
      
      汇总华为防火墙常见的几种配置案例
      
      3. 单击“确定”。
      
      步骤4 配置安全策略,允许内部网络中的PC访问Internet。
      
      1. 选择“策略 > 安全策略”。
      
      2. 单击“新建”,按如下参数配置。
      
      此处只给出了完成本举例所需的安全策略的基本参数, 具体使用时,请根据实际情
      
      况设置安全策略中的其他参数。
      
      汇总华为防火墙常见的几种配置案例
      
      3. 单击“确定”。
      
      步骤5 配置NAT策略,当内部网络中的PC访问Internet时进行地址转换。
      
      1. 选择“策略 > NAT策略 > 源NAT”。
      
      2. 在“源NAT策略列表”中单击“新建”,按如下参数配置。
      
      HUAWEI USG6000 系列 & NGFW Module
      
      典型配置案例 2 接入 Internet
      
      汇总华为防火墙常见的几种配置案例
      
      3. 单击“确定”。
      
      ----结束
      
      三、结果验证
      
      1. 检查接口GigabitEthernet 1/0/1的状态。
      
      a. 选择“网络 > 接口”。
      
      b. 查看接口GigabitEthernet 1/0/1的公网地址配置是否正确,物理状态和IPv4状态
      
      是否为Up。
      
      2. 在内部网络中的PC上通过ipconfig/all命令检查网卡是否正确分配到私网地址和DNS
      
      地址。此处以Windows XP操作系统为例,其它操作系统请以实际显示情况为准。
      
      Ethernet adapter 本地连接:
      
      Connection-specific DNS Suffix . :
      
      Description . . . . . . . . . . . : Intel(R) 82574L Gigabit Network Connection
      
      Physical Address. . . . . . . . . : 00-1B-21-B4-0B-35
      
      Dhcp Enabled. . . . . . . . . . . : Yes
      
      Autoconfiguration Enabled . . . . : Yes
      
      IP Address. . . . . . . . . . . . : 10.3.0.2
      
      Subnet Mask . . . . . . . . . . . : 255.255.255.0
      
      Default Gateway . . . . . . . . . : 10.3.0.1
      
      DHCP Server . . . . . . . . . . . : 10.3.0.1
      
      DNS Servers . . . . . . . . . . . : 9.9.9.9
      
      Lease Obtained. . . . . . . . . . : 2012年8月2日 9:38:14
      
      Lease Expires . . . . . . . . . . : 2012年8月13日 9:38:14
      
      3. 检查内部网络中的PC是否能通过域名访问Internet,若能访问,则表示配置成功。
      
      否则,请检查配置。
      
      四、配置脚本
      
      #
      
      sysname NGFW
      
      #
      
      HUAWEI USG6000 系列 & NGFW Module
      
      典型配置案例 2 接入 Internet
      
      interface GigabitEthernet1/0/1
      
      ip address 1.1.1.1 255.255.255.0
      
      #
      
      interface GigabitEthernet1/0/3
      
      ip address 10.3.0.1 255.255.255.0
      
      dhcp select interface
      
      dhcp server ip-range 10.3.0.1 10.3.0.254
      
      dhcp server gateway-list 10.3.0.1
      
      dhcp server dns-list 9.9.9.9
      
      #
      
      firewall zone trust
      
      set priority 85
      
      add interface GigabitEthernet1/0/3
      
      #
      
      firewall zone untrust
      
      set priority 5
      
      add interface GigabitEthernet1/0/1
      
      #
      
      ip route-static 0.0.0.0 0.0.0.0 GigabitEthernet1/0/1 1.1.1.254
      
      #
      
      security-policy
      
      rule name policy_sec_1
      
      source-zone trust
      
      destination-zone untrust
      
      source-address 10.3.0.0 24
      
      action permit
      
      #
      
      nat-policy
      
      rule name policy_nat_1
      
      source-zone trust
      
      egress-interface GigabitEthernet1/0/1
      
      source-address 10.3.0.0 24
      
      action nat easy-ip
      
      #
      
      return  

    相关阅读