华强电子网

电子元器件
采购信息平台

扫码下载
手机洽洽

  • 微信小程序

    让找料更便捷

  • 扫码下载手机洽洽

    随时找料

    即刻洽谈

    点击下载PC版
  • 华强电子网公众号

    电子元器件

    采购信息平台

  • 华强电子网移动端

    生意随身带

    随时随地找货

  • 华强商城公众号

    一站式电子元器件

    采购平台

  • 芯八哥公众号

    半导体行业观察第一站

Cisco SSL VPN 配置详解 图文

来源:互联网 作者:华仔 浏览:1241

标签: vpn

摘要: 基于SSL、DTLS和IPsec的完全网络远程访问--完全网络访问几乎能够为任何应用或网络资源提供网络层远程用户连接,而且通常能够将接入扩展到托管计算机,例如公司拥有的笔记本电脑。建立连接时,可以使用自动下载的Cisco AnyConnect VPN Client、Cisco IPsec VPN Client 以及 Microsoft和 Mac OS X第2层通道协议(L2TP)/IPsec VP

基于SSL、DTLS和IPsec的完全网络远程访问--完全网络访问几乎能够为任何应用或网络资源提供网络层远程用户连接,而且通常能够将接入扩展到托管计算机,例如公司拥有的笔记本电脑。建立连接时,可以使用自动下载的Cisco AnyConnect VPN Client、Cisco IPsec VPN Client 以及 Microsoft和 Mac OS X第2层通道协议(L2TP)/IPsec VPN Client。Cisco AnyConnect VPN Client 将自动基于网络限制使其通道协议适应最有效的方法。这是使用 DTLS 协议为延迟敏感型流量提供优化连接的第一种 VPN 产品,例如IP语音(VoIP)流量或基于 TCP 的应用接入。

试验目的:

掌握SSL VPN的配置步骤

掌握如何安装SSL VPN client

试验准备工作:

路由器IOS使用 c7200-advipservicesk9_li-mz。124-11。t。bin

SSL VPN 客户端软件:sslclient-win-1.1.3.173.pkg

此文件可以从Cisco站点下载,或者SDM 2.4.1软件的安装包,默认就自带此版本

试验拓扑: image 试验过程: 第一步:对路由器进行基础配置,测试直连通讯是否正常

SSL#sh ip int brief

Interface IP-Address OK? Method Status Protocol

FastEthernet0/0 unassigned YES unset administratively down down

FastEthernet0/1 unassigned YES unset administratively down down

SSL#conf t

Enter configuration commands, one per line. End with CNTL/Z.

SSL(config)#int f0/0

SSL(config-if)#ip add 192.168.10.11 255.255.255.0

SSL(config-if)#no sh

SSL(config-if)#int f0/1

SSL(config-if)#ip add 192.168.204.11 255.255.255.0

SSL(config-if)#no sh

SSL(config-if)#end

SSL#ping 192.168.10.1

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 192.168.10.1, timeout is 2 seconds:

.!!!!

Success rate is 80 percent (4/5), round-trip min/avg/max = 4/35/84 ms

SSL#ping 192.168.204.11

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 192.168.204.11, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/8 ms

SSL#

第二步:将SSL VPN Server的时间设置准确,已保证能客户端时间同步

SSL(config)#clock timezone UTC +8

SSL(config)#exit

SSL#clock set 18:38:00 24 Mar 2010

SSL#

Mar 24 10:38:00.003: %SYS-6-CLOCKUPDATE: System clock has been updated from 18:37:25 UTC Wed Mar 24 2010 to 18:38:00 UTC Wed Mar 24 2010, configured from console by console.

SSL#

SSL#show clock

18:38:46.483 UTC Wed Mar 24 2010

第三步:将Cisco SSL VPN Client软件,使用TFTP Server安装到路由器的disk0:中,并完成初始化安装

SSL#format disk0:

Format operation may take a while. Continue? [confirm]

Format operation will destroy all data in "disk0:". Continue? [confirm]

Format: Drive communication & 1st Sector Write OK...

Writing Monlib sectors.

.....................................................................................................................................................

Monlib write complete

Format: All system sectors written. OK...

Format: Total sectors in formatted partition: 130883

Format: Total bytes in formatted partition: 67012096

Format: Operation completed successfully.

