summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/HTML
diff options
context:
space:
mode:
authorMacDue <macdue@dueutil.tech>2022-08-25 19:04:27 +0100
committerAndreas Kling <kling@serenityos.org>2022-08-26 00:21:10 +0200
commit8d2c2f7c52b6a1ef975bb32026f14fd1584c737c (patch)
tree3cfd2ef26e6768722ef67e2c357206f1b91d039b /Userland/Libraries/LibWeb/HTML
parent9643a5c63f61741f82f91a49821f9b6b5d2e4e68 (diff)
downloadserenity-8d2c2f7c52b6a1ef975bb32026f14fd1584c737c.zip
LibWeb: Determine the origin when navigating across documents
Diffstat (limited to 'Userland/Libraries/LibWeb/HTML')
-rw-r--r--Userland/Libraries/LibWeb/HTML/BrowsingContext.cpp2
-rw-r--r--Userland/Libraries/LibWeb/HTML/BrowsingContext.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/Userland/Libraries/LibWeb/HTML/BrowsingContext.cpp b/Userland/Libraries/LibWeb/HTML/BrowsingContext.cpp
index 918f5671c2..e45dba2e6d 100644
--- a/Userland/Libraries/LibWeb/HTML/BrowsingContext.cpp
+++ b/Userland/Libraries/LibWeb/HTML/BrowsingContext.cpp
@@ -59,7 +59,7 @@ static HTML::Origin url_origin(AK::URL const& url)
}
// https://html.spec.whatwg.org/multipage/browsers.html#determining-the-origin
-static HTML::Origin determine_the_origin(BrowsingContext const& browsing_context, Optional<AK::URL> url, SandboxingFlagSet sandbox_flags, Optional<HTML::Origin> invocation_origin)
+HTML::Origin determine_the_origin(BrowsingContext const& browsing_context, Optional<AK::URL> url, SandboxingFlagSet sandbox_flags, Optional<HTML::Origin> invocation_origin)
{
// 1. If sandboxFlags has its sandboxed origin browsing context flag set, then return a new opaque origin.
if (sandbox_flags.flags & SandboxingFlagSet::SandboxedOrigin) {
diff --git a/Userland/Libraries/LibWeb/HTML/BrowsingContext.h b/Userland/Libraries/LibWeb/HTML/BrowsingContext.h
index f96bc7a72d..f48ef6d4f5 100644
--- a/Userland/Libraries/LibWeb/HTML/BrowsingContext.h
+++ b/Userland/Libraries/LibWeb/HTML/BrowsingContext.h
@@ -157,4 +157,6 @@ private:
String m_name;
};
+HTML::Origin determine_the_origin(BrowsingContext const& browsing_context, Optional<AK::URL> url, SandboxingFlagSet sandbox_flags, Optional<HTML::Origin> invocation_origin);
+
}