地方エンジニアの学習日記

興味ある技術の雑なメモだったりを書いてくブログ。たまに日記とガジェット紹介。

【Linux】curlが使うルート証明書

この辺にある。

/etc/pki/tls/certs/ca-bundle.crt

curlをverboseモードで打つと確かにそのパスを読んでるような出力がある

[root@worker001 ~]# curl -sv https://www.google.com -o /dev/null
* About to connect() to www.google.com port 443 (#0)
*   Trying 172.217.26.4...
* Connected to www.google.com (172.217.26.4) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
  CApath: none
* SSL connection using TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
* Server certificate:
*   subject: CN=www.google.com,O=Google LLC,L=Mountain View,ST=California,C=US
*   start date:  3月 11 15:00:19 2021 GMT
*   expire date:  6月 03 15:00:18 2021 GMT
*   common name: www.google.com
*   issuer: CN=GTS CA 1O1,O=Google Trust Services,C=US

ちなみに追加することも可能で以下のような手順となっているらしい。

manuals.gfi.com