PDA

View Full Version : Cisco Router + PKI???



ngd
14-10-2008, 10:10 AM
Mình đang cấu hình thử Cisco Router tích hợp với Windows CA Server. Nhưng khi vào SDM, phần VPN --> VPN Components --> PKI --> Certificate Enrollment --> chọn SCEP để Enroll Cert cứ bị báo lỗi như sau:

Authentication has failed. The error code returned indicates the following
reason for failure:

There was an error receiving the CA certificate. The CA server did
not respond for one of the following reasons:

-The enrollment URL entered is incorrect
-The router could not reach the CA server
-The CA server could be offline.

Bác nào biết lỗi này thì giúp mình với nhé.

PS: với 3 lỗi trên mình đã thử thì:
- CA vẫn đang online. Vì mình vào website của nó vẫn request/down dc cert.
- Từ Router vẫn Ping đến dc CA Server bình thường.
- Enrollment URL thì mình đã thử là: http://192.168.2.247/certsrv hoặc http://192.168.2.247 (địa chỉ của CA Server)

Thanks

nguyenquocle
14-10-2008, 11:23 AM
chào bạn!!!nguyên nhân bạn dẫn đến là do bạn chưa cài phần mềm hỗ trợ trên windows CAserver .các bước tiến cấu hình router xác thực CA server mình đưa ở dưới.bạn down về r xem thêm
http://rapidshare.com/files/153793055/cepsetup.exe.html
http://rapidshare.com/files/153791675/cau_hinh_CA.pdf.html
(http://rapidshare.com/files/153791675/cau_hinh_CA.pdf.html?killcode=15046161046357444910 )

ngd
14-10-2008, 04:59 PM
Cảm ơn bạn đã cho mình cep software. Mình đã Enrollment được Cert rồi. Còn về cấu hình trên Router, mình đang muốn thử VPN Remote Access. Trong khi tài liệu của bạn và các tài liệu trên Cisco chỉ có hướng dẫn cấu hình VPN Site-to-Site sử dụng Cert thôi.

Mà ngay cả trên cấu hình SDM, default khi cấu hình đến phần authen là Pre-shared key, chứ ko có option để cấu hình authen là RSA-Sig... Không biết Router VPN Remote Access có hỗ trợ authen = cert ko??? Đối với Cisco ASA hay VPN Concentrator thì có.

nguyenquocle
15-10-2008, 12:11 AM
hi ngd!!! mô hình Router VPN SERVER-REMOTE có hỗ trợ authen=cert đó bạn!!! sử dụng SDM cấu hình cũng dc,CLI cũng được vì hồi đó mình có làm thử rồi!!!!

ngd
16-10-2008, 12:59 AM
Mình cấu hình thì nó làm được các bước sau:
- Đã pass dc Phase 1.
- Router hỏi Username/pass của VPN Client.
Nhưng sau khi nhập User/pass xong thì nó hiển thị trên VPN Client là: Negotiation Security Policy rất lâu, rồi failed --> Not Connected.

Trên VPN Client báo: Inbound connections are not allowed
Còn đây là phần cấu hình VPN trên Router của mình.
aaa new-model
!
!
aaa authentication login default local
aaa authentication login sdm_vpn_xauth_ml_1 local
aaa authorization exec default local
aaa authorization network sdm_vpn_group_ml_1 local
aaa session-id common

crypto ca trustpoint TSVV
enrollment mode ra
enrollment url http://192.168.2.247:80/certsrv/mscep/mscep.dll
serial-number none
fqdn Router.
ip-address none
password 7 03267D5D2356026F1B5F415C4330292F22
subject-name O=TSV, OU=TSV, CN=Ducng, C=VN, ST=Ha Noi, E=duc@tsv.vn
rsakeypair SDM-RSAKey-1223971637000
auto-enroll
!
crypto ca certificate chain TSVV
certificate 61103809000000000005

username ducng privilege 15 password 0 123456
!
crypto isakmp policy 3
encr 3des
!
crypto isakmp keepalive 40 5
crypto isakmp xauth timeout 15

!
crypto isakmp client configuration group TSV
pool SDM_POOL_1
!
!
crypto ipsec transform-set ESP-3DES-SHA esp-3des esp-sha-hmac
!
crypto dynamic-map SDM_DYNMAP_1 1
set transform-set ESP-3DES-SHA
match address 101
reverse-route
!
!
crypto map SDM_CMAP_1 client authentication list sdm_vpn_xauth_ml_1
crypto map SDM_CMAP_1 isakmp authorization list sdm_vpn_group_ml_1
crypto map SDM_CMAP_1 client configuration address respond
crypto map SDM_CMAP_1 65535 ipsec-isakmp dynamic SDM_DYNMAP_1
!
!
ip local pool SDM_POOL_1 192.168.2.14 192.168.2.18

nguyenquocle
16-10-2008, 11:55 AM
bạn show cry ca certifications ,show cry isa sa, show cry ipsec sa, show cry sess và debug phase 1 va phase 2 ,nêu phase 1 pass r thì show phase 2 để tiện xem lỗi

ngd
16-10-2008, 04:36 PM
Show cry ca cert thì vẫn như trên SDM, chỉ ra là có 2 cert với usage là General Purpose và Signature. Status là Available.
Vì chưa connect dc VPN nên Show isakmp hay ipsec đều trống không.
Lúc đầu mình debug cả 2 phase nhưng Phase 1 pass nên mình chỉ debug phase 2. Mình thấy mấy lỗi này là đáng chú ý:

Oct 15 10:34:51.990: ISAKMP (0:2): Old State = IKE_P1_COMPLETE New State = IKE_CONFIG_AUTHOR_AAA_AWAIT

Oct 15 10:34:51.990: ISAKMP: got callback 1
Oct 15 10:34:51.994: ISAKMP (0:2): AAA returned a policy error. Sending empty reply.
Oct 15 10:34:51.994: ISAKMP (0:2): deleting node -944738816 error FALSE reason ""
Oct 15 10:34:51.994: ISAKMP (0:2): FSM action returned error: 2
Oct 15 10:34:51.994: ISAKMP (0:2): Input = IKE_MESG_FROM_AAA, IKE_AAA_GROUP_ATTR
Oct 15 10:34:51.994: ISAKMP (0:2): Old State = IKE_CONFIG_AUTHOR_AAA_AWAIT New State = IKE_P1_COMPLETE

với
*Mar 1 04:58:46.482: ISAKMP (0:1): peer's pubkey isn't cached
*Mar 1 04:58:46.594: %CRYPTO-5-IKMP_INVAL_CERT: Certificate received from 192.168.1.97 is bad: CA request failed!
*Mar 1 04:58:46.598: ISAKMP (0:1): Input = IKE_MESG_INTERNAL, IKE_PROCESS_MAIN_MODE
*Mar 1 04:58:46.598: ISAKMP (0:1): Old State = IKE_R_MM5 New State = IKE_R_MM5

nguyenquocle
17-10-2008, 02:32 AM
aaa new-model
!
!
aaa authentication login authen_vpn local
aaa authorization network author_vpn local
username admin password 0 admin
crypto isakmp policy 1
encr 3des
group 2
!
crypto isakmp client configuration group TSV
pool address-pool
save-password
netmask 255.255.255.0
crypto isakmp profile isa_profile
match identity group TSV
client authentication list author_vpn
isakmp authorization list authen_vpn
client configuration address respond
virtual-template 1
!
!
crypto ipsec transform-set vpn esp-3des esp-sha-hmac
!
crypto ipsec profile ipsec_profile
set transform-set vpn
set isakmp-profile isa_profile
!
interface loopback0
ip address 192.168.2.10 255.255.255.0
interface Virtual-Template1 type tunnel
ip unnumbered Loopback0
tunnel mode ipsec ipv4
tunnel protection ipsec profile ipsec_profile
!
ip local pool SDM_POOL_1 192.168.2.14 192.168.2.18

nguyenquocle
17-10-2008, 02:38 AM
bạn xem mau cau hình của mình sửa doi lai của bạn ap dung nha!!!
%CRYPTO-5-IKMP_INVAL_CERT: Certificate received from 192.168.1.97 is bad: CA request failed! cái lỗi này là do cert phía client của bạn có thể bi revoke...bạn hãy request 1 cert mới rồi connect đến server lại nha!!!

nguyenquocle
17-10-2008, 02:40 AM
yêu cầu là khi request cert từ client cần thiết phải có "OU=group name" vào nữa

nguyenquocle
17-10-2008, 07:04 PM
nhớ xem lại thời gian:giờ,phút,ngày tháng năm của CA,router vpn server,client nha bạn,nếu ko cũng dẫn đến lỗi trên