class

Marten::Conf::GlobalSettings::ContentSecurityPolicy

Inherits Reference / Object

Allows to configure settings related to the Content-Security-Policy middleware.

Constructors

Instance methods

base_uri=(arg)
Source
block_all_mixed_content=(arg)
Source
child_src=(arg)
Source
connect_src=(arg)
Source
default_policy

Returns the default Content-Security-Policy.

Source
default_policy=(default_policy : Marten::HTTP::ContentSecurityPolicy)

Allows to set the default Content-Security-Policy.

Source
default_src=(arg)
Source
font_src=(arg)
Source
form_action=(arg)
Source
frame_ancestors=(arg)
Source
frame_src=(arg)
Source
img_src=(arg)
Source
manifest_src=(arg)
Source
media_src=(arg)
Source
nonce_directives

Returns an array of directives where a dynamically-generated nonce will be included.

For example, if this setting is set to ["script-src"], a nonce-<b64-value> value will be added to the script-src directive.

Source
nonce_directives=(nonce_directives : Nil | Array(String))

Allows to set the array of directives where a dynamically-generated nonce will be included.

Source
object_src=(arg)
Source
plugin_types=(arg)
Source
prefetch_src=(arg)
Source
report_only

Indicates whether policy violations are reported without enforcing it.

Source
report_only=(report_only : Bool)

Allows set whether to report violations of the policy without enforcing it.

Source
report_only?

Indicates whether policy violations are reported without enforcing it.

Source
report_to=(arg)
Source
report_uri=(arg)
Source
require_sri_for=(arg)
Source
sandbox=(arg)
Source
script_src=(arg)
Source
script_src_attr=(arg)
Source
script_src_elem=(arg)
Source
style_src=(arg)
Source
style_src_attr=(arg)
Source
style_src_elem=(arg)
Source
upgrade_insecure_requests=(arg)
Source
worker_src=(arg)
Source