Skip to content

SSL Certificate Verification Failed: Self-signed Certificate

In professional email server configurations, an SSL Certificate Verification Failed error is a critical issue. If your tool.tl diagnostics show [SSL: CERTIFICATE_VERIFY_FAILED], it usually means your server is using a self-signed certificate.

Why Self-signed Certificates are a Problem

A self-signed certificate is generated by you and is not signed by a trusted Certificate Authority (CA). While it encrypts the connection, it cannot prove your identity. * Rejection Risk: Major providers like Gmail and Outlook may reject your emails or flag them as spam if the TLS certificate is untrusted. * Security Warnings: Mail clients (Outlook, iOS Mail, etc.) will display scary security warnings to users.

The Solution: Use a Trusted SSL Certificate

This is the most popular, free, and automated solution. Use certbot to issue a certificate for your mail domain (e.g., mail.yourdomain.com).

# For Ubuntu and Standalone mode
sudo apt update
sudo apt install certbot
sudo certbot certonly --standalone -d mail.yourdomain.com

2. Update Dovecot/Postfix Configuration

Once issued, point your config files to the new .pem files:

Postfix (/etc/postfix/main.cf):

smtpd_tls_cert_file=/etc/letsencrypt/live/mail.yourdomain.com/fullchain.pem
smtpd_tls_key_file=/etc/letsencrypt/live/mail.yourdomain.com/privkey.pem

Dovecot (/etc/dovecot/conf.d/10-ssl.conf):

ssl_cert = </etc/letsencrypt/live/mail.yourdomain.com/fullchain.pem
ssl_key = </etc/letsencrypt/live/mail.yourdomain.com/privkey.pem

Next Steps

  1. Deploy a trusted CA certificate.
  2. Restart Postfix and Dovecot.
  3. Go to the Email Diagnostics Tool for testing.

Targeting Production?
Ensure your IP reputation is clean and Port 25 is accessible before you begin.
Get $100 from Vultr to deploy a pristine Dovecot instance today →