[varnish] Add HSTS header to every response

This commit is contained in:
Vincent Ambo 2015-11-21 18:25:22 +01:00
parent 4a6dcafaad
commit 8f8cb132fb

View file

@ -30,8 +30,11 @@ sub vcl_backend_response {
if (beresp.ttl < 1m) { if (beresp.ttl < 1m) {
set beresp.ttl = 1m; set beresp.ttl = 1m;
} }
}
# Add an HSTS header to our response sub vcl_deliver {
# Add an HSTS header to everything
set resp.http.Strict-Transport-Security = "max-age=31536000;includeSubdomains;preload";
} }
sub vcl_synth { sub vcl_synth {