Every website transmits data between servers and browsers. Without encryption, that data travels in plain text—readable by anyone who intercepts it. Passwords, credit card numbers, session tokens, private messages: all exposed.
SSL/TLS encryption is no longer optional. Major browsers now flag HTTP sites as "Not Secure," Google penalizes them in search rankings, and users expect the padlock icon. But deploying TLS is just the starting point. Misconfigured TLS is nearly as dangerous as no TLS at all.
Weak cipher suites, outdated protocols, missing security headers, and poor certificate management create vulnerabilities that attackers actively exploit. In 2023, over 40% of TLS-enabled websites still supported deprecated TLS 1.0 or 1.1, and 25% used weak cipher suites vulnerable to downgrade attacks.
Protocol Versions: Deprecate the Old, Embrace the New
TLS 1.0 and 1.1 are dead. Both were officially deprecated by the IETF in 2021 and should be disabled on all servers. They're vulnerable to BEAST, POODLE, and downgrade attacks.
TLS 1.2 (2008) is the minimum acceptable version. It introduced AEAD ciphers (AES-GCM, ChaCha20-Poly1305) and SHA-256 for HMAC. Most modern systems support it.
TLS 1.3 (2018) is the current standard. It removes legacy cipher suites, reduces handshake latency (1-RTT instead of 2-RTT), and provides forward secrecy by default. Enable it wherever possible.
# Nginx: Force TLS 1.2 and 1.3 only
ssl_protocols TLSv1.2 TLSv1.3;
# Apache: Force TLS 1.2 and 1.3 only
SSLProtocol -all +TLSv1.2 +TLSv1.3
Certificate Types
Domain Validated (DV): Cheapest and fastest. CA verifies you control the domain (via DNS or HTTP challenge). Suitable for most websites.
Organization Validated (OV): CA verifies your organization exists. Displays company name in certificate details. Good for business sites.
Extended Validation (EV): Most rigorous. CA performs legal and operational checks. Historically showed company name in browser address bar, but modern browsers removed this UI.
Let's Encrypt: Free, automated, open CA. Issues DV certificates with 90-day validity. Perfect for most use cases.
Nginx SSL Configuration
# /etc/nginx/sites-available/example.com
server {
listen 443 ssl http2;
server_name example.com www.example.com;
# Certificate and private key
ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem;
# Protocol versions
ssl_protocols TLSv1.2 TLSv1.3;
# Cipher suites (Mozilla Intermediate)
ssl_ciphers 'ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256';
ssl_prefer_server_ciphers off;
# Session cache
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
# OCSP stapling
ssl_stapling on;
ssl_stapling_verify on;
# HSTS
add_header Strict-Transport-Security "max-age=63072000" always;
}
Apache SSL Configuration
# /etc/apache2/sites-available/example.com-ssl.conf
<VirtualHost *:443>
ServerName example.com
DocumentRoot /var/www/html
# Enable SSL
SSLEngine on
SSLCertificateFile /etc/letsencrypt/live/example.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/example.com/privkey.pem
# Protocol versions
SSLProtocol -all +TLSv1.2 +TLSv1.3
# OCSP stapling
SSLUseStapling on
SSLStaplingCache "shmcb:logs/ssl_stapling(32768)"
# HSTS
Header always set Strict-Transport-Security "max-age=63072000"
</VirtualHost>
HSTS (HTTP Strict Transport Security)
HSTS forces browsers to use HTTPS for all future visits. Once a browser sees the HSTS header, it won't allow HTTP connections—even if the user types http:// in the address bar.
# Enable HSTS (start with short max-age for testing)
add_header Strict-Transport-Security "max-age=300" always;
# After testing, increase to 2 years
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;
OCSP Stapling
Online Certificate Status Protocol (OCSP) lets browsers check if a certificate has been revoked. Without stapling, the browser contacts the CA directly (slow, privacy-leaking). With stapling, the server fetches the OCSP response and includes it in the TLS handshake.
# Nginx OCSP stapling
ssl_stapling on;
ssl_stapling_verify on;
# Apache OCSP stapling
SSLUseStapling on
SSLStaplingCache "shmcb:logs/ssl_stapling(32768)"
Automated Renewal with Certbot
Let's Encrypt certificates expire after 90 days. Automate renewal with certbot:
# Install certbot
sudo apt install certbot python3-certbot-nginx
# Obtain certificate (Nginx)
sudo certbot --nginx -d example.com -d www.example.com
# Test renewal
sudo certbot renew --dry-run
# Auto-renewal via cron
0 */12 * * * root certbot renew --quiet
Certificate Monitoring
Monitor certificate expiration to avoid outages:
# Check certificate expiration
echo | openssl s_client -servername example.com -connect example.com:443 2>/dev/null | openssl x509 -noout -dates
Use monitoring tools like SSL Labs Monitor, Uptime Robot, or Nagios/Zabbix with check_ssl_cert plugin.
Certificate Transparency
Certificate Transparency (CT) logs record all issued certificates publicly. This prevents CAs from issuing rogue certificates without detection. Modern browsers require CT compliance.
Monitor CT logs for unauthorized certificates at crt.sh.
CAA Records
Certification Authority Authorization (CAA) DNS records specify which CAs are allowed to issue certificates for your domain:
# Only Let's Encrypt can issue certificates
example.com. CAA 0 issue "letsencrypt.org"
# Report unauthorized issuance attempts
example.com. CAA 0 iodef "mailto:security@example.com"
TLS 1.3 Benefits
• Faster handshakes: TLS 1.3 reduces round trips from 2-RTT to 1-RTT
• Forward secrecy by default: All TLS 1.3 cipher suites provide forward secrecy
• Simplified cipher suites: Only five AEAD cipher suites remain
SSL Labs
Qualys SSL Labs (ssllabs.com/ssltest) provides comprehensive TLS testing. Aim for an A+ rating.
Command-Line Verification
# Test TLS connection
openssl s_client -connect example.com:443 -servername example.com
# Check supported protocols
nmap --script ssl-enum-ciphers -p 443 example.com
# Verify certificate chain
curl -vI https://example.com
# Test HSTS header
curl -I https://example.com | grep Strict-Transport-Security
Secure Certificate Storage
Swiss data centers provide physical and legal protections for private keys:
• Physical security: Biometric access, 24/7 monitoring, redundant facilities
• Legal protection: Swiss law prohibits unauthorized access to private keys
• No third-party disclosure: Foreign governments cannot compel key disclosure without Swiss court approval
Data Sovereignty
TLS certificates and private keys are sensitive assets. Hosting them in Switzerland ensures:
• Independence from Five Eyes jurisdiction: US CLOUD Act cannot compel Swiss hosting providers to hand over private keys
• FADP compliance: Swiss Federal Act on Data Protection aligns with strong cryptographic key management requirements
• Predictable legal environment: No sudden policy changes driven by foreign intelligence demands
Infrastructure Reliability
Swiss hosting infrastructure provides:
• High availability (99.95%+ uptime)
• Low-latency TLS handshakes
• Robust DDoS protection for TLS endpoints
Protocol and Ciphers:
✅ Disable TLS 1.0 and 1.1
✅ Enable TLS 1.2 and 1.3
✅ Use Mozilla Intermediate cipher suite
✅ Generate strong DH parameters (2048-bit minimum)
Certificates:
✅ Obtain certificate from trusted CA
✅ Use RSA 2048-bit or ECDSA P-256 keys
✅ Include full certificate chain
✅ Automate renewal (certbot cron)
Security Headers:
✅ Enable HSTS
✅ Enable OCSP stapling
✅ Set X-Frame-Options, X-Content-Type-Options headers
DNS and Monitoring:
✅ Configure CAA records
✅ Monitor certificate expiration (30-day alerts)
✅ Test with SSL Labs (aim for A+)
TLS is no longer just about the padlock icon—it's a complex system of protocols, ciphers, certificates, and configurations that must work together correctly. A misconfigured TLS deployment can be as dangerous as no encryption at all.
Modern TLS configuration means: deprecating old protocols, selecting strong cipher suites, automating certificate management, enabling security headers, and continuously monitoring for vulnerabilities. The practices outlined here will help you deploy TLS correctly and maintain it over time.
If you're running production web infrastructure, consider where your servers and private keys are hosted. Swiss hosting provides legal protections and infrastructure reliability that align with security-first deployments.
Ready to deploy secure TLS infrastructure? Explore our dedicated servers with full root access for custom TLS configurations, or check out our VPS options for flexible SSL/TLS deployments.