PKI_IOS证书加密L2L ×××

 

实验拓扑:

PKI_IOS证书加密L2L <wbr>×××

 

拓扑说明:

公网接口都为f0/0 。R1为100.100.100.1,R2为100.100.100.2 。R1和R2通过PKI证书加密做L2L的×××,R4为100.100.100.4做IOS的证书颁发机构。证书存放在172.16.1.10的FTP服务器上。

 

实验配置步骤:

前期准备:搭建好FTP服务器,R4能够通过用户名和密码正常的访问FTP服务器,本实验的而用户名为:cisco 密码为:cisco123,。R4为NTP服务器,其他路由器同步时间。

在R4上的配置,R4配置为CA证书颁发机构。

 

ip domain-name cisco.com                      

crypto key general rsa usage-keys label CISCO  //产生一个密钥名字

ip http server enable  //开启HTTP服务,以便路由器可以被访问

R4(config)#crypto pki server CISCO  //PKI服务器开启,PKI的名字和产生的密钥名字相同

R4(cs-server)#database url ftp://172.16.1.10  //指定CA数据库文件的存放地

R4(cs-server)#database username cisco password cisco123, //访问FTP服务器的用户名和密码

R4(cs-server)#database archive pem

R4(cs-server)#database level complete

R4(cs-server)#issuer-name cn=IOS_CISCO ou=IPSEC //证书CN和OU自己定义,但是注意格式

R4(cs-server)#no shutdown //开启这个服务

 

在R1路由器上申请证书

 

信任根证书证书CA

crypto pki trustpoint R1

 enrollment url http://100.100.100.4

subject-name cn=R1

 rsakeypair IKE

认证根证书

Crypto PKI authenticate R1

 

申请证书

crypto ca enroll R1

password:密码为空

yes

no

yes

此时,R1并不会获得证书,因为R4证书默认颁发模式为手动,所以在R4上:

crypto pki server CS info request  查看CA请求

crypto pki server CS grant all或序号  颁发CA

PKI_IOS证书加密L2L <wbr>×××
PKI_IOS证书加密L2L <wbr>×××

然后回到R1查看

PKI_IOS证书加密L2L <wbr>×××

R2的操作和R1一样。

 

×××的设置

crypto isakmp policy 10

crypto ipsec transform-set ×××SET esp-3des esp-md5-hmac

crypto map SMAP 10 ipsec-isakmp

 set peer 100.100.100.2

 set transform-set ×××SET

 match address ×××ACL

 reverse-route

interface FastEthernet0/0

crypto map SMAP

ip route 0.0.0.0 0.0.0.0 FastEthernet0/0

ip access-list extended ×××ACL

 permit ip 192.168.1.0 0.0.0.255 192.168.2.0 0.0.0.255

 

实验验证:

PKI_IOS证书加密L2L <wbr>×××

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

PKI_IOS证书加密Remote ×××

实验拓扑:

PKI_IOS证书加密L2L <wbr>×××

拓扑说明:

沿用上面的拓扑图,添加了一个R3路由器。***Cclient通过NAT上公网。R1还做了个NAT

实验配置:

R3同样也要向R1申请证书:步骤省略。

Remote ×××配置部分

aaa new-model

aaa authentication login AUTHEN local

aaa authorization network AUTHOR local

username remote*** password 0 cisco123

crypto isakmp policy 10

 hash md5

crypto isakmp identity dn

crypto isakmp client configuration group EZ×××  //组名相同

 pool ×××POOL

 acl 100

crypto isakmp profile EZ×××

   ca trust-point Remote×××

   match identity group EZ×××

   client authentication list AUTHEN

   isakmp authorization list AUTHOR

   client configuration address respond

!

crypto ipsec transform-set ×××SET esp-3des esp-md5-hmac

!

crypto dynamic-map DMAP 10

 set transform-set ×××SET

 set isakmp-profile EZ×××

 reverse-route

!

crypto map SMAP 10 ipsec-isakmp dynamic DMAP

!

interface Loopback0

 ip address 192.168.3.1 255.255.255.0

interface FastEthernet0/0

crypto map SMAP

ip local pool ×××POOL 20.1.1.1 20.1.1.10

!

access-list 100 permit ip 192.168.3.0 0.0.0.255 any

access-list 101 permit ip 192.168.3.0 0.0.0.255 any

!

 

客户端申请证书方式

PKI_IOS证书加密L2L <wbr>×××

在C:\program File\cisco system\××× client目录下生成IOS.txt .

 

在IOS_CA(R1)上颁发,把IOS.txt内容粘贴

cryp pki server CS request pkcs10 terminal

 

 

之后FTP会新生成*.crt,本实验为8.crt。把FTP的1.cer(根证书),和8.cet(XP获取的证书)

导入×××client软件。先导入根证书1,再导入证书8

完成后如下

PKI_IOS证书加密L2L <wbr>×××

完成

PKI_IOS证书加密L2L <wbr>×××

在xp上可以ping通公网,也可以ping通×××内部网络

PKI_IOS证书加密L2L <wbr>×××