Bug 195383 - Resource Load Statistics: Make it possible to purge only script-accessible cookies
Summary: Resource Load Statistics: Make it possible to purge only script-accessible co...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: John Wilander
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-03-06 16:00 PST by John Wilander
Modified: 2019-03-07 09:22 PST (History)
13 users (show)

See Also:


Attachments
Patch (40.68 KB, patch)
2019-03-06 16:10 PST, John Wilander
no flags Details | Formatted Diff | Diff
Patch (43.36 KB, patch)
2019-03-06 18:56 PST, John Wilander
no flags Details | Formatted Diff | Diff
Patch (44.53 KB, patch)
2019-03-06 19:06 PST, John Wilander
no flags Details | Formatted Diff | Diff
Patch (45.69 KB, patch)
2019-03-06 19:10 PST, John Wilander
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Wilander 2019-03-06 16:00:39 PST
We need the ability to purge all script-accessible cookies while leaving HttpOnly cookies in place.
Comment 1 John Wilander 2019-03-06 16:01:13 PST
<rdar://problem/48570136>
Comment 2 John Wilander 2019-03-06 16:10:03 PST
Created attachment 363806 [details]
Patch
Comment 3 Alex Christensen 2019-03-06 16:21:14 PST
Comment on attachment 363806 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=363806&action=review

> Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm:503
> +    deleteCookiesForHostnames(hostnames, true);

enum class IncludeHTTPOnlyCookies : bool { No, Yes };

> Source/WebKit/NetworkProcess/NetworkProcess.cpp:1603
> +    static NeverDestroyed<OptionSet<WebsiteDataType>> cookieType(std::initializer_list<WebsiteDataType>({ WebsiteDataType::Cookies }));

OptionSet fits in one register, so this is a little overkill.
Comment 4 John Wilander 2019-03-06 18:55:05 PST
(In reply to Alex Christensen from comment #3)
> Comment on attachment 363806 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=363806&action=review
> 
> > Source/WebCore/platform/network/cocoa/NetworkStorageSessionCocoa.mm:503
> > +    deleteCookiesForHostnames(hostnames, true);
> 
> enum class IncludeHTTPOnlyCookies : bool { No, Yes };
> 
> > Source/WebKit/NetworkProcess/NetworkProcess.cpp:1603
> > +    static NeverDestroyed<OptionSet<WebsiteDataType>> cookieType(std::initializer_list<WebsiteDataType>({ WebsiteDataType::Cookies }));
> 
> OptionSet fits in one register, so this is a little overkill.

Thanks! Will fix both of these.
Comment 5 John Wilander 2019-03-06 18:56:08 PST
Created attachment 363830 [details]
Patch
Comment 6 John Wilander 2019-03-06 19:06:57 PST
Created attachment 363832 [details]
Patch
Comment 7 John Wilander 2019-03-06 19:10:49 PST
Created attachment 363833 [details]
Patch
Comment 8 John Wilander 2019-03-06 19:11:36 PST
Added build fixes for ports that use soup and curl.
Comment 9 Brent Fulgham 2019-03-07 09:14:34 PST
Comment on attachment 363833 [details]
Patch

Looks good. r=me. Please keep an eye on the test system after landing.
Comment 10 John Wilander 2019-03-07 09:15:35 PST
Comment on attachment 363833 [details]
Patch

Thanks, Brent!
Comment 11 WebKit Commit Bot 2019-03-07 09:22:33 PST
Comment on attachment 363833 [details]
Patch

Clearing flags on attachment: 363833

Committed r242598: <https://trac.webkit.org/changeset/242598>
Comment 12 WebKit Commit Bot 2019-03-07 09:22:35 PST
All reviewed patches have been landed.  Closing bug.