Format of disk0 complete

SSL#copy tftp disk0:

Address or name of remote host []? 192.168.10.1

Source filename []? sslclient-win-1.1.3.173.pkg

Destination filename [sslclient-win-1.1.3.173.pkg]?

Accessing tftp://192.168.10.1/sslclient-win-1.1.3.173.pkg...

Loading sslclient-win-1.1.3.173.pkg from 192.168.10.1 (via FastEthernet0/0): !!

[OK - 416354 bytes]

416354 bytes copied in 16.064 secs (25918 bytes/sec)

SSL#dir disk0:

Directory of disk0:/

1-rw- 416354 Mar 24 2010 18:45:20 +08:00 sslclient-win-1.1.3.173.pkg

66846720 bytes total (66428928 bytes free)

使用webvpn 命令将sslclient完成初始化安装


SSL(config)#webvpn install svc disk0:/sslclient-win-1.1.3.173.pkg

SSLVPN Package SSL-VPN-Client : installed successfully

SSL(config)#exit

SSL#dir disk0:

Directory of disk0:/

1 drw- 0 Mar 24 2010 18:50:46 +08:00 webvpn

66846720 bytes total (66424832 bytes free)

第四步:启用AAA,并配置SSL VPN Client拨号的用户名和密码,并指定认证方式为AAA 本地认证,配置分配给SSL client地址池范围

SSL(config)#aaa new-model

SSL(config)#aaa authentication login webvpn local

SSL(config)#

SSL(config)#username admin privilege 15 password admin


在路由器创建回环接口来模拟SSL VPN Client的网关地址,并定义地址池

SSL(config)#int lo0

SSL(config-if)#ip add 192.168.0.254 255.255.255.0

SSL(config-if)#exit

SSL(config)#ip local pool sslvpn-pool 192.168.0.100 192.168.0.253 第五步:定义Webvpn的策略集,指定客户端的访问地址,端口等信息

//配置webvpn的网名名称为VPNGW


SSL(config)#webvpn gateway VPNGW

% Generating 1024 bit RSA keys, keys will be non-exportable...[OK]

SSL(config-webvpn-gateway)#?

SSLVPN Gateway Submode commands:

exit Exit from gateway configuration mode

hostname Hostname used in URL & Cookie mangling

http-redirect enable HTTP redirect feature

inservice Enable webvpn gateway

ip Virtual Gateway IP config

no Negate or set default values of a command

ssl SSL configurations for front end client connections

//配置虚拟网关IP,以及开放的端口

SSL(config-webvpn-gateway)#ip address 192.168.204.11 port 443

//开启webvpn网关服务

SSL(config-webvpn-gateway)#inservice 第六步:关联地址池,关联AAA认证策略,定义Client拨号的策略,以及DNS地址等

SSL(config)#webvpn context WEBTEXT

//关联虚拟网关的名称

SSL(config-webvpn-context)#gateway VPNGW

SSL(config-webvpn-context)#

//关联AAA认证策略

SSL(config-webvpn-context)#aaa authentication list webvpn

//开启服务

SSL(config-webvpn-context)#inservice

SSL(config-webvpn-context)#

Mar 24 11:06:02.687: %SSLVPN-5-UPDOWN: sslvpn context : WEBTEXT changed state to UP

//定义策略组的名称为SSLVPN-POLICY

SSL(config-webvpn-context)#policy group SSLVPN-POLICY

SSL(config-webvpn-group)#functions svc-enabled

//关联地址池名称

SSL(config-webvpn-group)#svc address-pool sslvpn-pool

SSL(config-webvpn-group)#banner "This IS Cisco IOS SSL VPN "

//配置首选DNS,备用DNS地址

SSL(config-webvpn-group)#svc dns-server primary 218.30.19.40

SSL(config-webvpn-group)#svc dns-server secondary 61.134.1.4

SSL(config-webvpn-group)#svc split include 192.168.10.0 255.255.255.0

SSL(config-webvpn-group)#exit

//应用到默认的策略组

SSL(config-webvpn-context)#default-group-policy SSLVPN-POLICY

SSL(config-webvpn-group)#exit

SSL(config-webvpn-context)#exit

SSL(config)#exit

SSL#write memory

Building configuration...

[OK]


第七步:因为SSL VPN Client软件,目前还不支持windows 7平台,故拨号我将在windows XP 环境下进行。使用https的方式访问SSL VPN SERVER,Windows XP 必须先安装jre,SSL VPN Client是基于jAVA环境运行的。 设置IE6允许弹出窗口 image

打开IE浏览器,使用https方式登录到SSL VPN SERVER,当弹出安全警报时,点击是

image

继续点击是接受安全警报

image

此时将进入 WEBVPN Service,登录页面,输入SSL VPN server上定义的拨号用户名和密码

image

此时,开始进入会话初始化阶段,将看到我们定义的banner消息

image

image

第八步:从路由器上下载SSL VPN Client,安装到XP上

如果IE6的安全级别为默认的设置,将不会主动安装ActiveX控件,此时会弹出窗口,询问我们是否安装非活动ActiveX控件,如下图所示:点击安装ActiveX控件,浏览器将从VPN Server上下载安装SSL VPN client软件,注意观察,浏览器已经正常加载了Java。

image

点击yes同意安装协议

image

如图所示:已经从VPN client成功下载完Cisco SSL VPN Client,点击安装

image

安装进行时,请稍等。。。。。。

image

SSL VPN 认证过程中,提示找不到有效证书,点击是下载安装证书

image

点击安装证书,将证书安装到系统当中

image

下一步

image

选择默认安装路径即可,下一步

image

点击是确认安装此证书

image

image

证书完成之后,再次发起连接,尝试进入SSL VPN Client拨号阶段,点击是

image

正在建立连接中

image

SSL VPN Client会话已经建立完成,VPN拨入成功

image

双击金黄色钥匙图标,查看连接状态的,路由信息等,客户端成功建立之后,从定义的地址池中获得IP地址为192.168.0.100

image

基于SSL、DTLS和IPsec的完全网络远程访问--完全网络访问几乎能够为任何应用或网络资源提供网络层远程用户连接,而且通常能够将接入扩展到托管计算机,例如公司拥有的笔记本电脑。建立连接时,可以使用自动下载的Cisco AnyConnect VPN Client、Cisco IPsec VPN Client 以及 Microsoft和 Mac OS X第2层通道协议(L2TP)/IPsec VPN Client。Cisco AnyConnect VPN Client 将自动基于网络限制使其通道协议适应最有效的方法。这是使用 DTLS 协议为延迟敏感型流量提供优化连接的第一种 VPN 产品,例如IP语音(VoIP)流量或基于 TCP 的应用接入。

试验目的:

掌握SSL VPN的配置步骤
掌握如何安装SSL VPN client
试验准备工作:
路由器IOS使用 c7200-advipservicesk9_li-mz。124-11。t。bin
SSL VPN 客户端软件:sslclient-win-1.1.3.173.pkg
此文件可以从Cisco站点下载,或者SDM 2.4.1软件的安装包,默认就自带此版本

试验拓扑:
image
试验过程:
第一步:对路由器进行基础配置,测试直连通讯是否正常

复制代码代码如下:
SSL#sh ip int brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES unset administratively down down
FastEthernet0/1 unassigned YES unset administratively down down
SSL#conf t
Enter configuration commands, one per line. End with CNTL/Z.
SSL(config)#int f0/0
SSL(config-if)#ip add 192.168.10.11 255.255.255.0
SSL(config-if)#no sh
SSL(config-if)#int f0/1
SSL(config-if)#ip add 192.168.204.11 255.255.255.0
SSL(config-if)#no sh
SSL(config-if)#end
SSL#ping 192.168.10.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.10.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 4/35/84 ms
SSL#ping 192.168.204.11
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.204.11, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/8 ms
SSL#

第二步:将SSL VPN Server的时间设置准确,已保证能客户端时间同步

复制代码代码如下:
SSL(config)#clock timezone UTC +8
SSL(config)#exit
SSL#clock set 18:38:00 24 Mar 2010
SSL#
Mar 24 10:38:00.003: %SYS-6-CLOCKUPDATE: System clock has been updated from 18:37:25 UTC Wed Mar 24 2010 to 18:38:00 UTC Wed Mar 24 2010, configured from console by console.
SSL#
SSL#show clock
18:38:46.483 UTC Wed Mar 24 2010

