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
[Cocoa] Add plumbing for a couple more platform flags on ResourceRequest #13150
Conversation
EWS run on previous version of this PR (hash 2ebc5d9) |
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.
Otherwise, lgtm.
Thanks for the reviews! |
EWS run on previous version of this PR (hash 4bc430a) |
EWS run on current version of this PR (hash e1837a3) |
https://bugs.webkit.org/show_bug.cgi?id=255927 rdar://105895713 Reviewed by Tim Horton and Matthew Finkel. Add plumbing for two flags on `ResourceRequest`: `PrivacyProxyFailClosedForUnreachableNonMainHosts` and `UseNetworkConnectionIntegrity`, which both map to SPI properties on `NSURLRequest`. In a subsequent patch, this will make it possible for WebKit clients to specify these flags on a URL request when loading a web view, and have this state propagate to everywhere (including the resource request used for performing preconnect). * Source/WebCore/platform/network/ResourceRequestBase.cpp: (WebCore::ResourceRequestBase::setAsIsolatedCopy): (WebCore::ResourceRequestBase::setIsAppInitiated): (WebCore::ResourceRequestBase::setPrivacyProxyFailClosedForUnreachableNonMainHosts): (WebCore::ResourceRequestBase::setUseNetworkConnectionIntegrity): Add support for the new flags here; this closely follows the existing pattern used to plumb whether or not the request is app-initiated through `ResourceRequest`. * Source/WebCore/platform/network/ResourceRequestBase.h: (WebCore::ResourceRequestBase::RequestData::RequestData): (WebCore::ResourceRequestBase::privacyProxyFailClosedForUnreachableNonMainHosts const): (WebCore::ResourceRequestBase::useNetworkConnectionIntegrity const): * Source/WebCore/platform/network/cf/ResourceRequest.h: * Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp: (WebCore::ResourceRequest::updateFromDelegatePreservingOldProperties): * Source/WebCore/platform/network/cocoa/ResourceRequestCocoa.mm: (WebCore::ResourceRequest::ResourceRequest): (WebCore::ResourceRequest::getResourceRequestPlatformData const): (WebCore::configureRequestWithData): Add a new helper method to set some policy flags on the platform URL request, to avoid duplicating this logic in the two methods below. (WebCore::ResourceRequest::doUpdatePlatformRequest): (WebCore::ResourceRequest::doUpdatePlatformHTTPBody): * Source/WebKit/Shared/Cocoa/WebCoreArgumentCodersCocoa.serialization.in: * Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in: Add IPC encoding/decoding support for the platform flags. Canonical link: https://commits.webkit.org/263390@main
e1837a3
to
2092e71
Compare
Committed 263390@main (2092e71): https://commits.webkit.org/263390@main Reviewed commits have been landed. Closing PR #13150 and removing active labels. |
2092e71
e1837a3
π§ͺ gtk-wk2π§ͺ mac-AS-debug-wk2