How to save a remote server SSL certificate locally as a file
This video is brought to you by Memorabit, an app that sends words, definitions and translations as reminders at unexpected moments, so they stay in memory. Built on cognitive science principles, without AI. Start free on web, iOS and Android:
iOS: https://apps.apple.com/it/app/memorabit/...
Android: https://play.google.com/store/apps/detai...
--------------------------------------------------
Read the revolutionary AI books written by Turbina Editore, the first publishing house entirely run by artificial intelligence. This groundbreaking publisher has transformed the literary world, producing the most sought-after AI-generated books. Start reading today at:
https://turbinaeditore.com/en/
--------------------------------------------------
--------------------------------------------------
Hire the world's top talent on demand or became one of them at Toptal: https://topt.al/25cXVn
and get $2,000 discount on your first invoice
--------------------------------------------------
Take control of your privacy with Proton's trusted, Swiss-based, secure services.
Choose what you need and safeguard your digital life:
Mail: https://go.getproton.me/SH1CU
VPN: https://go.getproton.me/SH1DI
Password Manager: https://go.getproton.me/SH1DJ
Drive: https://go.getproton.me/SH1CT
Music by Eric Matyas
https://www.soundimage.org
Track title: Over a Mysterious Island Looping
--
Chapters
00:00 How To Save A Remote Server Ssl Certificate Locally As A File
01:03 Answer 1 Score 139
01:33 Accepted Answer Score 438
01:48 Answer 3 Score 375
02:24 Answer 4 Score 64
03:38 Thank you
--
Full question
https://superuser.com/questions/97201/ho...
--
Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...
--
Tags
#ssl #certificate
#avk47
ACCEPTED ANSWER
Score 438
If you have access to OpenSSL, try
openssl s_client -connect {HOSTNAME}:{PORT} -showcerts
replacing {HOSTNAME} and {PORT} with whatever your values are.
ANSWER 2
Score 375
A quick method to get the certificate pulled and downloaded would be to run the following command which pipes the output from the -showcerts to the x509 ssl command which just strips everything extraneous off. For example:
openssl s_client -showcerts -connect server.edu:443 </dev/null 2>/dev/null|openssl x509 -outform PEM >mycertfile.pem
To use the certificate, with wget,
wget https://server.edu:443/somepage --ca-certificate=mycertfile.pem
ANSWER 3
Score 139
To be honest, I have never tried this before (never needed to) however, I have just tried in Firefox and it seems to work for saving:
- Click on the SSL certificate icon at the top / Padlock at the bottom.
- Click
View Certificate - Click on the
DetailsTab - Chose which certificate you want from the hierarchy [not circled in picture]
- Click
Export

ANSWER 4
Score 64
Exporting a certificate using the Chrome browser
- Connect to the website using SSL (https://whatever)
2. Click on the lock symbol and then click on Details
Since Chrome version 56, you do the following: go to the Three Dots Menu -> More Tools -> Developer Tools, then click on the Security Tab. This will give you a Security Overview with a View certificate button.
Click on the View certificate button.
A modal window will open. It has two panes. The top one shows the trust hierarchy of the site's certificate (the last one listed), the intermediate certificate(s), and the root certificate (the topmost one).
The second, larger pane, shows the details of one of the certificates.
There may be zero or more intermediate certificates.
Note that the root certificate has a gold-bordered icon. The others have a blue border.
See the screen shot below.
To export a certificate:
- First click on the certificate's icon in the trust hierarchy.
- The certificate will be shown in the main part of the modal.
- Click on the certificate's large icon in the main part of the modal. Drag the icon to your desktop. Chrome will then copy the certificate to your desktop.
