diff options
Diffstat (limited to 'src/core/profile_io_data_qt.h')
-rw-r--r-- | src/core/profile_io_data_qt.h | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/src/core/profile_io_data_qt.h b/src/core/profile_io_data_qt.h index 4a5b9f77d..8f11a9ce2 100644 --- a/src/core/profile_io_data_qt.h +++ b/src/core/profile_io_data_qt.h @@ -42,9 +42,13 @@ #include "profile_adapter.h" #include "content/public/browser/browsing_data_remover.h" +#include "content/public/common/url_loader_throttle.h" #include "chrome/browser/profiles/profile.h" #include "chrome/browser/custom_handlers/protocol_handler_registry.h" #include "extensions/buildflags/buildflags.h" +#include "mojo/public/cpp/bindings/strong_binding_set.h" +#include "services/network/cookie_settings.h" +#include "services/network/public/mojom/restricted_cookie_manager.mojom.h" #include "services/proxy_resolver/public/mojom/proxy_resolver.mojom.h" #include <QtCore/QString> @@ -56,6 +60,7 @@ class ClientCertStore; class DhcpPacFileFetcherFactory; class HttpAuthPreferences; class HttpNetworkSession; +class HostResolver; class NetworkDelegate; class ProxyConfigService; class URLRequestContext; @@ -103,6 +108,11 @@ public: extensions::ExtensionSystemQt* GetExtensionSystem(); #endif // BUILDFLAG(ENABLE_EXTENSIONS) + ProtocolHandlerRegistry::IOThreadDelegate *protocolHandlerRegistryIOThreadDelegate() + { + return m_protocolHandlerRegistryIOThreadDelegate.get(); + } + void initializeOnIOThread(); void initializeOnUIThread(); // runs on ui thread void shutdownOnUIThread(); // runs on ui thread @@ -138,11 +148,22 @@ public: void updateUsedForGlobalCertificateVerification(); // runs on ui thread bool hasPageInterceptors(); + void CreateRestrictedCookieManager(network::mojom::RestrictedCookieManagerRequest request, + network::mojom::RestrictedCookieManagerRole role, + const url::Origin &origin, + bool is_service_worker, + int32_t process_id, + int32_t routing_id); + #if QT_CONFIG(ssl) ClientCertificateStoreData *clientCertificateStoreData(); #endif std::unique_ptr<net::ClientCertStore> CreateClientCertStore(); + static ProfileIODataQt *FromBrowserContext(content::BrowserContext *browser_context); static ProfileIODataQt *FromResourceContext(content::ResourceContext *resource_context); + + base::WeakPtr<ProfileIODataQt> getWeakPtrOnUIThread(); + private: void removeBrowsingDataRemoverObserver(); @@ -152,11 +173,13 @@ private: std::unique_ptr<content::ResourceContext> m_resourceContext; std::unique_ptr<net::URLRequestContext> m_urlRequestContext; std::unique_ptr<net::HttpNetworkSession> m_httpNetworkSession; - std::unique_ptr<ProtocolHandlerRegistry::JobInterceptorFactory> m_protocolHandlerInterceptor; + scoped_refptr<ProtocolHandlerRegistry::IOThreadDelegate> + m_protocolHandlerRegistryIOThreadDelegate; std::unique_ptr<net::DhcpPacFileFetcherFactory> m_dhcpPacFileFetcherFactory; std::unique_ptr<net::HttpAuthPreferences> m_httpAuthPreferences; std::unique_ptr<net::URLRequestJobFactory> m_jobFactory; std::unique_ptr<net::TransportSecurityPersister> m_transportSecurityPersister; + std::unique_ptr<net::HostResolver> m_hostResolver; base::WeakPtr<ProfileIODataQt> m_weakPtr; scoped_refptr<CookieMonsterDelegateQt> m_cookieDelegate; content::URLRequestInterceptorScopedVector m_requestInterceptors; @@ -166,6 +189,8 @@ private: QAtomicPointer<net::ProxyConfigService> m_proxyConfigService; QPointer<ProfileAdapter> m_profileAdapter; // never dereferenced in IO thread and it is passed by qpointer ProfileAdapter::PersistentCookiesPolicy m_persistentCookiesPolicy; + mojo::StrongBindingSet<network::mojom::RestrictedCookieManager> m_restrictedCookieManagerBindings; + #if QT_CONFIG(ssl) ClientCertificateStoreData *m_clientCertificateStoreData; #endif @@ -177,6 +202,7 @@ private: QList<QByteArray> m_customUrlSchemes; QList<QByteArray> m_installedCustomSchemes; QWebEngineUrlRequestInterceptor* m_requestInterceptor = nullptr; + network::CookieSettings m_cookieSettings; #if QT_VERSION < QT_VERSION_CHECK(5, 14, 0) QMutex m_mutex{QMutex::Recursive}; using QRecursiveMutex = QMutex; |