#include "third_party/blink/renderer/core/frame/csp/execution_context_csp_delegate.h"
#include "services/network/public/cpp/web_sandbox_flags.h"
#include "services/network/public/mojom/web_sandbox_flags.mojom-blink.h"
#include "third_party/blink/public/common/security_context/insecure_request_policy.h"
#include "third_party/blink/public/mojom/devtools/inspector_issue.mojom-blink.h"
#include "third_party/blink/public/mojom/frame/frame.mojom-blink.h"
#include "third_party/blink/public/mojom/security_context/insecure_request_policy.mojom-blink.h"
#include "third_party/blink/renderer/bindings/core/v8/capture_source_location.h"
#include "third_party/blink/renderer/core/dom/document.h"
#include "third_party/blink/renderer/core/events/security_policy_violation_event.h"
#include "third_party/blink/renderer/core/execution_context/execution_context.h"
#include "third_party/blink/renderer/core/execution_context/security_context.h"
#include "third_party/blink/renderer/core/frame/csp/csp_violation_report_body.h"
#include "third_party/blink/renderer/core/frame/local_dom_window.h"
#include "third_party/blink/renderer/core/frame/local_frame.h"
#include "third_party/blink/renderer/core/frame/local_frame_client.h"
#include "third_party/blink/renderer/core/frame/report.h"
#include "third_party/blink/renderer/core/frame/reporting_context.h"
#include "third_party/blink/renderer/core/inspector/inspector_audits_issue.h"
#include "third_party/blink/renderer/core/loader/document_loader.h"
#include "third_party/blink/renderer/core/loader/ping_loader.h"
#include "third_party/blink/renderer/core/probe/core_probes.h"
#include "third_party/blink/renderer/core/workers/worker_global_scope.h"
#include "third_party/blink/renderer/core/workers/worklet_global_scope.h"
#include "third_party/blink/renderer/platform/bindings/source_location.h"
#include "third_party/blink/renderer/platform/instrumentation/use_counter.h"
#include "third_party/blink/renderer/platform/network/encoded_form_data.h"
#include "third_party/blink/renderer/platform/weborigin/security_origin.h"
namespace blink {
ExecutionContextCSPDelegate::ExecutionContextCSPDelegate(
ExecutionContext& execution_context)
: … { … }
void ExecutionContextCSPDelegate::Trace(Visitor* visitor) const { … }
const SecurityOrigin* ExecutionContextCSPDelegate::GetSecurityOrigin() { … }
const KURL& ExecutionContextCSPDelegate::Url() const { … }
void ExecutionContextCSPDelegate::SetSandboxFlags(
network::mojom::blink::WebSandboxFlags mask) { … }
void ExecutionContextCSPDelegate::SetRequireTrustedTypes() { … }
void ExecutionContextCSPDelegate::AddInsecureRequestPolicy(
mojom::blink::InsecureRequestPolicy policy) { … }
std::unique_ptr<SourceLocation>
ExecutionContextCSPDelegate::GetSourceLocation() { … }
std::optional<uint16_t> ExecutionContextCSPDelegate::GetStatusCode() { … }
String ExecutionContextCSPDelegate::GetDocumentReferrer() { … }
void ExecutionContextCSPDelegate::DispatchViolationEvent(
const SecurityPolicyViolationEventInit& violation_data,
Element* element) { … }
void ExecutionContextCSPDelegate::PostViolationReport(
const SecurityPolicyViolationEventInit& violation_data,
const String& stringified_report,
bool is_frame_ancestors_violation,
const Vector<String>& report_endpoints,
bool use_reporting_api) { … }
void ExecutionContextCSPDelegate::Count(WebFeature feature) { … }
void ExecutionContextCSPDelegate::AddConsoleMessage(
ConsoleMessage* console_message) { … }
void ExecutionContextCSPDelegate::AddInspectorIssue(AuditsIssue issue) { … }
void ExecutionContextCSPDelegate::DisableEval(const String& error_message) { … }
void ExecutionContextCSPDelegate::SetWasmEvalErrorMessage(
const String& error_message) { … }
void ExecutionContextCSPDelegate::ReportBlockedScriptExecutionToInspector(
const String& directive_text) { … }
void ExecutionContextCSPDelegate::DidAddContentSecurityPolicies(
WTF::Vector<network::mojom::blink::ContentSecurityPolicyPtr> policies) { … }
SecurityContext& ExecutionContextCSPDelegate::GetSecurityContext() { … }
Document* ExecutionContextCSPDelegate::GetDocument() { … }
void ExecutionContextCSPDelegate::DispatchViolationEventInternal(
const SecurityPolicyViolationEventInit* violation_data,
Element* element) { … }
}