View source: R/SecurityHeaders_helpers.R
sts | R Documentation |
Strict-Transport-Security
headerThis helper function exists mainly to document the possible values and prevent misspelled directives. It returns a bare list. See MDN for more information on the header
sts(max_age, include_sub_domains = NULL, preload = NULL)
max_age |
The maximum age the settings should be kept in the browser cache, in seconds. Recommended value is 63072000 (2 years) |
include_sub_domains |
Logical. Should subdomains be included in the policy |
preload |
Allow the settings to be cached and preloaded by a third-party,
e.g. Google or Mozilla. Can only be set if |
A bare list with the input arguments
# Default settings
sts(
max_age = 63072000,
include_sub_domains = TRUE
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.