Skip to content

Instantly share code, notes, and snippets.

@juliojsb
Created March 19, 2016 10:54
Show Gist options
  • Save juliojsb/e6018e646bc350e82d17 to your computer and use it in GitHub Desktop.
Save juliojsb/e6018e646bc350e82d17 to your computer and use it in GitHub Desktop.
Hardening Apache security with TLS and secure ciphers order
Put this at Apache main configuration level (httpd.conf or apache2.conf) or even at VirtualHost level.
To enable only TLS (in all its versions):
SSLProtocol all -SSLv2 -SSLv3
SSLCompression off
SSLHonorCipherOrder on
SSLCipherSuite "ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES256-SHA"
If you want to enable only TLS v1.2:
SSLProtocol -all +TLSv1.2
SSLCompression off
SSLHonorCipherOrder on
SSLCipherSuite "ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256:ECDHE-RSA-AES256-SHA"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment