diff options
author | Vijith Kini <vijith@claysol.com> | 2018-12-07 09:30:38 +0530 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2019-01-23 14:24:07 +0000 |
commit | be0fb77baf98f773928b4ff9d08a13c83f189564 (patch) | |
tree | 2a84528dd03fda0e44df790f7aa52f242f423b2e /src/core/content_browser_client_qt.cpp | |
parent | e11adebe6f4f76a3e3253b33314a2b4635dc3e65 (diff) |
Add in-memory client cert store implementation
Qt applications using webengine can now use a specific client certificate
without affecting(or using) the native certificate store. It sounds useful
for consumer applications where the application wants to identify itself to
the server as the application and not as a specific user.
Change-Id: Ib4fcdfd48e00051e3215f90be8701978902b1fbf
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/core/content_browser_client_qt.cpp')
-rw-r--r-- | src/core/content_browser_client_qt.cpp | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/src/core/content_browser_client_qt.cpp b/src/core/content_browser_client_qt.cpp index beec6dd26..b5b2ca0fd 100644 --- a/src/core/content_browser_client_qt.cpp +++ b/src/core/content_browser_client_qt.cpp @@ -85,6 +85,7 @@ #include "qtwebengine/grit/qt_webengine_resources.h" +#include "client_cert_override_p.h" #include "profile_adapter.h" #include "browser_main_parts_qt.h" #include "browser_message_filter_qt.h" @@ -113,18 +114,6 @@ #include "ui/base/resource/resource_bundle.h" #endif -#if defined(USE_NSS_CERTS) -#include "net/ssl/client_cert_store_nss.h" -#endif - -#if defined(OS_WIN) -#include "net/ssl/client_cert_store_win.h" -#endif - -#if defined(OS_MACOSX) -#include "net/ssl/client_cert_store_mac.h" -#endif - #if QT_CONFIG(webengine_pepper_plugins) #include "content/public/browser/browser_ppapi_host.h" #include "ppapi/host/ppapi_host.h" @@ -381,17 +370,8 @@ std::unique_ptr<net::ClientCertStore> ContentBrowserClientQt::CreateClientCertSt { if (!resource_context) return nullptr; -#if defined(USE_NSS_CERTS) - // FIXME: Give it a proper callback for a password delegate. - return std::unique_ptr<net::ClientCertStore>( - new net::ClientCertStoreNSS(net::ClientCertStoreNSS::PasswordDelegateFactory())); -#elif defined(OS_WIN) - return std::unique_ptr<net::ClientCertStore>(new net::ClientCertStoreWin()); -#elif defined(OS_MACOSX) - return std::unique_ptr<net::ClientCertStore>(new net::ClientCertStoreMac()); -#else - return nullptr; -#endif + + return std::unique_ptr<net::ClientCertStore>(new net::ClientCertOverrideStore()); } std::string ContentBrowserClientQt::GetApplicationLocale() |