X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/cfb2f2988c0a396f2d2b167d3c75461b7e811e1c..1096b3b8e2d986bc522c46d8d50b723dfd4dfff8:/config/initializers/secure_headers.rb diff --git a/config/initializers/secure_headers.rb b/config/initializers/secure_headers.rb index daf66bfc7..f09759fa6 100644 --- a/config/initializers/secure_headers.rb +++ b/config/initializers/secure_headers.rb @@ -27,12 +27,12 @@ csp_policy[:img_src] << Settings.storage_url if Settings.key?(:storage_url) csp_policy[:report_uri] << Settings.csp_report_url if Settings.key?(:csp_report_url) cookie_policy = { - :secure => SecureHeaders::OPT_OUT, - :httponly => SecureHeaders::OPT_OUT + :httponly => { :only => ["_osm_session"] } } SecureHeaders::Configuration.default do |config| config.hsts = SecureHeaders::OPT_OUT + config.referrer_policy = "strict-origin-when-cross-origin" if Settings.csp_enforce config.csp = csp_policy