OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 931 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
942 } | 942 } |
943 } | 943 } |
944 } else { | 944 } else { |
945 NOTREACHED(); | 945 NOTREACHED(); |
946 } | 946 } |
947 } | 947 } |
948 | 948 |
949 TabContentsWrapper* wrapper = | 949 TabContentsWrapper* wrapper = |
950 TabContentsWrapper::GetCurrentWrapperForContents(tab); | 950 TabContentsWrapper::GetCurrentWrapperForContents(tab); |
951 if (!wrapper) { | 951 if (!wrapper) { |
952 LOG(ERROR) << " *** No TabcontentsWrapper for: " << tab->GetURL().spec(); | |
953 // If there is no TabContentsWrapper for the given TabContents then we can't | 952 // If there is no TabContentsWrapper for the given TabContents then we can't |
954 // show the user a dialog to select a client certificate. So we simply | 953 // show the user a dialog to select a client certificate. So we simply |
955 // cancel the request. | 954 // proceed with no client certificate. |
956 handler->CertificateSelected(NULL); | 955 handler->CertificateSelected(NULL); |
957 return; | 956 return; |
958 } | 957 } |
959 wrapper->ssl_helper()->ShowClientCertificateRequestDialog(handler); | 958 wrapper->ssl_helper()->ShowClientCertificateRequestDialog(handler); |
960 } | 959 } |
961 | 960 |
962 void ChromeContentBrowserClient::AddNewCertificate( | 961 void ChromeContentBrowserClient::AddNewCertificate( |
963 net::URLRequest* request, | 962 net::URLRequest* request, |
964 net::X509Certificate* cert, | 963 net::X509Certificate* cert, |
965 int render_process_id, | 964 int render_process_id, |
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1211 #if defined(USE_NSS) | 1210 #if defined(USE_NSS) |
1212 crypto::CryptoModuleBlockingPasswordDelegate* | 1211 crypto::CryptoModuleBlockingPasswordDelegate* |
1213 ChromeContentBrowserClient::GetCryptoPasswordDelegate( | 1212 ChromeContentBrowserClient::GetCryptoPasswordDelegate( |
1214 const GURL& url) { | 1213 const GURL& url) { |
1215 return browser::NewCryptoModuleBlockingDialogDelegate( | 1214 return browser::NewCryptoModuleBlockingDialogDelegate( |
1216 browser::kCryptoModulePasswordKeygen, url.host()); | 1215 browser::kCryptoModulePasswordKeygen, url.host()); |
1217 } | 1216 } |
1218 #endif | 1217 #endif |
1219 | 1218 |
1220 } // namespace chrome | 1219 } // namespace chrome |
OLD | NEW |