728x90

SSL 인증서 중 Comodo  인증서가 sectigo 인증서로 변경되면서 일부 리눅스 시스템 내 Root/chain 인증서가 반영이 안되 어  있어 JAVA SSL HandshakeException 및 Curl  오류가 발생합니다.

 

"Sectigo(COMODO)의 “AddTrust External Root CA” 만료 이후 HTTPS 접속 오류 현상 관련 안내드립니다." 에서 확인이 가능합니다.

www.certkorea.co.kr/bbs/board.php?bo_table=31&wr_id=30

 

Sectigo(COMODO)의 “AddTrust External Root CA” 만료 이후 HTTPS 접속 오류 현상 관련 안내드립니다. > 공지�

> 고객지원/이벤트 > 공지사항 공지사항

www.certkorea.co.kr

 

오류 1 . curl https://www.OOOOO.co.kr cli 명령시 에러 발생

인증서가 교체 된 이후에 https://www.OOOO.co.kr로 접속할 경우 원할하지 않은 부분이 발생할 수 있습니다.

예를 들어 아래와 같은 문제가 발생할 수 있습니다.

# curl https://www.OOOOO.co.kr

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.

 

 

 

위와 같이 에러가 뜬다면 

 

서버의 인증서 Root CA 를 추가해 줘야 합니다.

 

0.  먼저 CA 파일의 경로를 찾습니다.

아래와 같이 curl -v https://www.OOOOO.co.kr로 하면 CAfile 파일 경로 위치를 확인할 수 있습니다.


1. 먼저 서버에 Chain_RootCA_Bundle.zip 압축파일을 풀어서 ftp로 업로드 합니다.
2. 업로드된 파일로 콘솔로 들어가야 함.

# cd ./Chain_RootCA_Bundle 
# ll /etc/pki/tls/certs/ca-bundle.crt
# cp /etc/pki/tls/certs/ca-bundle.crt /etc/pki/tls/certs/ca-bundle.crt.20201006
# printf "\n### Sectigo_RSA_AddTrust_codesign Add $(date '+%Y.%m.%d') \n " >> /etc/pki/tls/certs/ca-bundle.crt
# cat Chain_RootCA_Bundle.crt | sed -e "s/\\r//g" >>  /etc/pki/tls/certs/ca-bundle.crt

Chain_RootCA_Bundle.zip
0.05MB

 

첨부파일을 보시고서 자신에 맞는 폴더에서 확인 작업하시면 됩니다.

[15:35:43 root@home:~#] ll /etc/pki/tls/certs/ca-bundle.crt
lrwxrwxrwx 1 root root 49  5월 20  2016 /etc/pki/tls/certs/ca-bundle.crt -> /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem

[15:35:52 root@home:~#] cp /etc/pki/tls/certs/ca-bundle.crt /etc/pki/tls/certs/ca-bundle.crt.20201006


[15:36:28 root@home:/home#] cd Chain_RootCA_Bundle/
[15:36:32 root@home:/home/Chain_RootCA_Bundle#] ls
ChainCA1.crt  ChainCA2.crt  Chain_RootCA_Bundle.crt  RootCA.crt  add_sectigo_cert.sh

[15:36:33 root@home:/home/Chain_RootCA_Bundle#] printf "\n### Sectigo_RSA_AddTrust_codesign Add $(date '+%Y.%m.%d') \n " >> /etc/pki/tls/certs/ca-bundle.crt
[15:36:50 root@home:/home/Chain_RootCA_Bundle#] cat Chain_RootCA_Bundle.crt | sed -e "s/\\r//g" >>  /etc/pki/tls/certs/ca-bundle.crt
[15:36:53 root@home:/home/Chain_RootCA_Bundle#] curl https://www.OOOOOO.co.kr
....

 

 

 


참고 URL

www.securesign.kr/guides/kb/47

louky0714.tistory.com/entry/Linux-sectigo-rootchain-%EC%9D%B8%EC%A6%9D%EC%84%9C-%EC%B6%94%EA%B0%80

 

+ Recent posts