info > postfix-tls(1)

📄 POSTFIX-TLS(1)

📝 NAME

postfix-tls - Postfix TLS management

🚀 Quick Reference

Use CaseCommandDescription
🔐 Enable SMTP Client TLSpostfix tls enable-clientEnable opportunistic TLS in the Postfix SMTP client.
🔐 Enable SMTP Server TLSpostfix tls enable-serverCreate a new private key and self-signed certificate and enable opportunistic TLS in the server.
🔑 Generate New Server Key & Certpostfix tls new-server-keyCreate a new private key and self-signed certificate without deploying them.
📜 Generate New Server Cert (same key)postfix tls new-server-certGenerate a new certificate reusing the existing private key.
📂 Deploy Server Cert & Keypostfix tls deploy-server-cert <certfile> <keyfile>Deploy the generated certificate and private key.
📝 Output CSRpostfix tls output-server-csrWrite a CSR for the specified keyfile to stdout.
🌐 Output DANE TLSA Recordspostfix tls output-server-tlsaWrite DANE TLSA RRset for the specified keys to stdout.
✅ Check Client Defaultspostfix tls all-default-clientExit 0 if all SMTP client TLS settings are at default.
✅ Check Server Defaultspostfix tls all-default-serverExit 0 if all SMTP server TLS settings are at default.

🔖 SYNOPSIS

postfix tls subcommand

📖 DESCRIPTION

The "postfix tls subcommand" feature enables opportunistic TLS in the Postfix SMTP client or server, and manages Postfix SMTP server private keys and certificates.

The following subcommands are available:

enable-client

Enable opportunistic TLS in the Postfix SMTP client, if all SMTP client TLS settings are at their default values. Otherwise, suggest parameter settings without making any changes.

Options:

See also the all-default-client subcommand.

enable-server

Create a new private key and self-signed server certificate and enable opportunistic TLS in the Postfix SMTP server, if all SMTP server TLS settings are at their default values. Otherwise, suggest parameter settings without making any changes.

Options:

See also the all-default-server subcommand.

new-server-key

Create a new private key and self-signed server certificate, but do not deploy them. Log and display commands to deploy the new key and corresponding certificate. Also log and display commands to output a corresponding CSR or TLSA records which may be needed to obtain a CA certificate or to update DNS before the new key can be deployed.

Options:

Important Notes:

new-server-cert

This is just like new-server-key except that, rather than generating a new private key, any currently deployed private key is copied to the new key file. Thus if you're publishing DANE TLSA "3 1 1" or "3 1 2" records, there is no need to update DNS records. The algorithm and bits arguments are used only if no key of the same algorithm is already configured.

Important Notes:

deploy-server-cert

This subcommand deploys the certificates in certfile and private key in keyfile (which are typically generated by the commands above, which will also log and display the full command needed to deploy the generated key and certificate). After the new certificate and key are deployed any obsolete keys and certificates may be removed by hand. The keyfile and certfile filenames may be relative to the Postfix configuration directory.

output-server-csr

Write to stdout a certificate signing request (CSR) for the specified keyfile.

Options:

output-server-tlsa

Write to stdout a DANE TLSA RRset suitable for a port 25 SMTP server on host hostname with keys from any of the specified keyfile values. The default hostname is the value of the myhostname main.cf parameter.

Options:

⚙️ AUXILIARY COMMANDS

all-default-client

Exit with status 0 (success) if all SMTP client TLS settings are at their default values. Otherwise, exit with a non-zero status. This is typically used as follows:

postfix tls all-default-client &&\
        postfix tls enable-client

all-default-server

Exit with status 0 (success) if all SMTP server TLS settings are at their default values. Otherwise, exit with a non-zero status. This is typically used as follows:

postfix tls all-default-server &&\
        postfix tls enable-server

⚙️ CONFIGURATION PARAMETERS

The "postfix tls subcommand" feature reads or updates the following configuration parameters.

📚 SEE ALSO

📄 README FILES

Use "postconf readme_directory" or "postconf html_directory" to locate this information.

📜 LICENSE

The Secure Mailer license must be distributed with this software.

📅 HISTORY

The "postfix tls" command was introduced with Postfix version 3.1.

👤 AUTHOR(S)

Viktor Dukhovni

postfix-tls(1)
📄 POSTFIX-TLS(1) 📝 NAME 🚀 Quick Reference 🔖 SYNOPSIS 📖 DESCRIPTION
enable-client enable-server new-server-key new-server-cert deploy-server-cert output-server-csr output-server-tlsa
⚙️ AUXILIARY COMMANDS
all-default-client all-default-server
⚙️ CONFIGURATION PARAMETERS 📚 SEE ALSO 📄 README FILES 📜 LICENSE 📅 HISTORY 👤 AUTHOR(S)

Generated by phpman v4.9.26-1-g511901d Author: Che Dong Under GNU General Public License
2026-08-08 14:22 @216.73.216.150
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 Transitional!Valid CSS!
Enhanced by LLM: deepseek-v4-flash / taotoken.net / www.chedong.com - original format