lpi2:dovecot-ssl
Inhaltsverzeichnis
Todo: DH-Parameter einbinden
Vorraussetzungen
- Einfache dovecot-imapd Installation
- ssl Zertifikat erzeugt
- Korrektes DNS
- Korrekte Uhrzeiten auf allen Rechnern
SSL / TLS für Dovecot
Server-Zertifikat für verschlüsselte Verbindungen
Wie in ssl oder dehydrated beschrieben Server-Zertifikat bauen
openSuSE 12.1
cd /etc/ssl cp /root/server-ssl/servercert.pem certs/ cp /root/server-ssl/serverkey.pem private/ cp /home/ca/ca.*/cacert.pem certs/
chmod 640 private/serverkey.pem #chgrp ssl private/serverkey.pem
Dovecot konfigurieren
ausführlich: https://ssl-config.mozilla.org/#server=dovecot&config=intermediate
vereinfacht:
- /etc/dovecot/local.conf
ssl = required ssl_server_cert_file = /etc/apache2/md/domains/server.example.com/pubcert.pem ssl_server_key_file = /etc/apache2/md/domains/server.example.com/privkey.pem
doveconf ssl_cert doveconf ssl_key systemctl reload dovecot.service
testen
curl
curl -v --ssl-reqd --url imaps://server.example.com:993 --user user1@server.example.com
nc
nc server.example.com 143
..
* OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE STARTTLS AUTH=PLAIN] Dovecot ready.
testssl
testssl server.example.com:993 testssl --starttls=imap server.example.com:143
openssl
openssl s_client -starttls imap -CAfile /etc/ssl/certs/cacert.pem -connect server.example.com:143
lpi2/dovecot-ssl.txt · Zuletzt geändert: 2026/03/04 14:04 von ingo_wichmann
