-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash under NetworkProcess::addAllowedFirstPartyForCookies() #11506
Crash under NetworkProcess::addAllowedFirstPartyForCookies() #11506
Conversation
EWS run on previous version of this PR (hash eb6e9f3) |
eb6e9f3
to
514fd82
Compare
EWS run on previous version of this PR (hash 514fd82) |
514fd82
to
6d2fe4a
Compare
EWS run on current version of this PR (hash 6d2fe4a) |
@@ -395,6 +395,9 @@ void NetworkProcess::createNetworkConnectionToWebProcess(ProcessIdentifier ident | |||
|
|||
void NetworkProcess::addAllowedFirstPartyForCookies(WebCore::ProcessIdentifier processIdentifier, WebCore::RegistrableDomain&& firstPartyForCookies, LoadedWebArchive loadedWebArchive, CompletionHandler<void()>&& completionHandler) | |||
{ | |||
if (!HashSet<WebCore::RegistrableDomain>::isValidValue(firstPartyForCookies)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add this to NetworkProcess::webProcessWillLoadWebArchive too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
decltype(m_allowedFirstPartiesForCookies)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is a little more complicated than this, here is the type:
HashMap<WebCore::ProcessIdentifier, std::pair<LoadedWebArchive, HashSet<WebCore::RegistrableDomain>>>
I only care about the inner HashSet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
webProcessWillLoadWebArchive
webProcessWillLoadWebArchive doesn't modify the HashSet containing RegistrableDomains, only the top-level HashMap.
@@ -395,6 +395,9 @@ void NetworkProcess::createNetworkConnectionToWebProcess(ProcessIdentifier ident | |||
|
|||
void NetworkProcess::addAllowedFirstPartyForCookies(WebCore::ProcessIdentifier processIdentifier, WebCore::RegistrableDomain&& firstPartyForCookies, LoadedWebArchive loadedWebArchive, CompletionHandler<void()>&& completionHandler) | |||
{ | |||
if (!HashSet<WebCore::RegistrableDomain>::isValidValue(firstPartyForCookies)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
decltype(m_allowedFirstPartiesForCookies)
https://bugs.webkit.org/show_bug.cgi?id=253895 rdar://104526219 Reviewed by Alex Christensen. Make sure the registrable domain is valid before we try inserting it into the HashSet. * Source/WebKit/NetworkProcess/NetworkProcess.cpp: (WebKit::NetworkProcess::addAllowedFirstPartyForCookies): Canonical link: https://commits.webkit.org/261656@main
6d2fe4a
to
e2b561a
Compare
Committed 261656@main (e2b561a): https://commits.webkit.org/261656@main Reviewed commits have been landed. Closing PR #11506 and removing active labels. |
e2b561a
6d2fe4a
π wincairoπ§ͺ wpe-wk2π§ͺ ios-wk2π§ͺ api-iosπ§ͺ mac-wk1π§ͺ gtk-wk2π§ͺ api-gtkπ§ͺ mac-AS-debug-wk2π watch