Require STARTTLS for sending email in exim

eximsmtp

I have configured exim to work with dovecot (might be useful to point out) in both IMAP and SMTP auth. I need to make exim require STARTTLS + CRAM-MD5 when a client authenticates to send an email through it, but not for receiving.

I have tried many configuration options, including client_condition = (empty) in both LOGIN and PLAIN authenticators. With no luck.

How can I do this?

Best Answer

You need to set

auth_advertise_hosts = ${if eq {$tls_cipher}{}{}{*}}