大家好,欢迎来到IT知识分享网。
前面两篇文章《HUAWEI防火墙IPSEC配置一》和《HUAWEI防火墙IPSEC配置二》介绍了总部与分部间点对点和点对多点的IPSEC VPN配置方案。但有很多分支机构规模较小,上网采用普通拨号宽带,没有固定公网IP地址。对于这种情况,可以用IPSEC的IKE野蛮模式来解决,下面是具体方案。
======================================
方案说明:由于总部无法事先知道分部的出口地址,只能有分部首先发起访问总部,协商建立IPSEC VPN通道后,总部和分部就能正常互通了。
======================================
实验要求
总部内网与分部内网通过IPSEC VPN互通
总部出口采用固定IP方式,分部出口采用PPPOE拨号方式
实验拓扑说明
AR1模拟总部内部设备 FW1作为总部的网关接入ISP
AR2模拟分部内部设备 FW2作为分部的网关接入ISP
ISP模拟营运商和互联网
实验基础配置
ISP部分
system-view
sysname ISP
ip pool pool1
gateway-list 10.1.23.1
network 10.1.23.0 mask 255.255.255.0
aaa
local-user huawei password cipher huawei
local-user huawei service-type ppp
interface Virtual-Template1
ppp authentication-mode chap
remote address pool pool1
ip address 10.1.23.1 255.255.255.0
interface GigabitEthernet0/0/0
ip address 10.1.12.1 255.255.255.0
interface GigabitEthernet0/0/1
pppoe-server bind Virtual-Template 1
//配置原理参见以前PPPOE相关文章介绍
总部内网AR1配置
system-view
sysname ar1
interface GigabitEthernet0/0/0
ip address 192.168.1.100 255.255.255.0
ip route-static 0.0.0.0 0.0.0.0 192.168.1.254
分部内网AR2配置
system-view
sysname ar1
interface GigabitEthernet0/0/0
ip address 192.168.2.100 255.255.255.0
ip route-static 0.0.0.0 0.0.0.0 192.168.2.254
//常规配置
IPSEC VPN配置
总部防火墙FW1的配置,由于无法事先得知分部的出口地址,采用主模式加IPSEC 模板(MM+TE)配置方式
system-view
sysname FW1
acl number 3000
rule 5 permit ip source 192.168.1.0 0.0.0.255 destination 192.168.2.0 0.0.0.255
//配置从总部到分部的感兴趣流
ike proposal 10
q
ike peer 2_FW2
pre-shared-key Huawei@123
ike-proposal 10
//配置IKE参数,无需填写对端地址
ipsec proposal 10
q
ipsec policy-template t1 1
security acl 3000
ike-peer 2_FW2
proposal 10
ipsec policy ipsec 10 isakmp template t1
//配置IPSEC策略,采用模板的方式
interface GigabitEthernet1/0/0
ip address 192.168.1.254 255.255.255.0
interface GigabitEthernet1/0/1
ip address 10.1.12.254 255.255.255.0
ipsec policy ipsec
//出接口应用IPSEC策略
firewall zone trust
add interface GigabitEthernet1/0/0
firewall zone untrust
add interface GigabitEthernet1/0/1
//接口加入对应的安全区域
ip route-static 0.0.0.0 0.0.0.0 10.1.12.1
//配置默认路由
security-policy
default action permit
//放通安全策略,根据需要设置,这里为了实验放通所有
分部防火墙配置,采用PPPOE拨号方式获取地址,IPSEC采用野蛮模式(AM)配置方案。
sysname FW2
acl number 3000
rule 5 permit ip source 192.168.2.0 0.0.0.255 destination 192.168.1.0 0.0.0.255
//配置从分部到总部的感兴趣流
ike proposal 10
q
ike peer 2_FW1
exchange-mode aggressive
pre-shared-key Huawei@123
ike-proposal 10
remote-address 10.1.12.254
//配置IKE参数,协商采用野蛮模式AM
ipsec proposal 10
q
ipsec policy ipsec 10 isakmp
security acl 3000
ike-peer 2_FW1
proposal 10
//配置IPSEC策略
interface Dialer1
link-protocol ppp
ppp chap user huawei
ppp chap password cipher huawei
ppp ipcp dns admit-any
ip address ppp-negotiate
dialer user huawei
dialer bundle 1
dialer number 1 autodial
ipsec policy ipsec
//配置PPPOE拨号口,并应用IPSEC策略,PPPOE拨号原理和路由器一样,配置命令稍有区别
interface GigabitEthernet1/0/0
ip address 192.168.2.254 255.255.255.0
interface GigabitEthernet1/0/1
pppoe-client dial-bundle-number 1 ipv4
//绑定拨号口
firewall zone trust
add interface GigabitEthernet1/0/0
firewall zone untrust
add interface Dialer1
add interface GigabitEthernet1/0/1
//各接口加入对应区域,拨号也需要,不加区域的接口在FW上没有意义
ip route-static 0.0.0.0 0.0.0.0 Dialer1
//配置默认路由
security-policy
default action permit
//放通安全策略,根据需要设置,这里为了实验放通所有
实验结果验证。
首先从总部ping分部,发现无法联通。接着从分部ping总部,可以联通,再次测试从总部ping分部,没有任何问题。可见此方案需要从分部首先发起访问才能建立IPSEC VPN通道。
在总部防火墙上查看IKE SA 和IPSEC SA的信息,可以看到IPSEC VPN保护的数据详细信息
至此,实验成功。
本实验环境为华为ENSP模拟器
免责声明:本站所有文章内容,图片,视频等均是来源于用户投稿和互联网及文摘转载整编而成,不代表本站观点,不承担相关法律责任。其著作权各归其原作者或其出版社所有。如发现本站有涉嫌抄袭侵权/违法违规的内容,侵犯到您的权益,请在线联系站长,一经查实,本站将立刻删除。 本文来自网络,若有侵权,请联系删除,如若转载,请注明出处:https://haidsoft.com/169102.html