Last active
June 1, 2020 11:13
-
-
Save shoan/833c7467d37ba4b99795be3ad827129f to your computer and use it in GitHub Desktop.
Check if an ssl certificate and key match
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| openssl rsa -modulus -noout -in myserver.key | openssl md5 | |
| openssl rsa -check -noout -in myserver.key | |
| # RSA Key is ok | |
| # If it doesn't say 'RSA key ok', it isn't OK!" | |
| # To view the modulus of the RSA public key in a certificate: | |
| openssl x509 -modulus -noout -in myserver.crt | openssl md5 | |
| # To view the hash of the CSR | |
| openssl req -noout -modulus -in mycsr.csr | openssl md5 | |
| # Decode the CSR. | |
| openssl req -in csr.txt -noout -text | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment