Add commas
[WebKit-https.git] / Source / WebKit / ChangeLog
1 2018-01-04  Keith Rollin  <krollin@apple.com>
2
3         Add commas
4         https://bugs.webkit.org/show_bug.cgi?id=181295
5         <rdar://problem/35802295>
6
7         Reviewed by Brent Fulgham.
8
9         Fix a problem introduced in r226226 where the emitted JSON didn't
10         include some required commas.
11
12         * NetworkProcess/NetworkResourceLoader.cpp:
13         (WebKit::NetworkResourceLoader::logCookieInformation const):
14
15 2018-01-04  Eric Carlson  <eric.carlson@apple.com>
16
17         [MediaStream] Add Mock screen capture source
18         https://bugs.webkit.org/show_bug.cgi?id=181291
19         <rdar://problem/36298164>
20
21         Reviewed by Dean Jackson.
22
23         * Shared/WebCoreArgumentCoders.cpp:
24         (IPC::ArgumentCoder<MediaConstraints>::decode):
25         (IPC::ArgumentCoder<CaptureDevice>::encode): Deleted, moved to CaptureDevice.h
26         (IPC::ArgumentCoder<CaptureDevice>::decode): Ditto.
27         * Shared/WebCoreArgumentCoders.h:
28
29         * UIProcess/API/Cocoa/WKWebViewPrivate.h: Add _WKCaptureDeviceDisplay.
30         * UIProcess/Cocoa/UIDelegate.mm:
31         (WebKit::requestUserMediaAuthorizationForDevices): Deal with display capture.
32         (WebKit::UIDelegate::UIClient::decidePolicyForUserMediaPermissionRequest): Ditto.
33
34         * UIProcess/UserMediaPermissionRequestManagerProxy.cpp:
35         (WebKit::UserMediaPermissionRequestManagerProxy::userMediaAccessWasDenied): requiresAudio -> requiresAudioCapture.
36         (WebKit::UserMediaPermissionRequestManagerProxy::searchForGrantedRequest const): Never reuse
37         a previously granted display capture request.
38
39         * UIProcess/UserMediaPermissionRequestProxy.cpp:
40         (WebKit::UserMediaPermissionRequestProxy::allow): Search the eligible devices instead of asking
41         the source center to find devices.
42         * UIProcess/UserMediaPermissionRequestProxy.h:
43         (WebKit::UserMediaPermissionRequestProxy::requiresAudioCapture const): Renamed.
44         (WebKit::UserMediaPermissionRequestProxy::requiresVideoCapture const): Ditto.
45         (WebKit::UserMediaPermissionRequestProxy::requiresDisplayCapture const): New.
46         (WebKit::UserMediaPermissionRequestProxy::requiresAudio const): Deleted.
47         (WebKit::UserMediaPermissionRequestProxy::requiresVideo const): Deleted.
48
49 2018-01-04  Youenn Fablet  <youenn@apple.com>
50
51         FetchResponse should set its internal response text encoding name
52         https://bugs.webkit.org/show_bug.cgi?id=181284
53
54         Reviewed by Alex Christensen.
55
56         * WebProcess/Storage/ServiceWorkerClientFetch.cpp:
57         (WebKit::ServiceWorkerClientFetch::didReceiveResponse): Set default encoding to UTF-8.
58
59 2018-01-04  Youenn Fablet  <youenn@apple.com>
60
61         Implement Cache API partitioning based on ClientOrigin
62         https://bugs.webkit.org/show_bug.cgi?id=181240
63
64         Reviewed by Alex Christensen.
65
66         open and retrieveCaches now take a ClientOrigin instead of a String.
67         Updated cache filesystem path computation to take both client origin and top origin.
68
69         When clearing an origin, caches whose client origin or top origin matches the origin are cleared.
70         Caches are added to the web site data of their client origin with their corresponding cache size.
71         Caches are added to the web site data of their top origin with a size equal to 0.
72
73         Updated memory representation dumping used for test to include both top and client origins.
74
75         * NetworkProcess/NetworkProcess.cpp:
76         (WebKit::NetworkProcess::deleteWebsiteDataForOrigins):
77         * NetworkProcess/cache/CacheStorageEngine.cpp:
78         (WebKit::CacheStorage::Engine::cachesRootPath):
79         (WebKit::CacheStorage::Engine::open):
80         (WebKit::CacheStorage::Engine::remove):
81         (WebKit::CacheStorage::Engine::retrieveCaches):
82         (WebKit::CacheStorage::Engine::readCachesFromDisk):
83         (WebKit::CacheStorage::Engine::removeCaches):
84         (WebKit::CacheStorage::Engine::fetchEntries):
85         (WebKit::CacheStorage::Engine::clearCachesForOrigin):
86         (WebKit::CacheStorage::Engine::clearMemoryRepresentation):
87         (WebKit::CacheStorage::Engine::representation):
88         * NetworkProcess/cache/CacheStorageEngine.h:
89         * NetworkProcess/cache/CacheStorageEngineCache.cpp:
90         (WebKit::CacheStorage::Cache::Cache):
91         * NetworkProcess/cache/CacheStorageEngineCaches.cpp:
92         (WebKit::CacheStorage::Caches::retrieveOriginFromDirectory):
93         (WebKit::CacheStorage::Caches::Caches):
94         (WebKit::CacheStorage::Caches::storeOrigin):
95         (WebKit::CacheStorage::Caches::readOrigin):
96         (WebKit::CacheStorage::Caches::open):
97         * NetworkProcess/cache/CacheStorageEngineCaches.h:
98         (WebKit::CacheStorage::Caches::create):
99         (WebKit::CacheStorage::Caches::origin const):
100         * NetworkProcess/cache/CacheStorageEngineConnection.cpp:
101         (WebKit::CacheStorageEngineConnection::open):
102         (WebKit::CacheStorageEngineConnection::caches):
103         (WebKit::CacheStorageEngineConnection::clearMemoryRepresentation):
104         * NetworkProcess/cache/CacheStorageEngineConnection.h:
105         * NetworkProcess/cache/CacheStorageEngineConnection.messages.in:
106         * WebProcess/Cache/WebCacheStorageConnection.cpp:
107         (WebKit::WebCacheStorageConnection::doOpen):
108         (WebKit::WebCacheStorageConnection::doRetrieveCaches):
109         (WebKit::WebCacheStorageConnection::clearMemoryRepresentation):
110         * WebProcess/Cache/WebCacheStorageConnection.h:
111
112 2018-01-04  Youenn Fablet  <youenn@apple.com>
113
114         Service Worker should expose redirect mode for navigation loads as manual
115         https://bugs.webkit.org/show_bug.cgi?id=181067
116
117         Reviewed by Alex Christensen.
118
119         * WebProcess/Storage/ServiceWorkerClientFetch.cpp:
120         (WebKit::ServiceWorkerClientFetch::didReceiveResponse):
121
122 2018-01-03  Wenson Hsieh  <wenson_hsieh@apple.com>
123
124         [Attachment Support] Create attachment elements when dropping files on iOS
125         https://bugs.webkit.org/show_bug.cgi?id=181192
126         <rdar://problem/36280945>
127
128         Reviewed by Tim Horton.
129
130         Make some minor adjustments for changes to the pasteboard in WebCore. See WebCore/ChangeLog for more detail.
131         Teaches WebPasteboardProxy et. al. to plumb PasteboardItemInfo from the UI process to the web process via the
132         new `InformationForItemAtIndex` codepath.
133
134         * UIProcess/Cocoa/WebPasteboardProxyCocoa.mm:
135         (WebKit::WebPasteboardProxy::informationForItemAtIndex):
136         (WebKit::WebPasteboardProxy::getFilenamesForDataInteraction): Deleted.
137         * UIProcess/WebPasteboardProxy.h:
138         * UIProcess/WebPasteboardProxy.messages.in:
139         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
140         (WebKit::WebPlatformStrategies::informationForItemAtIndex):
141         (WebKit::WebPlatformStrategies::getFilenamesForDataInteraction): Deleted.
142         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
143
144 2018-01-03  Ting-Wei Lan  <lantw44@gmail.com>
145
146         Replace hard-coded paths in shebangs with #!/usr/bin/env
147         https://bugs.webkit.org/show_bug.cgi?id=181040
148
149         Reviewed by Alex Christensen.
150
151         * Scripts/generate-forwarding-headers.pl:
152
153 2018-01-03  Wenson Hsieh  <wenson_hsieh@apple.com>
154
155         [Attachment Support] Add plumbing for starting a drag with promised blob data
156         https://bugs.webkit.org/show_bug.cgi?id=181201
157
158         Reviewed by Tim Horton.
159
160         Add boilerplate plumbing for PrepareToDragPromisedBlob, which delivers blob promises to the UI process when
161         dragging, respectively.
162
163         * Scripts/webkit/messages.py:
164         (headers_for_type):
165         * Shared/WebCoreArgumentCoders.cpp:
166         (IPC::encodeTypesAndData):
167         (IPC::decodeTypesAndData):
168         (IPC::ArgumentCoder<PasteboardWebContent>::encode):
169         (IPC::ArgumentCoder<PasteboardWebContent>::decode):
170         (IPC::ArgumentCoder<PasteboardImage>::encode):
171         (IPC::ArgumentCoder<PasteboardImage>::decode):
172         (IPC::ArgumentCoder<PromisedBlobInfo>::encode):
173         (IPC::ArgumentCoder<PromisedBlobInfo>::decode):
174
175         Add IPC support PromisedBlobInfo's additionalTypes and additionalData.
176
177         (IPC::encodeClientTypesAndData): Deleted.
178         (IPC::decodeClientTypesAndData): Deleted.
179
180         Rename these helper functions and move them to the top of the file.
181
182         * UIProcess/Cocoa/WebViewImpl.h:
183         * UIProcess/Cocoa/WebViewImpl.mm:
184         (WebKit::WebViewImpl::prepareToDragPromisedBlob):
185         * UIProcess/PageClient.h:
186         (WebKit::PageClient::prepareToDragPromisedBlob):
187         * UIProcess/WebPageProxy.cpp:
188         (WebKit::WebPageProxy::prepareToDragPromisedBlob):
189         * UIProcess/WebPageProxy.h:
190         * UIProcess/WebPageProxy.messages.in:
191         * UIProcess/ios/PageClientImplIOS.h:
192         * UIProcess/ios/PageClientImplIOS.mm:
193         (WebKit::PageClientImpl::prepareToDragPromisedBlob):
194         * UIProcess/ios/WKContentViewInteraction.h:
195         * UIProcess/ios/WKContentViewInteraction.mm:
196         (-[WKContentView _prepareToDragPromisedBlob:]):
197         * UIProcess/mac/PageClientImplMac.h:
198         * UIProcess/mac/PageClientImplMac.mm:
199         (WebKit::PageClientImpl::prepareToDragPromisedBlob):
200         * WebProcess/WebCoreSupport/WebDragClient.cpp:
201         (WebKit::WebDragClient::prepareToDragPromisedBlob):
202         * WebProcess/WebCoreSupport/WebDragClient.h:
203         * WebProcess/WebPage/WebPage.cpp:
204         (WebKit::WebPage::prepareToDragPromisedBlob):
205         * WebProcess/WebPage/WebPage.h:
206
207 2018-01-03  David Kilzer  <ddkilzer@apple.com>
208
209         REGRESSION (r212929): WKSnapshotConfiguration may leak an NSNumber when deallocated
210         <https://webkit.org/b/181274>
211
212         Reviewed by Joseph Pecoraro.
213
214         * UIProcess/API/Cocoa/WKSnapshotConfiguration.mm:
215         (-[WKSnapshotConfiguration dealloc]): Implement method and
216         release _snapshotWidth.
217
218 2018-01-03  John Wilander  <wilander@apple.com>
219
220         Storage Access API: Refactor XPC for access removal to go straight from the web process to the network process
221         https://bugs.webkit.org/show_bug.cgi?id=181270
222         <rdar://problem/36289544>
223
224         Reviewed by Alex Christensen.
225
226         This change refactors how the web process tells the network process
227         to remove storage access. Previously, this was done over the UI process
228         just like requests for storage access. But since no further reasoning
229         is needed, the message should go straight from the web process to the
230         network process for performance reasons and to minimize the risk of a
231         race.
232
233         As a consequence, the XPC code for storage access removal in the UI
234         process is deleted.
235
236         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
237         (WebKit::NetworkConnectionToWebProcess::removeStorageAccess):
238         * NetworkProcess/NetworkConnectionToWebProcess.h:
239         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
240         * NetworkProcess/NetworkProcess.cpp:
241         (WebKit::NetworkProcess::removeStorageAccess): Deleted.
242         * NetworkProcess/NetworkProcess.h:
243         * NetworkProcess/NetworkProcess.messages.in:
244         * UIProcess/Network/NetworkProcessProxy.cpp:
245         (WebKit::NetworkProcessProxy::removeStorageAccess): Deleted.
246         * UIProcess/Network/NetworkProcessProxy.h:
247         * UIProcess/WebPageProxy.cpp:
248         (WebKit::WebPageProxy::requestStorageAccess):
249         (WebKit::WebPageProxy::removeStorageAccess): Deleted.
250         * UIProcess/WebPageProxy.h:
251         * UIProcess/WebPageProxy.messages.in:
252         * UIProcess/WebsiteData/WebsiteDataStore.cpp:
253         (WebKit::WebsiteDataStore::requestStorageAccess):
254         (WebKit::WebsiteDataStore::removeStorageAccess): Deleted.
255         * UIProcess/WebsiteData/WebsiteDataStore.h:
256         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
257         (WebKit::WebFrameLoaderClient::detachedFromParent2):
258         (WebKit::WebFrameLoaderClient::dispatchWillChangeDocument):
259
260 2018-01-03  David Kilzer  <ddkilzer@apple.com>
261
262         com.apple.WebKit.Networking crash in com.apple.Foundation: -[__NSOperationInternal _start:]
263         <https://webkit.org/b/181272>
264         <rdar://problem/35657310>
265
266         Reviewed by Alex Christensen.
267
268         * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
269         (downgradeRequest): Remove unnecessary -autorelease.
270
271 2018-01-03  Brent Fulgham  <bfulgham@apple.com>
272
273         [macOS] Constant frame dropping during Flash video playback
274         https://bugs.webkit.org/show_bug.cgi?id=181249
275         <rdar://problem/34843448>
276
277         Reviewed by Eric Carlson.
278
279         Review of logs during jerky flash video playback shows a few IOKit properties are being blocked by the sandbox,
280         which prevents some high-efficiency codecs from being used. Add 'AppleGVAKeyDoesNotExist', 'IODVDBundleName', and
281         'IOGVA*Encode' to the whitelist.
282
283         * PluginProcess/mac/com.apple.WebKit.plugin-common.sb.in:
284
285 2018-01-03  Michael Catanzaro  <mcatanzaro@igalia.com>
286
287         [GTK] Add web process API to detect when form is submitted via JavaScript
288         https://bugs.webkit.org/show_bug.cgi?id=173915
289
290         Reviewed by Carlos Garcia Campos.
291
292         Epiphany relies on the DOM submit event to detect when a form has been submitted. However,
293         for historical reasons, the submit event is not emitted when a form is submitted by
294         JavaScript. It is therefore not currently possible for a web browser to reliably detect form
295         submission and not possible to implement a robust password storage feature. In order to
296         avoid this problem, this patch adds a new WebKitWebPage signal, will-submit-form, that
297         browsers can use in preference to a DOM event listener.
298
299         Unfortunately, this signal is not available for WPE because it depends on the DOM API.
300
301         There are two submission events, WEBKIT_FORM_SUBMISSION_WILL_SEND_DOM_EVENT and
302         WEBKIT_FORM_SUBMISSION_WILL_COMPLETE. WEBKIT_FORM_SUBMISSION_WILL_SEND_DOM_EVENT
303         occurs earlier than WEBKIT_FORM_SUBMISSION_WILL_COMPLETE and can be used to retrieve form
304         values before websites receive the DOM submit event. This is useful as some websites like
305         to delete form values right before a submit would normally happen in order to attempt to
306         defeat browser password managers. There are two tricks to note: JavaScript can cancel form
307         submission immediately after this event occurs (by returning false in an onsubmit handler),
308         and, for historical reasons, this event will not occur at all when form submission is
309         triggered by JavaScript. WEBKIT_FORM_SUBMISSION_WILL_COMPLETE occurs next, and is more
310         straightforward: it is always emitted when a form is about to be submitted, when it is too
311         late to cancel.
312
313         The recommended way to reliably retrieve password form values would be to watch for both
314         events, use the form value detected in WEBKIT_FORM_SUBMISSION_WILL_SEND_DOM_EVENT
315         if that event is emitted, and use the value detected later in
316         WEBKIT_FORM_SUBMISSION_WILL_COMPLETE otherwise.
317
318         Since one of the signal arguments is an enum, we now have to run glib-mkenums for the web
319         process API. And that has resulted in this patch also adding GType goo for
320         WebKitConsoleMessageLevel and WebKitConsoleMessageSource that was previously missing. Any
321         applications that for some unlikely reason want to use these enums in properties or signals
322         will be happy.
323
324         * PlatformGTK.cmake:
325         * UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt:
326         * WebProcess/InjectedBundle/API/glib/WebKitWebPage.cpp:
327         (webkit_web_page_class_init):
328         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.h:
329         * WebProcess/InjectedBundle/API/gtk/WebKitWebProcessEnumTypes.cpp.template: Added.
330         * WebProcess/InjectedBundle/API/gtk/WebKitWebProcessEnumTypes.h.template: Added.
331
332 2018-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
333
334         Unreviewed. Really fix plugin process after r226327.
335
336         * PluginProcess/unix/PluginProcessMainUnix.cpp:
337
338 2018-01-02  Brent Fulgham  <bfulgham@apple.com>
339
340         [macOS, iOS] Adopt new secure coding APIs in WebKit
341         https://bugs.webkit.org/show_bug.cgi?id=181085
342         <rdar://problem/34837397>
343
344         Reviewed by Tim Horton.
345
346         Update WebKit code to use NSSecureCoding when the underlying operating system supports it. Use new
347         wrapper functions so the same code can be built on all supported OS releases, while enabling
348         seure coding when possible.
349
350         Note that NSView-based classes cannot be migrated at present due to AppKit not supporting NSSecureCoding
351         in its class hierarchy.
352
353         Tested by exising TestWebKitAPI tests for Coding and data transfer.
354
355         * Platform/ios/AccessibilityIOS.mm:
356         (WebKit::newAccessibilityRemoteToken): Encode using NSSecureCoding.
357         * UIProcess/API/Cocoa/WKPreferences.h:
358         * UIProcess/API/Cocoa/WKPreferences.mm:
359         (+[WKPreferences supportsSecureCoding]): Added to enable NSSecureCoding.
360         * UIProcess/API/Cocoa/WKProcessPool.h:
361         * UIProcess/API/Cocoa/WKProcessPool.mm:
362         (+[WKProcessPool supportsSecureCoding]): Ditto.
363         * UIProcess/API/Cocoa/WKUserContentController.h:
364         * UIProcess/API/Cocoa/WKUserContentController.mm:
365         (+[WKUserContentController supportsSecureCoding]): Ditto.
366         * UIProcess/API/Cocoa/WKWebView.mm:
367         (-[WKWebView initWithCoder:]): Use coding initialization that supports secure coding if
368         it is available in the supplied class.
369         * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
370         * UIProcess/API/Cocoa/WKWebViewConfiguration.mm:
371         (+[WKWebViewConfiguration supportsSecureCoding]): Added to enable NSSecureCoding.
372         (-[WKWebViewConfiguration initWithCoder:]): Use secure coding when possible.
373         * UIProcess/API/Cocoa/WKWebsiteDataStore.h:
374         * UIProcess/API/Cocoa/WKWebsiteDataStore.mm:
375         (+[WKWebsiteDataStore supportsSecureCoding]): Added to enable NSSecureCoding.
376         * UIProcess/API/Cocoa/_WKApplicationManifest.h:
377         * UIProcess/API/Cocoa/_WKApplicationManifest.mm:
378         (+[_WKApplicationManifest supportsSecureCoding]): Added to enable NSSecureCoding.
379         (-[_WKApplicationManifest initWithCoder:]): Use secure coding when possible.
380
381 2017-12-28  Yusuke Suzuki  <utatane.tea@gmail.com>
382
383         Remove std::chrono completely
384         https://bugs.webkit.org/show_bug.cgi?id=181186
385
386         Reviewed by Alex Christensen.
387
388         Use MonotonicTime, WallTime, and Seconds instead.
389         Changes are mechanical ones.
390
391         * NetworkProcess/NetworkProcess.cpp:
392         (WebKit::NetworkProcess::deleteWebsiteData):
393         * NetworkProcess/NetworkProcess.h:
394         * NetworkProcess/NetworkProcess.messages.in:
395         * NetworkProcess/cache/CacheStorageEngineCaches.cpp:
396         (WebKit::CacheStorage::Caches::clear):
397         * NetworkProcess/cache/NetworkCache.cpp:
398         (WebKit::NetworkCache::responseHasExpired):
399         (WebKit::NetworkCache::responseNeedsRevalidation):
400         (WebKit::NetworkCache::makeStoreDecision):
401         (WebKit::NetworkCache::Cache::clear):
402         (WebKit::NetworkCache::Cache::storeData):
403         * NetworkProcess/cache/NetworkCache.h:
404         * NetworkProcess/cache/NetworkCacheEntry.cpp:
405         (WebKit::NetworkCache::Entry::Entry):
406         (WebKit::NetworkCache::Entry::asJSON const):
407         * NetworkProcess/cache/NetworkCacheEntry.h:
408         (WebKit::NetworkCache::Entry::timeStamp const):
409         * NetworkProcess/cache/NetworkCacheFileSystem.cpp:
410         (WebKit::NetworkCache::fileTimes):
411         (WebKit::NetworkCache::updateFileModificationTimeIfNeeded):
412         * NetworkProcess/cache/NetworkCacheFileSystem.h:
413         * NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:
414         (WebKit::NetworkCache::IOChannel::IOChannel):
415         * NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:
416         (WebKit::NetworkCache::responseNeedsRevalidation):
417         (WebKit::NetworkCache::canRevalidate):
418         * NetworkProcess/cache/NetworkCacheStorage.cpp:
419         (WebKit::NetworkCache::Storage::readRecord):
420         (WebKit::NetworkCache::Storage::clear):
421         (WebKit::NetworkCache::computeRecordWorth):
422         * NetworkProcess/cache/NetworkCacheStorage.h:
423         Bump the cache version. We now change the data in persistent cache.
424         * NetworkProcess/cache/NetworkCacheSubresourcesEntry.cpp:
425         (WebKit::NetworkCache::SubresourceInfo::SubresourceInfo):
426         (WebKit::NetworkCache::SubresourcesEntry::SubresourcesEntry):
427         * NetworkProcess/cache/NetworkCacheSubresourcesEntry.h:
428         (WebKit::NetworkCache::SubresourceInfo::lastSeen const):
429         (WebKit::NetworkCache::SubresourceInfo::firstSeen const):
430         (WebKit::NetworkCache::SubresourcesEntry::timeStamp const):
431         * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
432         (WebKit::NetworkProcess::clearHSTSCache):
433         (WebKit::clearNSURLCache):
434         (WebKit::NetworkProcess::clearDiskCache):
435         * NetworkProcess/curl/NetworkProcessCurl.cpp:
436         (WebKit::NetworkProcess::clearDiskCache):
437         * NetworkProcess/mac/NetworkProcessMac.mm:
438         (WebKit::NetworkProcess::clearCacheForAllOrigins):
439         * NetworkProcess/soup/NetworkProcessSoup.cpp:
440         (WebKit::NetworkProcess::clearCacheForAllOrigins):
441         (WebKit::NetworkProcess::clearDiskCache):
442         * Platform/IPC/ArgumentCoders.cpp:
443         (IPC::ArgumentCoder<WallTime>::encode):
444         (IPC::ArgumentCoder<WallTime>::decode):
445         (IPC::ArgumentCoder<std::chrono::system_clock::time_point>::encode): Deleted.
446         (IPC::ArgumentCoder<std::chrono::system_clock::time_point>::decode): Deleted.
447         * Platform/IPC/ArgumentCoders.h:
448         * PluginProcess/PluginProcess.cpp:
449         (WebKit::PluginProcess::deleteWebsiteData):
450         * PluginProcess/PluginProcess.h:
451         * PluginProcess/PluginProcess.messages.in:
452         * Scripts/webkit/messages.py:
453         (headers_for_type):
454         * Shared/RemoteLayerTree/RemoteLayerBackingStore.h:
455         (WebKit::RemoteLayerBackingStore::lastDisplayTime const):
456         * Shared/RemoteLayerTree/RemoteLayerBackingStore.mm:
457         (WebKit::RemoteLayerBackingStore::RemoteLayerBackingStore):
458         (WebKit::RemoteLayerBackingStore::display):
459         * Shared/RemoteLayerTree/RemoteLayerBackingStoreCollection.h:
460         * Shared/RemoteLayerTree/RemoteLayerBackingStoreCollection.mm:
461         (WebKit::RemoteLayerBackingStoreCollection::markBackingStoreVolatile):
462         (WebKit::RemoteLayerBackingStoreCollection::volatilityTimerFired):
463         * Shared/WebCoreArgumentCoders.cpp:
464         (IPC::ArgumentCoder<RecentSearch>::decode):
465         (IPC::ArgumentCoder<WallTime>::encode): Deleted.
466         (IPC::ArgumentCoder<WallTime>::decode): Deleted.
467         * Shared/WebCoreArgumentCoders.h:
468         * StorageProcess/StorageProcess.cpp:
469         (WebKit::StorageProcess::deleteWebsiteData):
470         * StorageProcess/StorageProcess.h:
471         * StorageProcess/StorageProcess.messages.in:
472         * UIProcess/API/C/WKApplicationCacheManager.cpp:
473         (WKApplicationCacheManagerDeleteAllEntries):
474         * UIProcess/API/C/WKCookieManager.cpp:
475         (WKCookieManagerDeleteAllCookiesModifiedAfterDate):
476         * UIProcess/API/C/WKKeyValueStorageManager.cpp:
477         (WKKeyValueStorageManagerDeleteAllEntries):
478         * UIProcess/API/C/WKResourceCacheManager.cpp:
479         (WKResourceCacheManagerClearCacheForAllOrigins):
480         * UIProcess/API/C/WKWebsiteDataStoreRef.cpp:
481         (WKWebsiteDataStoreStatisticsClearInMemoryAndPersistentStoreModifiedSinceHours):
482         (WKWebsiteDataStoreStatisticsClearThroughWebsiteDataRemoval):
483         (WKWebsiteDataStoreRemoveAllFetchCaches):
484         (WKWebsiteDataStoreRemoveAllIndexedDatabases):
485         (WKWebsiteDataStoreRemoveAllServiceWorkerRegistrations):
486         * UIProcess/API/Cocoa/WKWebsiteDataStore.mm:
487         (toSystemClockTime):
488         (-[WKWebsiteDataStore _resourceLoadStatisticsClearInMemoryAndPersistentStoreModifiedSinceHours:]):
489         * UIProcess/API/glib/WebKitWebContext.cpp:
490         (webkit_web_context_clear_cache):
491         * UIProcess/API/glib/WebKitWebsiteDataManager.cpp:
492         (webkit_website_data_manager_clear):
493         * UIProcess/DrawingAreaProxy.h:
494         * UIProcess/Network/NetworkProcessProxy.cpp:
495         (WebKit::NetworkProcessProxy::deleteWebsiteData):
496         * UIProcess/Network/NetworkProcessProxy.h:
497         * UIProcess/Plugins/PluginProcessManager.cpp:
498         (WebKit::PluginProcessManager::deleteWebsiteData):
499         * UIProcess/Plugins/PluginProcessManager.h:
500         * UIProcess/Plugins/PluginProcessProxy.cpp:
501         (WebKit::PluginProcessProxy::deleteWebsiteData):
502         * UIProcess/Plugins/PluginProcessProxy.h:
503         * UIProcess/Storage/StorageProcessProxy.cpp:
504         (WebKit::StorageProcessProxy::deleteWebsiteData):
505         * UIProcess/Storage/StorageProcessProxy.h:
506         * UIProcess/WebCookieManagerProxy.cpp:
507         (WebKit::WebCookieManagerProxy::deleteAllCookiesModifiedSince):
508         * UIProcess/WebCookieManagerProxy.h:
509         * UIProcess/WebProcessProxy.cpp:
510         (WebKit::WebProcessProxy::deleteWebsiteData):
511         * UIProcess/WebProcessProxy.h:
512         * UIProcess/WebResourceLoadStatisticsStore.cpp:
513         (WebKit::WebResourceLoadStatisticsStore::scheduleClearInMemoryAndPersistent):
514         * UIProcess/WebResourceLoadStatisticsStore.h:
515         * UIProcess/WebStorage/LocalStorageDatabaseTracker.cpp:
516         (WebKit::LocalStorageDatabaseTracker::deleteDatabasesModifiedSince):
517         * UIProcess/WebStorage/LocalStorageDatabaseTracker.h:
518         * UIProcess/WebStorage/StorageManager.cpp:
519         (WebKit::StorageManager::deleteLocalStorageOriginsModifiedSince):
520         * UIProcess/WebStorage/StorageManager.h:
521         * UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:
522         (WebKit::WebsiteDataStore::platformRemoveRecentSearches):
523         * UIProcess/WebsiteData/WebsiteDataStore.cpp:
524         (WebKit::WebsiteDataStore::removeData):
525         (WebKit::WebsiteDataStore::removeMediaKeys):
526         * UIProcess/WebsiteData/WebsiteDataStore.h:
527         * UIProcess/gtk/WebPageProxyGtk.cpp:
528         (WebKit::WebsiteDataStore::platformRemoveRecentSearches):
529         * UIProcess/wpe/WebPageProxyWPE.cpp:
530         (WebKit::WebsiteDataStore::platformRemoveRecentSearches):
531         * WebProcess/Cookies/WebCookieManager.cpp:
532         (WebKit::WebCookieManager::deleteAllCookiesModifiedSince):
533         * WebProcess/Cookies/WebCookieManager.h:
534         * WebProcess/Cookies/WebCookieManager.messages.in:
535         * WebProcess/Plugins/PluginView.cpp:
536         (WebKit::lastModifiedDateMS):
537         * WebProcess/WebProcess.cpp:
538         (WebKit::WebProcess::deleteWebsiteData):
539         * WebProcess/WebProcess.h:
540         * WebProcess/WebProcess.messages.in:
541
542 2018-01-02  Wenson Hsieh  <wenson_hsieh@apple.com>
543
544         [Attachment Support] Introduce data structures and IPC support for writing promised blobs
545         https://bugs.webkit.org/show_bug.cgi?id=181189
546
547         Reviewed by Tim Horton.
548
549         Add IPC support for PromisedBlobInfo and PromisedBlobData. See WebCore/ChangeLog for more detail.
550
551         * Shared/WebCoreArgumentCoders.cpp:
552         (IPC::ArgumentCoder<PromisedBlobData>::encode):
553         (IPC::ArgumentCoder<PromisedBlobData>::decode):
554         (IPC::ArgumentCoder<PromisedBlobInfo>::encode):
555         (IPC::ArgumentCoder<PromisedBlobInfo>::decode):
556         * Shared/WebCoreArgumentCoders.h:
557
558 2018-01-02  Michael Catanzaro  <mcatanzaro@igalia.com>
559
560         REGRESSION(r223253): Broke ResourceLoadStatistics layout tests for non-Cocoa ports
561         https://bugs.webkit.org/show_bug.cgi?id=181231
562
563         Reviewed by Alex Christensen.
564
565         Add new C API for use by WebKitTestRunner.
566
567         * UIProcess/API/C/WKWebsiteDataStoreRef.cpp:
568         (WKWebsiteDataStoreIsStatisticsRegisteredAsSubFrameUnder):
569         (WKWebsiteDataStoreIsStatisticsRegisteredAsRedirectingTo):
570         * UIProcess/API/C/WKWebsiteDataStoreRef.h:
571
572 2018-01-02  Jiewen Tan  <jiewen_tan@apple.com>
573
574         Add a WebAuthentication runtime feature flag
575         https://bugs.webkit.org/show_bug.cgi?id=181220
576         <rdar://problem/36055305>
577
578         Reviewed by Brent Fulgham.
579
580         Renames the CredentialManagement runtime feature flag into WebAuthentication.
581
582         * Shared/WebPreferences.yaml:
583         * UIProcess/API/C/WKPreferences.cpp:
584         (WKPreferencesSetWebAuthenticationEnabled):
585         (WKPreferencesGetWebAuthenticationEnabled):
586         (WKPreferencesSetCredentialManagementEnabled): Deleted.
587         (WKPreferencesGetCredentialManagementEnabled): Deleted.
588         * UIProcess/API/C/WKPreferencesRefPrivate.h:
589         * WebProcess/WebPage/WebPage.cpp:
590         (WebKit::WebPage::updatePreferences):
591
592 2018-01-02  Michael Catanzaro  <mcatanzaro@igalia.com>
593
594         REGRESSION(r226327): [GTK] Plugin process is broken
595         https://bugs.webkit.org/show_bug.cgi?id=181187
596
597         Unreviewed, fix PluginProcessMainUnix after r226327.
598
599         * PluginProcess/unix/PluginProcessMainUnix.cpp:
600
601 2018-01-02  Tim Horton  <timothy_horton@apple.com>
602
603         Fix the build on platforms where UICurrentUserInterfaceIdiomIsPad is defined to false
604         https://bugs.webkit.org/show_bug.cgi?id=181218
605
606         Reviewed by Alex Christensen.
607
608         * Platform/spi/ios/UIKitSPI.h:
609         (currentUserInterfaceIdiomIsPad):
610         * UIProcess/ios/SmartMagnificationController.mm:
611         (WebKit::SmartMagnificationController::didCollectGeometryForSmartMagnificationGesture):
612         * UIProcess/ios/WKContentViewInteraction.mm:
613         (-[WKFormInputSession setAccessoryViewCustomButtonTitle:]):
614         (-[WKContentView _requiresKeyboardWhenFirstResponder]):
615         (-[WKContentView _displayFormNodeInputView]):
616         (-[WKContentView requiresAccessoryView]):
617         (-[WKContentView _updateAccessory]):
618         * UIProcess/ios/forms/WKAirPlayRoutePicker.mm:
619         (-[WKAirPlayRoutePicker show:fromRect:]):
620         * UIProcess/ios/forms/WKFileUploadPanel.mm:
621         (-[WKFileUploadPanel _showPhotoPickerWithSourceType:]):
622         (-[WKFileUploadPanel _presentMenuOptionForCurrentInterfaceIdiom:]):
623         * UIProcess/ios/forms/WKFormInputControl.mm:
624         (-[WKDateTimePicker initWithView:datePickerMode:]):
625         (-[WKFormInputControl initWithView:]):
626         * UIProcess/ios/forms/WKFormSelectControl.mm:
627         (-[WKFormSelectControl initWithView:]):
628         On platforms where UICurrentUserInterfaceIdiomIsPad is defined to false,
629         blocks that conditionally execute based on its value are unreachable.
630         This causes the compiler to complain. Hide it away inside an inline function
631         and make use of that everywhere we used to use the macro.
632
633 2018-01-02  Alex Christensen  <achristensen@webkit.org>
634
635         Remove SVN file accidentally added in r226160
636         https://bugs.webkit.org/show_bug.cgi?id=180934
637
638         * UIProcess/WebPageProxy.cpp.orig: Removed.
639
640 2018-01-02  Alex Christensen  <achristensen@webkit.org>
641
642         Use BlockPtrs and lambdas instead of new/delete to pass parameters to blocks in WebViewImpl::performDragOperation
643         https://bugs.webkit.org/show_bug.cgi?id=180795
644
645         Reviewed by Brent Fulgham.
646
647         * UIProcess/Cocoa/WebViewImpl.mm:
648         (WebKit::WebViewImpl::performDragOperation):
649
650 2018-01-02  Michael Catanzaro  <mcatanzaro@igalia.com>
651
652         [WPE][GTK] Implement the assignment of ProcessIdentifiers to child processes
653         https://bugs.webkit.org/show_bug.cgi?id=181187
654
655         Reviewed by Brady Eidson.
656
657         * Shared/ChildProcess.cpp: Make the ProcessIdentifier mandatory.
658         (WebKit::ChildProcess::initialize):
659         * Shared/unix/ChildProcessMain.cpp: Initialize ChildProcessInitializationParameters with the
660         ProcessIdentifier.
661         (WebKit::ChildProcessMainBase::parseCommandLine):
662         * UIProcess/Launcher/glib/ProcessLauncherGLib.cpp: Copy the ProcessIdentifier from
663         LaunchOptions into argv.
664         (WebKit::ProcessLauncher::launchProcess):
665         * WebProcess/wpe/WebProcessMainWPE.cpp: Expect the WPE socket ID later in the command line.
666
667 2018-01-02  Alex Christensen  <achristensen@webkit.org>
668
669         Use new WebsiteDataStore passed in through decidePolicyForNavigation SPI
670         https://bugs.webkit.org/show_bug.cgi?id=180897
671         <rdar://problem/35535328>
672
673         Reviewed by Brent Fulgham.
674
675         * Shared/WebsitePoliciesData.cpp:
676         (WebKit::WebsitePoliciesData::applyToDocumentLoader):
677         * UIProcess/Cocoa/NavigationState.mm:
678         (WebKit::NavigationState::NavigationClient::decidePolicyForNavigationAction):
679         * UIProcess/WebPageProxy.cpp:
680         (WebKit::WebPageProxy::changeWebsiteDataStore):
681         * UIProcess/WebPageProxy.h:
682         * UIProcess/WebProcessPool.cpp:
683         (WebKit::WebProcessPool::pageBeginUsingWebsiteDataStore):
684         (WebKit::WebProcessPool::pageEndUsingWebsiteDataStore):
685         (WebKit::WebProcessPool::pageAddedToProcess): Deleted.
686         (WebKit::WebProcessPool::pageRemovedFromProcess): Deleted.
687         * UIProcess/WebProcessPool.h:
688         * UIProcess/WebProcessProxy.cpp:
689         (WebKit::WebProcessProxy::addExistingWebPage):
690         (WebKit::WebProcessProxy::removeWebPage):
691         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
692         (WebKit::WebFrameNetworkingContext::ensureWebsiteDataStoreSession):
693
694 2018-01-02  Alex Christensen  <achristensen@webkit.org>
695
696         Only use CookieStorageShim when we aren't using NetworkSession
697         https://bugs.webkit.org/show_bug.cgi?id=180766
698
699         Reviewed by Brent Fulgham.
700
701         * Shared/mac/CookieStorageShim.h:
702         * Shared/mac/CookieStorageShim.mm:
703         * WebProcess/WebProcess.cpp:
704         (WebKit::WebProcess::initializeWebProcess):
705
706 2018-01-02  Alex Christensen  <achristensen@webkit.org>
707
708         Clean up context menu code
709         https://bugs.webkit.org/show_bug.cgi?id=181074
710
711         Reviewed by Brent Fulgham.
712
713         Use Ref instead of RefPtr where possible.
714         Use move semantics instead of copying from const references when possible.
715         Remove dead iOS code.  Reduce allocations.  Add stub for WPE.
716
717         * UIProcess/API/APIContextMenuClient.h:
718         (API::ContextMenuClient::getContextMenuFromProposedMenu):
719         (API::ContextMenuClient::getContextMenuFromProposedMenuAsync):
720         (API::ContextMenuClient::showContextMenu):
721         * UIProcess/API/C/WKPage.cpp:
722         (WKPageSetPageContextMenuClient):
723         * UIProcess/API/gtk/PageClientImpl.cpp:
724         (WebKit::PageClientImpl::createContextMenuProxy):
725         * UIProcess/API/gtk/PageClientImpl.h:
726         * UIProcess/PageClient.h:
727         * UIProcess/WebContextMenuListenerProxy.cpp:
728         (WebKit::WebContextMenuListenerProxy::useContextMenuItems):
729         * UIProcess/WebContextMenuProxy.cpp:
730         (WebKit::WebContextMenuProxy::WebContextMenuProxy):
731         * UIProcess/WebContextMenuProxy.h:
732         * UIProcess/WebPageProxy.cpp:
733         (WebKit::WebPageProxy::showContextMenu):
734         (WebKit::WebPageProxy::internalShowContextMenu): Deleted.
735         * UIProcess/WebPageProxy.h:
736         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
737         (WebKit::WebContextMenuProxyGtk::showContextMenuWithItems):
738         (WebKit::WebContextMenuProxyGtk::WebContextMenuProxyGtk):
739         * UIProcess/gtk/WebContextMenuProxyGtk.h:
740         (WebKit::WebContextMenuProxyGtk::create):
741         * UIProcess/ios/PageClientImplIOS.h:
742         * UIProcess/ios/PageClientImplIOS.mm:
743         (WebKit::PageClientImpl::createContextMenuProxy): Deleted.
744         * UIProcess/mac/PageClientImplMac.h:
745         * UIProcess/mac/PageClientImplMac.mm:
746         (WebKit::PageClientImpl::createContextMenuProxy):
747         * UIProcess/mac/WebContextMenuProxyMac.h:
748         (WebKit::WebContextMenuProxyMac::create):
749         * UIProcess/mac/WebContextMenuProxyMac.mm:
750         (WebKit::WebContextMenuProxyMac::WebContextMenuProxyMac):
751         (WebKit::WebContextMenuProxyMac::showContextMenuWithItems):
752         (WebKit::WebContextMenuProxyMac::showContextMenu):
753
754 == Rolled over to ChangeLog-2018-01-01 ==