Conditions | 1 |
Total Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | # frozen_string_literal: true |
||
15 | def config_x_headers(config) |
||
16 | # Add "; preload" and submit the site to hstspreload.org for best protection. |
||
17 | config.hsts = "max-age=#{1.week.to_i}" |
||
18 | config.x_frame_options = 'DENY' |
||
19 | config.x_content_type_options = 'nosniff' |
||
20 | config.x_xss_protection = '1; mode=block' |
||
21 | config.x_download_options = 'noopen' |
||
22 | config.x_permitted_cross_domain_policies = 'none' |
||
23 | config.referrer_policy = %w[origin-when-cross-origin strict-origin-when-cross-origin] |
||
24 | end |
||
25 | |||
42 |