TLS
Cheat sheet · https://pcornel.dk/topic.php?topic=2879
Answer
TLS on a Linux web server encrypts HTTPS: the server presents its certificate and intermediate chain, negotiates TLS 1.2/1.3 and ciphers, and keeps the private key readable only by the server.
Remember
Serve the full chain (leaf + intermediates). Disable TLS 1.0/1.1. Renew certificates automatically (certbot timer) and reload the server after renewal. The key must match the certificate.
First checks
openssl s_client -connect <host>:443 -servername <name>— handshake and chain checksystemctl status nginx|apache2|httpd— web server statenginx -t / apachectl configtest— configuration testss -ltnp | grep -E ':80|:443'— listening portscurl -vI https://<name>— response, headers and TLStail -f /var/log/nginx/error.log— error log (or apache2/httpd)
Verify in this order
certificate and chain installed → key readable by the server → TLS handshake with SNI → client validates chain and name
Where it usually breaks
First mismatch in persistent intent → provider/parser/generator → kernel/userspace runtime → dependency/security context → logs/counters → consumer-visible read-back; preserve identity/native diagnostic/pre-state before mutation.
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=2879