ensp华为防火墙的简单区域划分和配置

本文详细记录了一次实验,涉及PC和server通过USG6000V1防火墙的IP配置、安全区域设置(Trust和Untrust)、安全策略定义(允许ping流量)以及连通性测试。通过这个过程学习了防火墙的基础概念和配置技巧。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

实验环境

在这里插入图片描述

实验思路

  • 规划并配置IP
  • 设置安全区域
  • 设置安全策略
  • 检查连通性

具体实施

规划并配置IP:

PC1:

在这里插入图片描述

server1:

在这里插入图片描述

FW1:
[USG6000V1]int g1/0/1
[USG6000V1-GigabitEthernet1/0/1]undo  shutdown
[USG6000V1-GigabitEthernet1/0/1]ip address 192.168.1.254 24 
[USG6000V1-GigabitEthernet1/0/1]service-manage ping permit
[USG6000V1]int g1/0/0
[USG6000V1-GigabitEthernet1/0/0]undo  shutdown
[USG6000V1-GigabitEthernet1/0/0]ip address 200.2.2.254 24 
[USG6000V1-GigabitEthernet1/0/0]service-manage ping permit

设置安全区域:

FW1:
[USG6000V1]firewall zone trust
[USG6000V1-zone-trust]add interface g1/0/1
[USG6000V1]firewall zone untrust
[USG6000V1-zone-untrust]add interface g1/0/0

设置安全策略:

FW1:
[USG6000V1]security-policy
[USG6000V1-policy-security]rule name t-u
[USG6000V1-policy-security-rule-t-u]source-zone trust 
[USG6000V1-policy-security-rule-t-u]destination-zone  untrust
[USG6000V1-policy-security-rule-t-u]source-address 192.168.1.0 24 
[USG6000V1-policy-security-rule-t-u]action  permit

检查连通性:

PC1 ping server:
PC>ping 200.2.2.1

Ping 200.2.2.1: 32 data bytes, Press Ctrl_C to break From 200.2.2.1: bytes=32 seq=1 ttl=254 time=15 ms From 200.2.2.1: bytes=32 seq=2 ttl=254 time=16 ms From 200.2.2.1: bytes=32 seq=3 ttl=254 time<1 ms
From 200.2.2.1: bytes=32 seq=4 ttl=254 time<1 ms From 200.2.2.1: bytes=32 seq=5 ttl=254 time=16 ms

--- 200.2.2.1 ping statistics ---
5 packet(s) transmitted
5 packet(s) received 0.00% packet loss
round-trip min/avg/max = 0/9/16 ms

server ping PC1:

在这里插入图片描述

在这里插入图片描述

实验总结

本次实验学习了防火墙的原理和配置方法。防火墙用来 保护一个网络区域免受另外一个网络区域的攻击或入侵。本次实验主要介绍了安全区域和安全策略,而安全区域和安全策略是防火墙的重要组成部分。通过安全区域来划分网络以及标识报文的流动,以接口的划分来确认不同的安全区域。其中共有三个安全区域:Untrust、DMZ和Trust以及一个表示自身的Local区域。安全策略则用来检测和控制数据包的流动。与防火墙相连的网段无法直连,且在配置防火墙时不能自动连线,因为接口g0/0/0是管理口。

防火墙的基本配置在企业网络环境中至关重要,通过配置防火墙可以有效保护内部网络资源,防范外部威胁。以下是使用华为eNSP(Enterprise Network Simulation Platform)进行防火墙基本配置的步骤: 1. **设备连接与基本设置**: - 打开eNSP,添加一台防火墙设备(例如:USG6000系列)。 - 连接防火墙的接口到相应的网络设备(如交换机、PC等)。 2. **配置接口**: - 进入防火墙配置模式。 ```plaintext system-view ``` - 配置内网接口(例如:GigabitEthernet0/0/1)。 ```plaintext interface GigabitEthernet0/0/1 ip address 192.168.1.1 255.255.255.0 quit ``` - 配置外网接口(例如:GigabitEthernet0/0/2)。 ```plaintext interface GigabitEthernet0/0/2 ip address 203.0.113.1 255.255.255.0 quit ``` 3. **配置安全区域**: - 将接口划分到不同的安全区域。 ```plaintext security-zone trust add interface GigabitEthernet0/0/1 quit security-zone untrust add interface GigabitEthernet0/0/2 quit ``` 4. **配置NAT(网络地址转换)**: - 配置源NAT,使内部网络访问外部网络时使用防火墙的外网IP地址。 ```plaintext nat address-group 1 203.0.113.1 quit acl number 3000 rule permit ip source 192.168.1.0 0.0.0.255 quit interface GigabitEthernet0/0/2 nat outbound 3000 address-group 1 quit ``` 5. **配置访问控制列表(ACL)**: - 配置ACL以允许或拒绝特定流量。 ```plaintext acl number 3001 rule permit tcp source 192.168.1.0 0.0.0.255 destination 0.0.0.0 0.0.0.0 eq 80 rule deny ip quit interface GigabitEthernet0/0/2 traffic-filter outbound acl 3001 quit ``` 6. **配置安全策略**: - 配置安全策略以控制不同安全区域之间的流量。 ```plaintext security-policy rule name allow_http source-zone trust destination-zone untrust service http action permit quit quit ``` 7. **保存配置**: - 保存所有配置以防设备重启后丢失。 ```plaintext save ``` 通过以上步骤,您可以在eNSP中基本配置防火墙,确保内部网络的安全性。
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值