# 查詢 HTTPS 服務的證書指紋 | 維運猿的共同筆記 確保不會被中間人攻擊影響 <https://hackmd.io/@ops-notes-tw/query-https-certificate-fingerprints> ## 操作步驟 1. 登入服務所在主機以避免查詢的主機就是中間人攻擊主機 1. 執行下列命令計算證書的指紋: + SHA-256 雜湊演算法: ```bash openssl x509 -noout -fingerprint -sha256 </path/to/certificate.crt ``` + SHA-1 雜湊演算法: ```bash openssl x509 -noout -fingerprint -sha1 </path/to/certificate.crt ``` <!-- + SHA-256 雜湊值: `echo | openssl s_client -connect localhost:443 2>/dev/null | openssl x509 -noout -fingerprint -sha256` + SHA-1 雜湊值: `echo | openssl s_client -connect localhost:443 2>/dev/null | openssl x509 -noout -fingerprint -sha1` --> --- 本作品為[《維運猿的共同筆記》](https://hackmd.io/@ops-notes-tw/home)的一部分 頁面連結:<https://hackmd.io/@ops-notes-tw/query-https-certificate-fingerprints> 授權條款:<https://hackmd.io/@ops-notes-tw/licensing> 參與協作視同將您的貢獻內容以相同的授權條款釋出
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up