cisco asa l2tp over ipsec 配置详解
Cisco ASA L2TP over IPSEC 配置详解
1 创建×××地址池
ciscoasa(config)# ip local pool ***pool 192.168.151.11-192.168.151.15 mask 255.255.255.0
2 配置Ipsec 加密算法为3DES和SHA
ciscoasa(config)# crypto ipsec transform-set TRANS_ESP_3DES_SHA esp-3des esp-sha-hmac
3 配置IPSec传输模式为transport,默认为tunnel 模式(L2TP 只支持transport)
Ciscoasa(config)#crypto ipsec transform-set TRANS_ESP_3DES_SHA mode transport
4 使用传输组定义动态加密策略
Ciscoasa(config)# crypto dynamic-map outside_dyn_map 10 set transform-set TRANS_ESP_3DES_SHA
5 定义加密映射并应用到外网接口上(outside)
#crypto map outside_map 10 ipsec-isakmp dynamic outside_dyn_map
#crypto map outside_map interface outside
6 外网接口上开启isakmp策略支持
Ciscoasa(config) crypto isakmp enable outside
7 定义isakmp 策略
Ciscoasa(config)# crypto isakmp policy 10
ciscoasa(config-isakmp-policy)# authentication pre-share
ciscoasa(config-isakmp-policy)# encryption 3des
ciscoasa(config-isakmp-policy)# hash sha
ciscoasa(config-isakmp-policy)# group 2
ciscoasa(config-isakmp-policy)# lifetime 86400
ciscoasa(config-isakmp-policy)# exit
8 设置nat 穿越
ciscoasa(config)# crypto isakmp nat-traversal 10
9 配置默认内部组策略
ciscoasa(config)# group-policy DefaultRAGroup internal
10 配置默认内部组策略属性
ciscoasa(config)# group-policy DefaultRAGroup attributes
ciscoasa(config-group-policy)# ***-tunnel-protocol IPSec l2tp-ipsec
ciscoasa(config-group-policy)# default-domain value cisco.com
ciscoasa(config-group-policy)# dns-server value 202.96.209.133
注:配置L2TP over IPsec为***隧道的协议,必须要加IPSec,只有l2tp-ipsec,***是拨不通的
11创建本地用户,及为用户配置密码,并指明加密算法
ciscoasa(config)# username frank password frank mschap
12 创建默认的隧道组,一定要使用defaultRAGroup,L2TP不支持其他组,并定义认证方式为本地。
ciscoasa(config)# tunnel-group DefaultRAGroup general-attributes
ciscoasa(config-tunnel-general)# authentication-server-group LOCAL
ciscoasa(config-tunnel-general)# default-group-policy DefaultRAGroup
ciscoasa(config-tunnel-general)#address-pool ***pool
ciscoasa(config-tunnel-general)#exit
13 制定用户所在的组策略
ciscoasa(config-tunnel-general)#username frank attributes
ciscoasa(config-username)# ***-group-policy DefaultRAGroup
ciscoasa(config-username)# ***-tunnel-protocol IPSec l2tp-ipsec
ciscoasa(config-username)# exit
14 配置默认隧道组的ipsec属性,并配置默认隧道组认证方式为ms-chap-v2
ciscoasa(config)# tunnel-group DefaultRAGroup ppp-attributes
ciscoasa(config-ppp)# authentication ms-chap-v2
ciscoasa(config-ppp)#exit
15 客户端设置
Win 7 需要修改注册表
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\PolicyAgent]
"AssumeUDPEncapsulationContextOnSendRule"=dword:00000002
16 在客户端上创建连接到工作区域××× 连接,并设置*** 的属性