RESOLVED FIXED 187379
Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache
https://bugs.webkit.org/show_bug.cgi?id=187379
Summary Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache
Sihui Liu
Reported 2018-07-05 22:34:00 PDT
Safari needs to show whether a host has HSTS cache and allow user to delete.
Attachments
Patch (18.47 KB, patch)
2018-07-05 22:44 PDT, Sihui Liu
no flags
Archive of layout-test-results from ews100 for mac-sierra (2.31 MB, application/zip)
2018-07-06 00:30 PDT, EWS Watchlist
no flags
Patch (21.75 KB, patch)
2018-07-09 23:56 PDT, Sihui Liu
no flags
Patch (21.39 KB, patch)
2018-07-25 23:23 PDT, Sihui Liu
no flags
Patch for landing (21.32 KB, patch)
2018-07-30 15:43 PDT, Sihui Liu
no flags
Sihui Liu
Comment 1 2018-07-05 22:34:41 PDT
Radar WebKit Bug Importer
Comment 2 2018-07-05 22:34:50 PDT
Sihui Liu
Comment 3 2018-07-05 22:44:48 PDT
EWS Watchlist
Comment 4 2018-07-06 00:30:46 PDT
Comment on attachment 344403 [details] Patch Attachment 344403 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/8453501 New failing tests: media/media-fullscreen-return-to-inline.html
EWS Watchlist
Comment 5 2018-07-06 00:30:48 PDT
Created attachment 344405 [details] Archive of layout-test-results from ews100 for mac-sierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews100 Port: mac-sierra Platform: Mac OS X 10.12.6
Sihui Liu
Comment 6 2018-07-09 23:56:26 PDT
Brent Fulgham
Comment 7 2018-07-25 09:34:07 PDT
Comment on attachment 344673 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=344673&action=review I think this looks very close, but I believe your change to WebsiteDataRecord::displayNameForCookieHostName will break some ITP functionality. r- to revise that section, but otherwise I think this looks good. > Source/WebCore/PAL/ChangeLog:3 > + Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache You have an extra space between 'type' and '_WKWebsite..' > Source/WebKit/ChangeLog:3 > + Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache Ditto. > Source/WebKit/NetworkProcess/cocoa/NetworkProcessCocoa.mm:155 > + HashSet<String>* hostnames = (HashSet<String>*)context; You should use the proper C++ casting here (probably a reinterpret_cast). > Source/WebKit/UIProcess/WebsiteData/WebsiteDataRecord.cpp:51 > + return displayNameForHostName(hostName); I don't think this change is correct, since you are losing the special handling of localhost and removal of the leading period. > Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp:1008 > + Please remove this whitespace change.
Sihui Liu
Comment 8 2018-07-25 23:16:22 PDT
Comment on attachment 344673 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=344673&action=review >> Source/WebCore/PAL/ChangeLog:3 >> + Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache > > You have an extra space between 'type' and '_WKWebsite..' Done. >> Source/WebKit/ChangeLog:3 >> + Add support for fetching and remove type _WKWebsiteDataTypeHSTSCache > > Ditto. Done. >> Source/WebKit/NetworkProcess/cocoa/NetworkProcessCocoa.mm:155 >> + HashSet<String>* hostnames = (HashSet<String>*)context; > > You should use the proper C++ casting here (probably a reinterpret_cast). Yes! Will fix. >> Source/WebKit/UIProcess/WebsiteData/WebsiteDataRecord.cpp:51 >> + return displayNameForHostName(hostName); > > I don't think this change is correct, since you are losing the special handling of localhost and removal of the leading period. displayNameForHostName calls WebCore::topPrivatelyControlledDomain, and in WebCore::topPrivatelyControlledDomain we will check leading period and "localhost", so we could remove the check here. >> Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp:1008 >> + > > Please remove this whitespace change. Done.
Sihui Liu
Comment 9 2018-07-25 23:23:00 PDT
Geoffrey Garen
Comment 10 2018-07-26 13:12:43 PDT
Comment on attachment 345829 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=345829&action=review r=me > Source/WebKit/NetworkProcess/cocoa/NetworkProcessCocoa.mm:155 > + HashSet<String>* hostnames = reinterpret_cast<HashSet<String>*>(context); This can be static_cast because void* can static_cast to any pointer.
Sihui Liu
Comment 11 2018-07-30 15:43:21 PDT
Created attachment 346110 [details] Patch for landing
WebKit Commit Bot
Comment 12 2018-07-30 16:23:47 PDT
Comment on attachment 346110 [details] Patch for landing Clearing flags on attachment: 346110 Committed r234396: <https://trac.webkit.org/changeset/234396>
WebKit Commit Bot
Comment 13 2018-07-30 16:23:49 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.