TL;DR
BEAST (Browser Exploits Against SSL/TLS) is an old but still relevant attack that can allow someone to decrypt secure web traffic. This guide shows you how to disable vulnerable TLS versions and ciphers in your server configuration to protect against it.
What is BEAST?
BEAST exploits a weakness in older SSL 3.0 and TLS 1.0 protocols when used with certain cipher suites. It’s complex, but essentially allows an attacker to potentially decrypt HTTPS sessions if they can intercept the traffic.
How to Protect Against BEAST
- Disable SSL 3.0: This is the most important step. SSL 3.0 is very old and has known vulnerabilities, including being susceptible to BEAST attacks.
- Apache: Edit your Apache configuration file (usually
httpd.confor a virtual host file). Add or modify the following line:SSLProtocol -all +TLSv1.2 +TLSv1.3This disables all protocols except TLS 1.2 and TLS 1.3.
- Nginx: Edit your Nginx configuration file (usually
nginx.confor a virtual host file). Add or modify the following line:ssl_protocols TLSv1.2 TLSv1.3;This also disables all protocols except TLS 1.2 and TLS 1.3.
- IIS: Use the IIS Manager to disable SSL 3.0 in the SSL Settings for your website. You’ll find this under Server Certificates, then Bindings.
- Apache: Add or modify the following line in your Apache configuration:
SSLCipherSuite ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES256-SHA:ECDHE-RSA-AES128-SHAThis specifies a set of strong cipher suites. Adjust this list based on your security requirements.
- Nginx: Add or modify the following line in your Nginx configuration:
ssl_ciphers ECDHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES256-SHA;Again, adjust this list as needed.
- This is usually done in conjunction with disabling SSL 3.0 as shown above.
- Apache:
sudo systemctl restart apache2(or similar command depending on your Linux distribution)
- Nginx:
sudo systemctl restart nginx - IIS: Restart the website in IIS Manager.
- Some popular tools include SSL Labs Server Test and TestSSL.sh
Important Considerations
- Browser Compatibility: While rare, very old browsers might not support TLS 1.2 or TLS 1.3. Consider the needs of your users when making changes. However, security should generally take priority over supporting outdated software.
- Regular Updates: Keep your web server and operating system up to date with the latest security patches.