0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

ターミナルからドメイン証明書の確認をする方法

Posted at
echo | openssl s_client -connect {example.com}:443 -servername {example.com} 2>/dev/null | openssl x509 -noout -dates -issuer -subject

これでexample.comドメインの証明書情報を確認することができます。
(example.comは適宜調べたいドメイン名に変更してください)

# 例
ryosuke.takano@iMac-PC-0079 ~ % echo | openssl s_client -connect example.com:443 -servername example.com 2>/dev/null | openssl x509 -noout -dates -issuer -subject 
notBefore=Jan 15 00:00:00 2025 GMT
notAfter=Jan 15 23:59:59 2026 GMT
issuer=C=US, O=DigiCert Inc, CN=DigiCert Global G3 TLS ECC SHA384 2020 CA1
subject=C=US, ST=California, L=Los Angeles, O=Internet Corporation for Assigned Names and Numbers, CN=*.example.com

上記のように、開始・終了期限、割当たっている証明書情報、コモンネーム(CN)情報がわかります。

メモしておくと便利です👍

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?