How to improve Caddy's HTTPS configuration
Caddy’s default TLS configuration is very good. It includes a lot of features that older and well-known servers like Nginx or Apache don’t enable by default.
From the tls module’s documentation:
Caddy implements these TLS features for you automatically. It is the only server to do so by default:
- Session identifiers
- Session ticket key rotation
- OCSP stapling
- Dynamic record sizing
- Application-layer protocol negotiation
- Forward secrecy
- HTTP/2 (for the HTTP server)
- Certificate management (including auto-renew)
- Man-In-The-Middle detection (for HTTPS sites)
Pretty awesome isn’t it? It also enables TLS 1.2 only by default and will support TLS 1.3 soon. FYI Caddy does not have its own TLS implementation by relies on the crypto/tls
module of Go.