第三步:将Cisco SSL VPN Client软件,使用TFTP Server安装到路由器的disk0:中,并完成初始化安装

复制代码代码如下:
SSL#format disk0:
Format operation may take a while. Continue? [confirm]
Format operation will destroy all data in "disk0:". Continue? [confirm]
Format: Drive communication & 1st Sector Write OK...
Writing Monlib sectors.
.....................................................................................................................................................
Monlib write complete
Format: All system sectors written. OK...
Format: Total sectors in formatted partition: 130883
Format: Total bytes in formatted partition: 67012096
Format: Operation completed successfully.
Format of disk0 complete
SSL#copy tftp disk0:
Address or name of remote host []? 192.168.10.1
Source filename []? sslclient-win-1.1.3.173.pkg
Destination filename [sslclient-win-1.1.3.173.pkg]?
Accessing tftp://192.168.10.1/sslclient-win-1.1.3.173.pkg...
Loading sslclient-win-1.1.3.173.pkg from 192.168.10.1 (via FastEthernet0/0): !!
[OK - 416354 bytes]
416354 bytes copied in 16.064 secs (25918 bytes/sec)
SSL#dir disk0:
Directory of disk0:/
1-rw- 416354 Mar 24 2010 18:45:20 +08:00 sslclient-win-1.1.3.173.pkg
66846720 bytes total (66428928 bytes free)
使用webvpn 命令将sslclient完成初始化安装
SSL(config)#webvpn install svc disk0:/sslclient-win-1.1.3.173.pkg
SSLVPN Package SSL-VPN-Client : installed successfully
SSL(config)#exit
SSL#dir disk0:
Directory of disk0:/
1 drw- 0 Mar 24 2010 18:50:46 +08:00 webvpn
66846720 bytes total (66424832 bytes free)

第四步:启用AAA,并配置SSL VPN Client拨号的用户名和密码,并指定认证方式为AAA 本地认证,配置分配给SSL client地址池范围

复制代码代码如下:
SSL(config)#aaa new-model
SSL(config)#aaa authentication login webvpn local
SSL(config)#
SSL(config)#username admin privilege 15 password admin
在路由器创建回环接口来模拟SSL VPN Client的网关地址,并定义地址池
SSL(config)#int lo0
SSL(config-if)#ip add 192.168.0.254 255.255.255.0
SSL(config-if)#exit
SSL(config)#ip local pool sslvpn-pool 192.168.0.100 192.168.0.253

第五步:定义Webvpn的策略集,指定客户端的访问地址,端口等信息

复制代码代码如下:
//配置webvpn的网名名称为VPNGW
SSL(config)#webvpn gateway VPNGW
% Generating 1024 bit RSA keys, keys will be non-exportable...[OK]
SSL(config-webvpn-gateway)#?
SSLVPN Gateway Submode commands:
exit Exit from gateway configuration mode
hostname Hostname used in URL & Cookie mangling
http-redirect enable HTTP redirect feature
inservice Enable webvpn gateway
ip Virtual Gateway IP config
no Negate or set default values of a command
ssl SSL configurations for front end client connections
//配置虚拟网关IP,以及开放的端口
SSL(config-webvpn-gateway)#ip address 192.168.204.11 port 443
//开启webvpn网关服务
SSL(config-webvpn-gateway)#inservice

第六步:关联地址池,关联AAA认证策略,定义Client拨号的策略,以及DNS地址等

复制代码代码如下:
SSL(config)#webvpn context WEBTEXT
//关联虚拟网关的名称
SSL(config-webvpn-context)#gateway VPNGW
SSL(config-webvpn-context)#
//关联AAA认证策略
SSL(config-webvpn-context)#aaa authentication list webvpn
//开启服务
SSL(config-webvpn-context)#inservice
SSL(config-webvpn-context)#
Mar 24 11:06:02.687: %SSLVPN-5-UPDOWN: sslvpn context : WEBTEXT changed state to UP
//定义策略组的名称为SSLVPN-POLICY
SSL(config-webvpn-context)#policy group SSLVPN-POLICY
SSL(config-webvpn-group)#functions svc-enabled
//关联地址池名称
SSL(config-webvpn-group)#svc address-pool sslvpn-pool
SSL(config-webvpn-group)#banner "This IS Cisco IOS SSL VPN "
//配置首选DNS,备用DNS地址
SSL(config-webvpn-group)#svc dns-server primary 218.30.19.40
SSL(config-webvpn-group)#svc dns-server secondary 61.134.1.4
SSL(config-webvpn-group)#svc split include 192.168.10.0 255.255.255.0
SSL(config-webvpn-group)#exit
//应用到默认的策略组
SSL(config-webvpn-context)#default-group-policy SSLVPN-POLICY
SSL(config-webvpn-group)#exit
SSL(config-webvpn-context)#exit
SSL(config)#exit
SSL#write memory
Building configuration...
[OK]

第七步:因为SSL VPN Client软件,目前还不支持windows 7平台,故拨号我将在windows XP 环境下进行。使用https的方式访问SSL VPN SERVER,Windows XP 必须先安装jre,SSL VPN Client是基于jAVA环境运行的。 设置IE6允许弹出窗口
image

打开IE浏览器,使用https方式登录到SSL VPN SERVER,当弹出安全警报时,点击是

image

继续点击是接受安全警报

image

此时将进入 WEBVPN Service,登录页面,输入SSL VPN server上定义的拨号用户名和密码

image

此时,开始进入会话初始化阶段,将看到我们定义的banner消息

image

image

第八步:从路由器上下载SSL VPN Client,安装到XP上

如果IE6的安全级别为默认的设置,将不会主动安装ActiveX控件,此时会弹出窗口,询问我们是否安装非活动ActiveX控件,如下图所示:点击安装ActiveX控件,浏览器将从VPN Server上下载安装SSL VPN client软件,注意观察,浏览器已经正常加载了Java。

image

点击yes同意安装协议

image

如图所示:已经从VPN client成功下载完Cisco SSL VPN Client,点击安装

image

安装进行时,请稍等。。。。。。

image

SSL VPN 认证过程中,提示找不到有效证书,点击是下载安装证书

image

点击安装证书,将证书安装到系统当中

image

下一步

image

选择默认安装路径即可,下一步

image

点击是确认安装此证书

image

image

证书完成之后,再次发起连接,尝试进入SSL VPN Client拨号阶段,点击是

image

正在建立连接中

image

SSL VPN Client会话已经建立完成,VPN拨入成功

image

双击金黄色钥匙图标,查看连接状态的,路由信息等,客户端成功建立之后,从定义的地址池中获得IP地址为192.168.0.100

image

第九步:检查SSL VPN Server的工作状态

复制代码代码如下:
SSL#show ip local pool
Pool Begin End Free In use
sslvpn-pool 192.168.0.100 192.168.0.253 153 1
SSL#show webvpn session context WEBTEXT
WebVPN context name: WEBTEXT
Client_Login_Name Client_IP_Address No_of_Connections Created Last_Used
admin 192.168.204.111 1 00:07:09 00:00:50
SSL#show webvpn stats
User session statistics:
Active user sessions : 2 AAA pending reqs : 0
Peak user sessions : 2 Peak time : 00:16:11
Active user TCP conns : 1 Terminated user sessions : 1
Session alloc failures : 0 Authentication failures : 0
VPN session timeout : 0 VPN idle timeout : 0
User cleared VPN sessions: 0 Exceeded ctx user limit : 0
Exceeded total user limit: 0
CEF switched packets - client: 0 , server: 0
CEF punted packets - client: 0 , server: 0


第十步:SDM,可以实时监控SSL VPN状态,并且对SSL VPN配置调整更加灵活

如果初次在XP上使用SDM时,可能使SDM无法正常工作

解决方法:

如下图所示,Internet属性-安全,勾选允许活动的内容在我的计算机上运行,默认此项没有打钩,确定之后,再次打开SDM登录即可。

image

监视-VPN状态

image


SDM 配置SSL VPN 更加方便

image

型号 厂商 价格
EPCOS 爱普科斯 /
STM32F103RCT6 ST ¥461.23
STM32F103C8T6 ST ¥84
STM32F103VET6 ST ¥426.57
STM32F103RET6 ST ¥780.82
STM8S003F3P6 ST ¥10.62
STM32F103VCT6 ST ¥275.84
STM32F103CBT6 ST ¥130.66
STM32F030C8T6 ST ¥18.11
N76E003AT20 NUVOTON ¥9.67