SSL fingerprints mailserver : SMG's Weblog

SSL fingerprints mailserver

I use fetchmail to pull down my mail from the mailserver, just now the ssl fingerprints changed

leading to an error like:

fetchmail: fingerprints do not match!

12096:error:14090086:SSL routines:SSL3GETSERVERCERTIFICATE:certificate verify failed:../../../../common/openssl/ssl/s3clnt.c:894:

fetchmail: SSL connection failed.

fetchmail: socket error while fetching from @

fetchmail: Query status=2 (SOCKET)

So to get the new fingerprint, firstly get the changed ssl cert:

openssl s_client -connect : -showcerts

and copy say the first cert to a file .pem. Now generate

the SSL fingerprint of this pem file:

openssl x509 -fingerprint -md5 -noout -in .pem

MD5 Fingerprint=XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX

and put it in the .fetchmailrc file:

poll protocol imap port

username

ssl sslfingerprint XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX

sslcertpath /path/to/certs

Whew, nice and quick, thanks to google 🙂

viaSSL fingerprints mailserver : SMG’s Weblog.