CDPotion.Domain.Security (cdpotion v0.1.4)
Summary
Types
The action to take when a certificate error occurs. continue will continue processing the request and cancel will cancel the request.
An internal certificate ID value.
Details about the security state of the page certificate.
Information about insecure content on the page.
A description of mixed content (HTTP resources on HTTPS pages), as defined by https://www.w3.org/TR/mixed-content/#categories
description not provided :(
description not provided :(
The security level of a page or resource.
An explanation of an factor contributing to the security state.
Security state information about the page.
Functions
Disables tracking security state changes.
Enables tracking security state changes.
Handles a certificate error that fired a certificateError event.
Enable/disable whether all certificate errors should be ignored.
Enable/disable overriding certificate errors. If enabled, all certificate error events need to
be handled by the DevTools client and should be answered with handleCertificateError
commands.
Types
certificate_error_action()
@type certificate_error_action() :: :continue | :cancel
The action to take when a certificate error occurs. continue will continue processing the request and cancel will cancel the request.
certificate_id()
@type certificate_id() :: integer()
An internal certificate ID value.
certificate_security_state()
@type certificate_security_state() :: %{ certificate: [String.t()], certificateHasSha1Signature: boolean(), certificateHasWeakSignature: boolean(), certificateNetworkError: String.t() | nil, cipher: String.t(), issuer: String.t(), keyExchange: String.t(), keyExchangeGroup: String.t() | nil, mac: String.t() | nil, modernSSL: boolean(), obsoleteSslCipher: boolean(), obsoleteSslKeyExchange: boolean(), obsoleteSslProtocol: boolean(), obsoleteSslSignature: boolean(), protocol: String.t(), subjectName: String.t(), validFrom: CDPotion.Domain.Network.time_since_epoch(), validTo: CDPotion.Domain.Network.time_since_epoch() }
Details about the security state of the page certificate.
insecure_content_status()
@type insecure_content_status() :: %{ containedMixedForm: boolean(), displayedContentWithCertErrors: boolean(), displayedInsecureContentStyle: security_state(), displayedMixedContent: boolean(), ranContentWithCertErrors: boolean(), ranInsecureContentStyle: security_state(), ranMixedContent: boolean() }
Information about insecure content on the page.
mixed_content_type()
@type mixed_content_type() :: :blockable | :"optionally-blockable" | :none
A description of mixed content (HTTP resources on HTTPS pages), as defined by https://www.w3.org/TR/mixed-content/#categories
safety_tip_info()
@type safety_tip_info() :: %{ safeUrl: String.t() | nil, safetyTipStatus: safety_tip_status() }
description not provided :(
safety_tip_status()
@type safety_tip_status() :: :badReputation | :lookalike
description not provided :(
security_state()
@type security_state() ::
:unknown | :neutral | :insecure | :secure | :info | :"insecure-broken"
The security level of a page or resource.
security_state_explanation()
@type security_state_explanation() :: %{ certificate: [String.t()], description: String.t(), mixedContentType: mixed_content_type(), recommendations: [String.t()] | nil, securityState: security_state(), summary: String.t(), title: String.t() }
An explanation of an factor contributing to the security state.
visible_security_state()
@type visible_security_state() :: %{ certificateSecurityState: certificate_security_state() | nil, safetyTipInfo: safety_tip_info() | nil, securityState: security_state(), securityStateIssueIds: [String.t()] }
Security state information about the page.
Functions
disable()
Disables tracking security state changes.
enable()
Enables tracking security state changes.
handle_certificate_error(event_id, action)
@spec handle_certificate_error(integer(), certificate_error_action()) :: {String.t(), map()}
Handles a certificate error that fired a certificateError event.
Parameters:
- (Required)
event_id
: The ID of the event. - (Required)
action
: The action to take on the certificate error.
set_ignore_certificate_errors(ignore)
Enable/disable whether all certificate errors should be ignored.
Parameters:
- (Required)
ignore
: If true, all certificate errors will be ignored.
set_override_certificate_errors(override)
Enable/disable overriding certificate errors. If enabled, all certificate error events need to
be handled by the DevTools client and should be answered with handleCertificateError
commands.
Parameters:
- (Required)
override
: If true, certificate errors will be overridden.