1/*
2 * Copyright (C) 2010-2018 Apple Inc. All rights reserved.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the
11 * documentation and/or other materials provided with the distribution.
12 *
13 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
14 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
15 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
16 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
17 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
18 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
19 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
20 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
21 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
23 * THE POSSIBILITY OF SUCH DAMAGE.
24 */
25
26#pragma once
27
28#include "AuxiliaryProcess.h"
29#include "CacheModel.h"
30#if ENABLE(MEDIA_STREAM)
31#include "MediaDeviceSandboxExtensions.h"
32#endif
33#include "PluginProcessConnectionManager.h"
34#include "ResourceCachesToClear.h"
35#include "SandboxExtension.h"
36#include "TextCheckerState.h"
37#include "ViewUpdateDispatcher.h"
38#include "WebInspectorInterruptDispatcher.h"
39#include "WebProcessCreationParameters.h"
40#include "WebSQLiteDatabaseTracker.h"
41#include "WebSocketChannelManager.h"
42#include <WebCore/ActivityState.h>
43#include <WebCore/PageIdentifier.h>
44#include <WebCore/RegistrableDomain.h>
45#if PLATFORM(MAC)
46#include <WebCore/ScreenProperties.h>
47#endif
48#include <WebCore/Timer.h>
49#include <pal/HysteresisActivity.h>
50#include <pal/SessionID.h>
51#include <wtf/Forward.h>
52#include <wtf/HashMap.h>
53#include <wtf/HashSet.h>
54#include <wtf/RefCounter.h>
55#include <wtf/text/AtomString.h>
56#include <wtf/text/AtomStringHash.h>
57
58#if PLATFORM(COCOA)
59#include <dispatch/dispatch.h>
60#include <wtf/MachSendRight.h>
61#endif
62
63#if PLATFORM(IOS_FAMILY)
64#include "ProcessTaskStateObserver.h"
65#endif
66
67#if PLATFORM(WAYLAND) && USE(WPE_RENDERER)
68#include <WebCore/PlatformDisplayLibWPE.h>
69#endif
70
71namespace API {
72class Object;
73}
74
75namespace PAL {
76class SessionID;
77}
78
79namespace WebCore {
80class ApplicationCacheStorage;
81class CPUMonitor;
82class CertificateInfo;
83class PageGroup;
84class ResourceRequest;
85class UserGestureToken;
86struct MessagePortIdentifier;
87struct MessageWithMessagePorts;
88struct MockMediaDevice;
89struct PluginInfo;
90struct PrewarmInformation;
91struct SecurityOriginData;
92
93#if ENABLE(SERVICE_WORKER)
94struct ServiceWorkerContextData;
95#endif
96}
97
98namespace WebKit {
99
100class EventDispatcher;
101class GamepadData;
102class InjectedBundle;
103class LibWebRTCNetwork;
104class NetworkProcessConnection;
105class ObjCObjectGraph;
106class StorageAreaMap;
107class UserData;
108class WaylandCompositorDisplay;
109class WebAutomationSessionProxy;
110class WebCacheStorageProvider;
111class WebConnectionToUIProcess;
112class WebFrame;
113class WebLoaderStrategy;
114class WebPage;
115class WebPageGroupProxy;
116struct WebProcessCreationParameters;
117struct WebProcessDataStoreParameters;
118class WebProcessSupplement;
119enum class WebsiteDataType;
120struct WebPageCreationParameters;
121struct WebPageGroupData;
122struct WebPreferencesStore;
123struct WebsiteData;
124struct WebsiteDataStoreParameters;
125
126#if PLATFORM(IOS_FAMILY)
127class LayerHostingContext;
128#endif
129
130class WebProcess
131 : public AuxiliaryProcess
132#if PLATFORM(IOS_FAMILY)
133 , ProcessTaskStateObserver::Client
134#endif
135{
136public:
137 static WebProcess& singleton();
138 static constexpr ProcessType processType = ProcessType::WebContent;
139
140 template <typename T>
141 T* supplement()
142 {
143 return static_cast<T*>(m_supplements.get(T::supplementName()));
144 }
145
146 template <typename T>
147 void addSupplement()
148 {
149 m_supplements.add(T::supplementName(), std::make_unique<T>(*this));
150 }
151
152 WebConnectionToUIProcess* webConnectionToUIProcess() const { return m_webConnection.get(); }
153
154 WebPage* webPage(WebCore::PageIdentifier) const;
155 void createWebPage(WebCore::PageIdentifier, WebPageCreationParameters&&);
156 void removeWebPage(PAL::SessionID, WebCore::PageIdentifier);
157 WebPage* focusedWebPage() const;
158
159 InjectedBundle* injectedBundle() const { return m_injectedBundle.get(); }
160
161#if PLATFORM(COCOA)
162 const WTF::MachSendRight& compositingRenderServerPort() const { return m_compositingRenderServerPort; }
163#endif
164
165 bool shouldPlugInAutoStartFromOrigin(WebPage&, const String& pageOrigin, const String& pluginOrigin, const String& mimeType);
166 void plugInDidStartFromOrigin(const String& pageOrigin, const String& pluginOrigin, const String& mimeType, PAL::SessionID);
167 void plugInDidReceiveUserInteraction(const String& pageOrigin, const String& pluginOrigin, const String& mimeType, PAL::SessionID);
168 void setPluginLoadClientPolicy(uint8_t policy, const String& host, const String& bundleIdentifier, const String& versionString);
169 void resetPluginLoadClientPolicies(const HashMap<String, HashMap<String, HashMap<String, uint8_t>>>&);
170 void clearPluginClientPolicies();
171 void refreshPlugins();
172
173 bool fullKeyboardAccessEnabled() const { return m_fullKeyboardAccessEnabled; }
174
175 WebFrame* webFrame(uint64_t) const;
176 void addWebFrame(uint64_t, WebFrame*);
177 void removeWebFrame(uint64_t);
178
179 WebPageGroupProxy* webPageGroup(WebCore::PageGroup*);
180 WebPageGroupProxy* webPageGroup(uint64_t pageGroupID);
181 WebPageGroupProxy* webPageGroup(const WebPageGroupData&);
182
183 uint64_t userGestureTokenIdentifier(RefPtr<WebCore::UserGestureToken>);
184 void userGestureTokenDestroyed(WebCore::UserGestureToken&);
185
186 const TextCheckerState& textCheckerState() const { return m_textCheckerState; }
187 void setTextCheckerState(const TextCheckerState&);
188
189 void clearResourceCaches(ResourceCachesToClear = AllResourceCaches);
190
191#if ENABLE(NETSCAPE_PLUGIN_API)
192 PluginProcessConnectionManager& pluginProcessConnectionManager();
193#endif
194
195 EventDispatcher& eventDispatcher() { return m_eventDispatcher.get(); }
196
197 NetworkProcessConnection& ensureNetworkProcessConnection();
198 void networkProcessConnectionClosed(NetworkProcessConnection*);
199 NetworkProcessConnection* existingNetworkProcessConnection() { return m_networkProcessConnection.get(); }
200 WebLoaderStrategy& webLoaderStrategy();
201
202 LibWebRTCNetwork& libWebRTCNetwork();
203
204 void setCacheModel(CacheModel);
205
206 void ensureLegacyPrivateBrowsingSessionInNetworkProcess();
207
208 void pageDidEnterWindow(WebCore::PageIdentifier);
209 void pageWillLeaveWindow(WebCore::PageIdentifier);
210
211 void nonVisibleProcessCleanupTimerFired();
212
213 void registerStorageAreaMap(StorageAreaMap&);
214 void unregisterStorageAreaMap(StorageAreaMap&);
215 StorageAreaMap* storageAreaMap(uint64_t identifier) const;
216
217 void enablePrivateBrowsingForTesting(bool);
218
219#if PLATFORM(COCOA)
220 RetainPtr<CFDataRef> sourceApplicationAuditData() const;
221 void destroyRenderingResources();
222#endif
223
224 const String& uiProcessBundleIdentifier() const { return m_uiProcessBundleIdentifier; }
225
226 void updateActivePages();
227 void getActivePagesOriginsForTesting(CompletionHandler<void(Vector<String>&&)>&&);
228 void pageActivityStateDidChange(WebCore::PageIdentifier, OptionSet<WebCore::ActivityState::Flag> changed);
229
230 void setHiddenPageDOMTimerThrottlingIncreaseLimit(int milliseconds);
231
232 void processWillSuspendImminently();
233 void prepareToSuspend();
234 void cancelPrepareToSuspend();
235 void processDidResume();
236
237 void sendPrewarmInformation(const URL&);
238
239 void isJITEnabled(CompletionHandler<void(bool)>&&);
240
241#if PLATFORM(IOS_FAMILY)
242 void resetAllGeolocationPermissions();
243#endif
244
245#if PLATFORM(WAYLAND)
246 WaylandCompositorDisplay* waylandCompositorDisplay() const { return m_waylandCompositorDisplay.get(); }
247#endif
248
249 RefPtr<API::Object> transformHandlesToObjects(API::Object*);
250 static RefPtr<API::Object> transformObjectsToHandles(API::Object*);
251
252#if PLATFORM(COCOA)
253 RefPtr<ObjCObjectGraph> transformHandlesToObjects(ObjCObjectGraph&);
254 static RefPtr<ObjCObjectGraph> transformObjectsToHandles(ObjCObjectGraph&);
255#endif
256
257#if ENABLE(SERVICE_CONTROLS)
258 bool hasImageServices() const { return m_hasImageServices; }
259 bool hasSelectionServices() const { return m_hasSelectionServices; }
260 bool hasRichContentServices() const { return m_hasRichContentServices; }
261#endif
262
263 WebCore::ApplicationCacheStorage& applicationCacheStorage() { return *m_applicationCacheStorage; }
264
265 void prefetchDNS(const String&);
266
267 WebAutomationSessionProxy* automationSessionProxy() { return m_automationSessionProxy.get(); }
268
269 WebCacheStorageProvider& cacheStorageProvider() { return m_cacheStorageProvider.get(); }
270 WebSocketChannelManager& webSocketChannelManager() { return m_webSocketChannelManager; }
271
272#if PLATFORM(IOS_FAMILY)
273 void accessibilityProcessSuspendedNotification(bool);
274
275 void unblockAccessibilityServer(const SandboxExtension::Handle&);
276#endif
277
278#if PLATFORM(IOS)
279 float backlightLevel() const { return m_backlightLevel; }
280#endif
281
282#if PLATFORM(COCOA)
283 void setMediaMIMETypes(const Vector<String>);
284#endif
285
286 bool areAllPagesThrottleable() const;
287
288private:
289 WebProcess();
290 ~WebProcess();
291
292 void initializeWebProcess(WebProcessCreationParameters&&);
293 void platformInitializeWebProcess(WebProcessCreationParameters&);
294 void setWebsiteDataStoreParameters(WebProcessDataStoreParameters&&);
295 void platformSetWebsiteDataStoreParameters(WebProcessDataStoreParameters&&);
296
297 void prewarmGlobally();
298 void prewarmWithDomainInformation(const WebCore::PrewarmInformation&);
299
300#if USE(OS_STATE)
301 void registerWithStateDumper();
302#endif
303
304 void markAllLayersVolatile(WTF::Function<void(bool)>&& completionHandler);
305 void cancelMarkAllLayersVolatile();
306
307 void freezeAllLayerTrees();
308 void unfreezeAllLayerTrees();
309
310 void processSuspensionCleanupTimerFired();
311
312 void platformTerminate();
313
314 void setHasSuspendedPageProxy(bool);
315 void setIsInProcessCache(bool);
316 void markIsNoLongerPrewarmed();
317
318 void registerURLSchemeAsEmptyDocument(const String&);
319 void registerURLSchemeAsSecure(const String&) const;
320 void registerURLSchemeAsBypassingContentSecurityPolicy(const String&) const;
321 void setDomainRelaxationForbiddenForURLScheme(const String&) const;
322 void registerURLSchemeAsLocal(const String&) const;
323 void registerURLSchemeAsNoAccess(const String&) const;
324 void registerURLSchemeAsDisplayIsolated(const String&) const;
325 void registerURLSchemeAsCORSEnabled(const String&) const;
326 void registerURLSchemeAsAlwaysRevalidated(const String&) const;
327 void registerURLSchemeAsCachePartitioned(const String&) const;
328 void registerURLSchemeAsCanDisplayOnlyIfCanRequest(const String&) const;
329
330 void setDefaultRequestTimeoutInterval(double);
331 void setAlwaysUsesComplexTextCodePath(bool);
332 void setShouldUseFontSmoothing(bool);
333 void setResourceLoadStatisticsEnabled(bool);
334 void clearResourceLoadStatistics();
335 void userPreferredLanguagesChanged(const Vector<String>&) const;
336 void fullKeyboardAccessModeChanged(bool fullKeyboardAccessEnabled);
337
338 bool isPlugInAutoStartOriginHash(unsigned plugInOriginHash, PAL::SessionID);
339 void didAddPlugInAutoStartOriginHash(unsigned plugInOriginHash, WallTime expirationTime, PAL::SessionID);
340 void resetPlugInAutoStartOriginDefaultHashes(const HashMap<unsigned, WallTime>& hashes);
341 void resetPlugInAutoStartOriginHashes(const HashMap<PAL::SessionID, HashMap<unsigned, WallTime>>& hashes);
342
343 void platformSetCacheModel(CacheModel);
344
345 void setEnhancedAccessibility(bool);
346
347 void startMemorySampler(SandboxExtension::Handle&&, const String&, const double);
348 void stopMemorySampler();
349
350 void getWebCoreStatistics(uint64_t callbackID);
351 void garbageCollectJavaScriptObjects();
352 void setJavaScriptGarbageCollectorTimerEnabled(bool flag);
353
354 void mainThreadPing();
355 void backgroundResponsivenessPing();
356
357 void didTakeAllMessagesForPort(Vector<WebCore::MessageWithMessagePorts>&& messages, uint64_t messageCallbackIdentifier, uint64_t messageBatchIdentifier);
358 void checkProcessLocalPortForActivity(const WebCore::MessagePortIdentifier&, uint64_t callbackIdentifier);
359 void didCheckRemotePortForActivity(uint64_t callbackIdentifier, bool hasActivity);
360 void messagesAvailableForPort(const WebCore::MessagePortIdentifier&);
361
362#if ENABLE(GAMEPAD)
363 void setInitialGamepads(const Vector<GamepadData>&);
364 void gamepadConnected(const GamepadData&);
365 void gamepadDisconnected(unsigned index);
366#endif
367
368#if ENABLE(SERVICE_WORKER)
369 void establishWorkerContextConnectionToNetworkProcess(uint64_t pageGroupID, WebCore::PageIdentifier, const WebPreferencesStore&, PAL::SessionID);
370 void registerServiceWorkerClients();
371#endif
372
373 void releasePageCache();
374
375 void fetchWebsiteData(PAL::SessionID, OptionSet<WebsiteDataType>, CompletionHandler<void(WebsiteData&&)>&&);
376 void deleteWebsiteData(PAL::SessionID, OptionSet<WebsiteDataType>, WallTime modifiedSince, CompletionHandler<void()>&&);
377 void deleteWebsiteDataForOrigins(PAL::SessionID, OptionSet<WebsiteDataType>, const Vector<WebCore::SecurityOriginData>& origins, CompletionHandler<void()>&&);
378
379 void setMemoryCacheDisabled(bool);
380
381#if ENABLE(SERVICE_CONTROLS)
382 void setEnabledServices(bool hasImageServices, bool hasSelectionServices, bool hasRichContentServices);
383#endif
384
385 void handleInjectedBundleMessage(const String& messageName, const UserData& messageBody);
386 void setInjectedBundleParameter(const String& key, const IPC::DataReference&);
387 void setInjectedBundleParameters(const IPC::DataReference&);
388
389 enum class ShouldAcknowledgeWhenReadyToSuspend { No, Yes };
390 void actualPrepareToSuspend(ShouldAcknowledgeWhenReadyToSuspend);
391
392 bool hasPageRequiringPageCacheWhileSuspended() const;
393 bool areAllPagesSuspended() const;
394
395 void ensureAutomationSessionProxy(const String& sessionIdentifier);
396 void destroyAutomationSessionProxy();
397
398 void logDiagnosticMessageForNetworkProcessCrash();
399 bool hasVisibleWebPage() const;
400 void updateCPULimit();
401 enum class CPUMonitorUpdateReason { LimitHasChanged, VisibilityHasChanged };
402 void updateCPUMonitorState(CPUMonitorUpdateReason);
403
404 // AuxiliaryProcess
405 void initializeProcess(const AuxiliaryProcessInitializationParameters&) override;
406 void initializeProcessName(const AuxiliaryProcessInitializationParameters&) override;
407 void initializeSandbox(const AuxiliaryProcessInitializationParameters&, SandboxInitializationParameters&) override;
408 void initializeConnection(IPC::Connection*) override;
409 bool shouldTerminate() override;
410 void terminate() override;
411
412#if USE(APPKIT)
413 void stopRunLoop() override;
414#endif
415
416#if ENABLE(MEDIA_STREAM)
417 void addMockMediaDevice(const WebCore::MockMediaDevice&);
418 void clearMockMediaDevices();
419 void removeMockMediaDevice(const String& persistentId);
420 void resetMockMediaDevices();
421#if ENABLE(SANDBOX_EXTENSIONS)
422 void grantUserMediaDeviceSandboxExtensions(MediaDeviceSandboxExtensions&&);
423 void revokeUserMediaDeviceSandboxExtensions(const Vector<String>&);
424#endif
425
426#endif
427
428 void platformInitializeProcess(const AuxiliaryProcessInitializationParameters&);
429
430 // IPC::Connection::Client
431 friend class WebConnectionToUIProcess;
432 void didReceiveMessage(IPC::Connection&, IPC::Decoder&) override;
433 void didReceiveSyncMessage(IPC::Connection&, IPC::Decoder&, std::unique_ptr<IPC::Encoder>&) override;
434
435 // Implemented in generated WebProcessMessageReceiver.cpp
436 void didReceiveWebProcessMessage(IPC::Connection&, IPC::Decoder&);
437
438#if PLATFORM(MAC)
439 void setScreenProperties(const WebCore::ScreenProperties&);
440#if ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING)
441 void scrollerStylePreferenceChanged(bool useOverlayScrollbars);
442 void displayConfigurationChanged(CGDirectDisplayID, CGDisplayChangeSummaryFlags);
443 void displayWasRefreshed(CGDirectDisplayID);
444#endif
445#endif
446
447#if PLATFORM(COCOA)
448 void updateProcessName();
449#endif
450
451#if PLATFORM(IOS)
452 void backlightLevelDidChange(float backlightLevel);
453#endif
454
455#if PLATFORM(IOS_FAMILY)
456 void processTaskStateDidChange(ProcessTaskStateObserver::TaskState) final;
457 bool shouldFreezeOnSuspension() const;
458 void updateFreezerStatus();
459#endif
460
461#if ENABLE(VIDEO)
462 void suspendAllMediaBuffering();
463 void resumeAllMediaBuffering();
464#endif
465
466 void clearCurrentModifierStateForTesting();
467
468 RefPtr<WebConnectionToUIProcess> m_webConnection;
469
470 HashMap<WebCore::PageIdentifier, RefPtr<WebPage>> m_pageMap;
471 HashMap<uint64_t, RefPtr<WebPageGroupProxy>> m_pageGroupMap;
472 RefPtr<InjectedBundle> m_injectedBundle;
473
474 Ref<EventDispatcher> m_eventDispatcher;
475#if PLATFORM(IOS_FAMILY)
476 RefPtr<ViewUpdateDispatcher> m_viewUpdateDispatcher;
477#endif
478 RefPtr<WebInspectorInterruptDispatcher> m_webInspectorInterruptDispatcher;
479
480 HashMap<PAL::SessionID, HashMap<unsigned, WallTime>> m_plugInAutoStartOriginHashes;
481 HashSet<String> m_plugInAutoStartOrigins;
482
483 bool m_hasSetCacheModel { false };
484 CacheModel m_cacheModel { CacheModel::DocumentViewer };
485
486#if PLATFORM(COCOA)
487 WTF::MachSendRight m_compositingRenderServerPort;
488#endif
489
490 bool m_fullKeyboardAccessEnabled { false };
491
492 HashMap<uint64_t, WebFrame*> m_frameMap;
493
494 typedef HashMap<const char*, std::unique_ptr<WebProcessSupplement>, PtrHash<const char*>> WebProcessSupplementMap;
495 WebProcessSupplementMap m_supplements;
496
497 TextCheckerState m_textCheckerState;
498
499 String m_uiProcessBundleIdentifier;
500 RefPtr<NetworkProcessConnection> m_networkProcessConnection;
501 WebLoaderStrategy& m_webLoaderStrategy;
502
503 Ref<WebCacheStorageProvider> m_cacheStorageProvider;
504 WebSocketChannelManager m_webSocketChannelManager;
505
506 std::unique_ptr<LibWebRTCNetwork> m_libWebRTCNetwork;
507
508 HashSet<String> m_dnsPrefetchedHosts;
509 PAL::HysteresisActivity m_dnsPrefetchHystereris;
510
511 std::unique_ptr<WebAutomationSessionProxy> m_automationSessionProxy;
512
513#if ENABLE(NETSCAPE_PLUGIN_API)
514 RefPtr<PluginProcessConnectionManager> m_pluginProcessConnectionManager;
515#endif
516
517#if ENABLE(SERVICE_CONTROLS)
518 bool m_hasImageServices { false };
519 bool m_hasSelectionServices { false };
520 bool m_hasRichContentServices { false };
521#endif
522
523 bool m_processIsSuspended { false };
524
525 HashSet<WebCore::PageIdentifier> m_pagesInWindows;
526 WebCore::Timer m_nonVisibleProcessCleanupTimer;
527
528 RefPtr<WebCore::ApplicationCacheStorage> m_applicationCacheStorage;
529
530#if PLATFORM(IOS_FAMILY)
531 WebSQLiteDatabaseTracker m_webSQLiteDatabaseTracker;
532 ProcessTaskStateObserver m_taskStateObserver { *this };
533#endif
534
535 enum PageMarkingLayersAsVolatileCounterType { };
536 using PageMarkingLayersAsVolatileCounter = RefCounter<PageMarkingLayersAsVolatileCounterType>;
537 std::unique_ptr<PageMarkingLayersAsVolatileCounter> m_pageMarkingLayersAsVolatileCounter;
538 unsigned m_countOfPagesFailingToMarkVolatile { 0 };
539
540 bool m_suppressMemoryPressureHandler { false };
541#if PLATFORM(MAC)
542 std::unique_ptr<WebCore::CPUMonitor> m_cpuMonitor;
543 Optional<double> m_cpuLimit;
544
545 String m_uiProcessName;
546 WebCore::RegistrableDomain m_registrableDomain;
547#endif
548
549#if PLATFORM(COCOA)
550 enum class ProcessType { Inspector, ServiceWorker, PrewarmedWebContent, CachedWebContent, WebContent };
551 ProcessType m_processType { ProcessType::WebContent };
552#endif
553
554 HashMap<WebCore::UserGestureToken *, uint64_t> m_userGestureTokens;
555
556#if PLATFORM(WAYLAND)
557 std::unique_ptr<WaylandCompositorDisplay> m_waylandCompositorDisplay;
558#endif
559
560#if PLATFORM(WAYLAND) && USE(WPE_RENDERER)
561 std::unique_ptr<WebCore::PlatformDisplayLibWPE> m_wpeDisplay;
562#endif
563
564 bool m_hasSuspendedPageProxy { false };
565 bool m_isSuspending { false };
566
567#if ENABLE(MEDIA_STREAM) && ENABLE(SANDBOX_EXTENSIONS)
568 HashMap<String, RefPtr<SandboxExtension>> m_mediaCaptureSandboxExtensions;
569#endif
570
571#if PLATFORM(IOS)
572 float m_backlightLevel { 0 };
573#endif
574
575 HashMap<uint64_t, StorageAreaMap*> m_storageAreaMaps;
576};
577
578} // namespace WebKit
579