diff --git a/README.md b/README.md index 412604c..809a6fe 100644 --- a/README.md +++ b/README.md @@ -69,6 +69,7 @@ None * `postfix_smtpd_tls_cert_file` [default: `/etc/ssl/certs/ssl-cert-snakeoil.pem`]: Path to certificate file * `postfix_smtpd_tls_key_file` [default: `/etc/ssl/certs/ssl-cert-snakeoil.key`]: Path to key file + * `postfix_smtpd_security_level` [optional]: The SMTP TLS security level for the Postfix SMTP server ([see](http://www.postfix.org/postconf.5.html#smtpd_tls_security_level)) * `postfix_raw_options` [default: `[]`]: List of lines (to pass extra (unsupported) configuration) ## Dependencies diff --git a/templates/etc/postfix/main.cf.j2 b/templates/etc/postfix/main.cf.j2 index 0ca384e..2be8118 100644 --- a/templates/etc/postfix/main.cf.j2 +++ b/templates/etc/postfix/main.cf.j2 @@ -25,7 +25,10 @@ compatibility_level = {{ postfix_compatibility_level }} # TLS parameters smtpd_tls_cert_file = {{ postfix_smtpd_tls_cert_file }} smtpd_tls_key_file = {{ postfix_smtpd_tls_key_file }} -smtpd_use_tls=yes +smtpd_use_tls = yes +{% if postfix_smtpd_tls_security_level is defined %} +smtpd_tls_security_level = {{ postfix_smtpd_tls_security_level }} +{% endif %} smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache