이 페이지에서
예: 피어 인증서 체인 검증을 위한 디바이스 구성
이 예는 IKE 협상 중에 피어 디바이스를 검증하는 데 사용되는 인증서 체인의 디바이스를 구성하는 방법을 보여줍니다.
요구 사항
시작하기 전에 로컬 인증서 요청을 제출할 때 인증 기관(CA)의 주소와 필요한 정보(예: 도전 암호)를 얻을 수 있습니다.
개요
이 예는 인증서 체인을 위해 로컬 디바이스를 구성하고, CA 및 로컬 인증서를 등록하고, 등록한 인증서의 유효성을 확인하고, 피어 디바이스의 해지 상태를 확인하는 방법을 보여줍니다.
토폴로지
이 예는 그림 1과 같이 Host-A의 구성 및 운영 명령을 보여줍니다. Host-A에 동적 CA 프로필이 자동으로 생성되어 Host-A가 Sales-CA에서 CRL을 다운로드하고 Host-B 인증서 해지 상태를 확인할 수 있습니다.
이 예에서는 1단계 및 2단계 협상에 대한 IPsec VPN 구성이 Host-A에 대해 표시됩니다. 피어 디바이스(Host-B)는 1단계 및 2단계 옵션이 성공적으로 협상되고 SA(Security Association)가 설정되도록 올바르게 구성되어야 합니다.
구성
인증서 체인을 위한 디바이스 구성 방법:
CA 프로필 구성
CLI 빠른 구성
이 예를 빠르게 구성하려면, 아래 명령을 복사하여 텍스트 파일로 붙여 넣은 다음 모든 라인브러브를 제거하고, 네트워크 구성을 일치하는 데 필요한 세부 사항을 바꾸고 계층 수준에서 명령을 CLI [edit]
로 복사해 붙여 넣은 다음, 구성 모드에서 을(를) 입력 commit
합니다.
set security pki ca-profile Root-CA ca-identity CA-Root set security pki ca-profile Root-CA enrollment url http://10.157.88.230:8080/scep/Root/ set security pki ca-profile Root-CA revocation-check use-crl set security pki ca-profile Eng-CA ca-identity Eng-CA set security pki ca-profile Eng-CA enrollment url http://10.157.88.230:8080/scep/Eng/ set security pki ca-profile Eng-CA revocation-check use-crl set security pki ca-profile Dev-CA ca-identity Dev-CA set security pki ca-profile Dev-CA enrollment url http://10.157.88.230:8080/scep/Dev/ set security pki ca-profile Dev-CA revocation-check use-crl
단계별 절차
다음 예제에서는 구성 계층에서 다양한 수준의 탐색이 필요합니다. 이를 수행하는 방법에 대한 지침은 CLI 사용자 가이드의 구성 모드에서 CLI 편집기 사용을 참조하십시오.
CA 프로필 구성 방법:
루트-CA에 대한 CA 프로필을 생성합니다.
[edit security pki] user@host# set ca-profile Root-CA ca-identity CA-Root user@host# set ca-profile Root-CA enrollment url http://10.157.88.230:8080/scep/Root/ user@host# set ca-profile Root-CA revocation-check use-crl
Eng-CA에 대한 CA 프로필을 생성합니다.
[edit security pki] user@host# set ca-profile Eng-CA ca-identity Eng-CA user@host# set ca-profile Eng-CA enrollment url http://10.157.88.230:8080/scep/Eng/ user@host# set ca-profile Eng-CA revocation-check use-crl
Dev-CA에 대한 CA 프로필을 생성합니다.
[edit security pki] user@host# set ca-profile Dev-CA ca-identity Dev-CA user@host# set ca-profile Dev-CA enrollment url http://10.157.88.230:8080/scep/Dev/ user@host# set ca-profile Dev-CA revocation-check use-crl
결과
구성 모드에서 명령을 입력하여 구성을 확인합니다 show security pki
. 출력에 의도한 구성이 표시되지 않으면 이 예의 구성 지침을 반복하여 수정합니다.
[edit] user@host# show security pki ca-profile Root-CA { ca-identity Root-CA; enrollment { url "http:/;/10.157.88.230:8080/scep/Root/"; } revocation-check { use-crl; } } ca-profile Eng-CA { ca-identity Eng-CA; enrollment { url "http:/;/10.157.88.230:8080/scep/Eng/"; } revocation-check { use-crl; } } ca-profile Dev-CA { ca-identity Dev-CA; enrollment { url "http:/;/10.157.88.230:8080/scep/Dev/"; } revocation-check { use-crl; } }
디바이스 구성이 완료되면 구성 모드에서 을(를) 입력합니다 commit
.
인증서 등록
단계별 절차
인증서 등록:
CA 인증서를 등록합니다.
user@host> request security pki ca-certificate enroll ca-profile Root-CA
user@host> request security pki ca-certificate enroll ca-profile Eng-CA
user@host> request security pki ca-certificate enroll ca-profile Dev-CA
CA 인증서를 로드하려면 프롬프트에 을(를) 입력 yes 합니다.
CA 인증서가 디바이스에 등록되었는지 확인합니다.
user@host> show security pki ca-certificate ca-profile Root-CA Certificate identifier: Root-CA Issued to: Root-CA, Issued by: C = us, O = juniper, CN = Root-CA Validity: Not before: 07- 3-2015 10:54 UTC Not after: 07- 1-2020 10:54 UTC Public key algorithm: rsaEncryption(2048 bits)
user@host> show security pki ca-certificate ca-profile Eng-CA Certificate identifier: Eng-CA Issued to: Eng-CA, Issued by: C = us, O = juniper, CN = Root-CA Validity: Not before: 07- 3-2015 10:54 UTC Not after: 07- 1-2020 10:54 UTC Public key algorithm: rsaEncryption(2048 bits)
user@host> show security pki ca-certificate ca-profile Dev-CA Certificate identifier: Dev-CA Issued to: Dev-CA, Issued by: C = us, O = juniper, CN = Eng-CA Validity: Not before: 07- 3-2015 10:54 UTC Not after: 07- 1-2020 10:54 UTC Public key algorithm: rsaEncryption(2048 bits)
등록한 CA 인증서의 유효성을 확인합니다.
user@host> request security pki ca-certificate verify ca-profile Root-CA CA certificate Root-CA verified successfully
user@host> request security pki ca-certificate verify ca-profile Eng-CA CA certificate Eng-CA verified successfully
user@host> request security pki ca-certificate verify ca-profile Dev-CA CA certificate Dev-CA verified successfully
로컬 인증서를 등록합니다.
user@host> request security pki local-certificate enroll certificate-id Host-A ca-profile Dev-CA challenge-password juniper domain-name host-a.company.net email host-a@company.net subject DC=juniper,CN=Host-A, OU=DEV,O=PKI,L=Sunnyvale,ST=CA,C=US
로컬 인증서가 디바이스에 등록되었는지 확인합니다.
user@host> show security pki local-certificate Issued to: Host-A, Issued by: C = us, O = juniper, CN = Dev-CA Validity: Not before: 07- 3-2015 10:54 UTC Not after: 07- 1-2020 10:54 UTC Public key algorithm: rsaEncryption(1024 bits)
등록한 로컬 인증서의 유효성을 확인합니다.
user@host> request security pki local-certificate verify certificate-id Host-A Local certificate Host-A verification success
구성된 CA 프로필은 CRL 다운로드를 확인합니다.
user@host> show security pki crl CA profile: Root-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Root-CA Effective date: 09- 9-2015 13:08 Next update: 09-21-2015 02:55 CA profile: Eng-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Eng-CA Effective date: 08-22-2015 17:46 Next update: 10-24-2015 03:33 CA profile: Dev-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Dev-CA Effective date: 09-14-2015 21:15 Next update: 09-26-2012 11:02
IPsec VPN 옵션 구성
CLI 빠른 구성
이 예를 빠르게 구성하려면, 아래 명령을 복사하여 텍스트 파일로 붙여 넣은 다음 모든 라인브러브를 제거하고, 네트워크 구성을 일치하는 데 필요한 세부 사항을 바꾸고 계층 수준에서 명령을 CLI [edit]
로 복사해 붙여 넣은 다음, 구성 모드에서 을(를) 입력 commit
합니다.
set services ipsec-vpn ike proposal ike_cert_prop_01 authentication-method rsa-signatures set services ipsec-vpn ike proposal ike_cert_prop_01 dh-group group5 set services ipsec-vpn ike proposal ike_cert_prop_01 authentication-algorithm sha1 set services ipsec-vpn ike proposal ike_cert_prop_01 encryption-algorithm aes-256-cbc set services ipsec-vpn ike policy ike_cert_pol_01 mode main set services ipsec-vpn ike policy ike_cert_pol_01 proposals ike_cert_prop_01 set services ipsec-vpn ike policy ike_cert_pol_01 certificate local-certificate Host-A set services ipsec-vpn ipsec proposal ipsec_prop_01 protocol esp set services ipsec-vpn ipsec proposal ipsec_prop_01 authentication-algorithm hmac-sha1-96 set services ipsec-vpn ipsec proposal ipsec_prop_01 encryption-algorithm 3des-cbc set services ipsec-vpn ipsec proposal ipsec_prop_01 lifetime-seconds 300 set services ipsec-vpn ipsec policy ipsec_pol_01 proposals ipsec_prop_01 set services ipsec-vpn ipsec vpn ipsec_cert_vpn_01 ike ipsec-policy ipsec_pol_01
단계별 절차
다음 예제에서는 구성 계층에서 다양한 수준의 탐색이 필요합니다. 이를 수행하는 방법에 대한 지침은 CLI 사용자 가이드의 구성 모드에서 CLI 편집기 사용을 참조하십시오.
IPsec VPN 옵션 구성 방법:
1단계 옵션을 구성합니다.
[edit services ipsec-vpn ike proposal ike_cert_prop_01] user@host# set authentication-method rsa-signatures user@host# set dh-group group5 user@host# set authentication-algorithm sha1 user@host# set encryption-algorithm aes-256-cbc [edit services ipsec-vpn ike policy ike_cert_pol_01] user@host# set mode main user@host# set proposals ike_cert_prop_01 user@host# set certificate local-certificate Host-A
2단계 옵션을 구성합니다.
[edit services ipsec-vpn ipsec proposal ipsec_prop_01] user@host# set protocol esp user@host# set authentication-algorithm hmac-sha1-96 user@host# set encryption-algorithm 3des-cbc user@host# set lifetime-seconds 300 [edit services ipsec-vpn ipsec policy ipsec_pol_01] user@host# set proposals ipsec_prop_01 [edit services ipsec-vpn ipsec vpn ipsec_cert_vpn_01] user@host# set ike ipsec-policy ipsec_pol_01
결과
구성 모드에서 및 show security ipsec
명령을 입력하여 구성을 show security ike
확인합니다. 출력에 의도한 구성이 표시되지 않으면 이 예의 구성 지침을 반복하여 수정합니다.
[edit] user@host# show services ipsec-vpn ike proposal ike_cert_prop_01 { authentication-method rsa-signatures; dh-group group5; authentication-algorithm sha1; encryption-algorithm aes-256-cbc; } policy ike_cert_pol_01 { mode main; proposals ike_cert_prop_01; certificate { local-certificate Host-A; } } [edit] user@host# show services ipsec-vpn ipsec proposal ipsec_prop_01 { protocol esp; authentication-algorithm hmac-sha1-96; encryption-algorithm 3des-cbc; lifetime-seconds 300; } policy ipsec_pol_01 { proposals ipsec_prop_01; }
디바이스 구성이 완료되면 구성 모드에서 을(를) 입력합니다 commit
.
확인
피어 디바이스 간의 IKE 협상 중에 인증서 검증이 성공하면 IKE 및 IPsec 보안 연결(SA) 모두 설정됩니다.
IKE(Internet Internet) 1단계 상태 확인
목적
IKE(Internet Internet) 1단계 상태를 확인합니다.
작업
show services ipsec-vpn ike security-associations 운영 모드에서 명령을 입력합니다.
user@host> show services ipsec-vpn ike security-associations Remote Address State Initiator cookie Responder cookie Exchange type 192.0.2.0 Matured 63b3445edda507fb 2715ee5895ed244d Main
IPsec 2단계 상태 확인
목적
IPsec 2단계 상태를 확인합니다.
작업
show services ipsec-vpn ipsec security-associations 운영 모드에서 명령을 입력합니다.
user@host> show services ipsec-vpn ipsec security-associations Service set: ips_ss1, IKE Routing-instance: default Rule: vpn_rule_ms_2_2_01, Term: term11, Tunnel index: 1 Local gateway: 10.0.1.2, Remote gateway: 172.16.0.0 IPSec inside interface: ms-2/2/0.1, Tunnel MTU: 1500 UDP encapsulate: Disabled, UDP Destination port: 0 Direction SPI AUX-SPI Mode Type Protocol inbound 2151932129 0 tunnel dynamic ESP outbound 4169263669 0 tunnel dynamic ESP
취소된 인증서에 대한 IKE 및 IPsec SA 실패
취소된 인증서 확인
문제
피어 디바이스 간의 IKE 협상 중에 인증서 검증이 실패하면 피어의 인증서가 취소되지 않았는지 확인합니다. 동적 CA 프로필을 사용하면 로컬 디바이스가 피어의 CA에서 CRL을 다운로드하고 피어 인증서의 해지 상태를 확인할 수 있습니다. 동적 CA 프로필을 활성화하려면 상위 CA 프로필 revocation-check crl
에 옵션을 구성해야 합니다.
솔루션
피어 인증서의 해지 상태를 확인하려면 다음을 수행합니다.
운영 모드에서 명령을 입력 show security pki crl 하여 피어 디바이스의 CRL을 표시하는 동적 CA 프로필을 식별합니다.
user@host> show security pki crl CA profile: Root-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Root-CA Effective date: 09- 9-2012 13:08 Next update: 09-21-2012 02:55 CA profile: Eng-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Eng-CA Effective date: 08-22-2012 17:46 Next update: 10-24-2015 03:33 CA profile: Dev-CA CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Dev-CA Effective date: 09-14-2012 21:15 Next update: 09-26-2012 11:02 CA profile: dynamic-001 CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Sales-CA Effective date: 09-14-2012 21:15 Next update: 09-26-2012 11:02
CA 프로필
dynamic-001
은 Host-A에서 자동으로 생성되므로 Host-A는 Host-B의 CA(Sales-CA)에서 CRL을 다운로드하고 피어 인증서의 해지 상태를 확인할 수 있습니다.운영 모드에서 명령을 입력하여 동적 CA 프로필에 show security pki crl ca-profile dynamic-001 detail 대한 CRL 정보를 표시합니다.
입력
user@host> show security pki crl ca-profile dynamic-001 detail CA profile: dynamic-001 CRL version: V00000001 CRL issuer: C = us, O = juniper, CN = Sub11 Effective date: 09-19-2012 17:29 Next update: 09-20-2012 01:49 Revocation List: Serial number Revocation date 10647C84 09-19-2012 17:29 UTC
Host-B의 인증서(일련번호 10647084)가 취소되었습니다.