中国网络-ITPro俱乐部's Archiver

木头 发表于 2007-12-12 11:14

Dynamic Multipoint VPN

动态多点VPN (DMVPN) -顾名思义:DMVPN应用在多点到多点的复杂VPN网络环境中。
DMVPN的动态连接关系是通过hub-spokes模式来实现,它可以在两个或多个DMVPN成员的各自子网间动态建立基于GRE over ipsec连接的路由路径。根据目的前缀和下一跳结合路由协议来推断调用的GRE隧道和相关ipsec 保护策略。
DMVPN还要结合mGRE(Multipoint GRE interfaces)和NHRP(Next Hop Resolution Protocol)等相关知识。 大致流程:
1. 首先通过mGRE的封装代替p-t-p GRE封装来减少手动tunnel 数量及有效结合NHRP。
2. NHRP结合动态路由协议来支持mGRE的下一跳动态解析功能,以便根据路由协议动态建立保护网络间的临时tunnel.(保护网络要路由通告出去)
3. 在mGRE下采用ipsec profile 实现 ipsec automatic proxy 功能;保护gre封装流量,加密根据NHRP和动态路由协议建立起来的保护网络间的临时tunnel。(由于是动态方式,IKE isakmp remote peers 为 0.0.0.0)
[img]http://wartace.bokee.com/photo/view.fcgi?id=4628250&mode=3[/img][img]http://blogteam.bokee.com/pub/images/clarity.gif[/img][img]http://blogteam.bokee.com/pub/images/clarity.gif[/img]

配置案例 Hub Configuration for DMVPN
crypto isakmp policy 1
authentication pre-share
crypto isakmp key ikecisco address 0.0.0.0
!
crypto ipsec transform-set myset esp-des esp-md5-hmac
mode transport
!
crypto ipsec profile vpnprof
set transform-set myset
!
interface Tunnel0
bandwidth 1000
ip address 10.0.0.1 255.255.255.0
ip mtu 1416(确保大包在加密之前分片,目的设备正常重组)
ip nhrp authentication nhrp-pwd(nhrp认证,在匹配后,调用mGRE属性)
ip nhrp map multicast dynamic(启用NHRP自动加入分支路由器到多播NHRP映射组中)
ip nhrp network-id 99(启用NHRP,在匹配后,调用mGRE属性)
ip nhrp holdtime 300
no ip split-horizon eigrp 1(当使用EIGRP协议时,屏蔽水平分割)
no ip next-hop-self eigrp 1 (当使用EIGRP时,直接建立动态SPOKE-TO-SPOKE隧道)
delay 1000
tunnel source Ethernet0
tunnel mode gre multipoint(设置隧道接口的封装模式为mGRE)
tunnel key cisco (tunnel 认证)
tunnel protection ipsec profile vpnprof(为隧道接口指定IPSEC模板)
!
interface Ethernet0
ip address 172.17.0.1 255.255.255.0
!
interface Ethernet1
ip address 192.168.0.1 255.255.255.0
!
router eigrp 1
network 10.0.0.0 0.0.0.255 area 0
network 192.168.0.0 0.0.0.255 area 0
Spoke Configuration for DMVPN
crypto isakmp policy 1
authentication pre-share
crypto isakmp key ikecisco address 0.0.0.0
!
crypto ipsec transform-set myset esp-des esp-md5-hmac
mode transport
!
crypto ipsec profile vpnprof
set transform-set myset
!
interface Tunnel0
bandwidth 1000
ip address 10.0.0.2 255.255.255.0
ip mtu 1416
ip nhrp authentication nhrp-pwd
ip nhrp map 10.0.0.1 172.17.0.1(为NHRP server hub 隧道地址10.0.0.1做物理地址绑定)
ip nhrp map multicast 172.17.0.1(在分支和HUB之间启动动态路由协议,并发送多播包到HUB路由器上)
ip nhrp network-of 99
ip nhrp holdtime 300
ip nhrp nhs 10.0.0.1(配置HUB路由器作为NHRP的下一跳服务器)
delay 1000
tunnel source Ethernet0
tunnel mode gre multipoint
tunnel key cisco
tunnel protection ipsec profile vpnprof
!
interface Ethernet0
ip address 172.16.0.2 255.255.255.0
!
interface Ethernet1
ip address 192.168.1.1 255.255.255.0
!
router eigrp 1
network 10.0.0.0 0.0.0.255
network 192.168.1.0 0.0.0.255
配置结果就可以动态建立保护网络间的隧道及加密保护网络间的数据,具体细节可参考cisco cd-rom.

页: [1]

Powered by Discuz! Archiver 7.0.0  © 2001-2009 Comsenz Inc.