Saturday, December 12, 2015

HTTP Strict Transport Security on OpenShift

Just create an .htaccess file and add the HSTS header app-root/repo/php.

# Force https
RewriteEngine on 
RewriteCond %{HTTP:X-Forwarded-Proto} !https 
RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [R,L]

# Add HSTS header
Header set Strict-Transport-Security "max-age=31536000"

转自:http://bit.ly/1IL5MPu

via Chu's Space http://bit.ly/1UfSpZ4

Powered by Blogger Skins. Theme: TheBuckmaker | Free Wordpress Templates. Presents HD TV Futurama Streaming. Featured on Wedding Dresses.