Skip to content

Commit

Permalink
[fuchsia] Send a null client certificate
Browse files Browse the repository at this point in the history
Bug: 1176941
Change-Id: I9fffe2b139aef19bb6f95663bc4d725632df59c6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2686455
Commit-Queue: Fabrice de Gans-Riberi <fdegans@chromium.org>
Reviewed-by: David Dorwin <ddorwin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#852840}
  • Loading branch information
Steelskin authored and Chromium LUCI CQ committed Feb 10, 2021
1 parent 039d1da commit 5d50866
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
11 changes: 11 additions & 0 deletions fuchsia/engine/browser/web_engine_content_browser_client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "base/strings/string_split.h"
#include "components/policy/content/safe_sites_navigation_throttle.h"
#include "components/version_info/version_info.h"
#include "content/public/browser/client_certificate_delegate.h"
#include "content/public/browser/devtools_manager_delegate.h"
#include "content/public/browser/navigation_handle.h"
#include "content/public/browser/network_service_instance.h"
Expand Down Expand Up @@ -199,6 +200,16 @@ std::string WebEngineContentBrowserClient::GetAcceptLangs(
->GetPreferredLanguages();
}

base::OnceClosure WebEngineContentBrowserClient::SelectClientCertificate(
content::WebContents* web_contents,
net::SSLCertRequestInfo* cert_request_info,
net::ClientCertIdentityList client_certs,
std::unique_ptr<content::ClientCertificateDelegate> delegate) {
// Continue without a certificate.
delegate->ContinueWithCertificate(nullptr, nullptr);
return base::OnceClosure();
}

std::vector<std::unique_ptr<content::NavigationThrottle>>
WebEngineContentBrowserClient::CreateThrottlesForNavigation(
content::NavigationHandle* navigation_handle) {
Expand Down
5 changes: 5 additions & 0 deletions fuchsia/engine/browser/web_engine_content_browser_client.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ class WebEngineContentBrowserClient : public content::ContentBrowserClient {
int child_process_id) final;
std::string GetApplicationLocale() final;
std::string GetAcceptLangs(content::BrowserContext* context) final;
base::OnceClosure SelectClientCertificate(
content::WebContents* web_contents,
net::SSLCertRequestInfo* cert_request_info,
net::ClientCertIdentityList client_certs,
std::unique_ptr<content::ClientCertificateDelegate> delegate) final;
std::vector<std::unique_ptr<content::NavigationThrottle>>
CreateThrottlesForNavigation(
content::NavigationHandle* navigation_handle) final;
Expand Down

0 comments on commit 5d50866

Please sign in to comment.