OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1605 | 1605 |
1606 if (filter.get()) { | 1606 if (filter.get()) { |
1607 // Try to automatically select a client certificate. | 1607 // Try to automatically select a client certificate. |
1608 if (filter->IsType(Value::TYPE_DICTIONARY)) { | 1608 if (filter->IsType(Value::TYPE_DICTIONARY)) { |
1609 DictionaryValue* filter_dict = | 1609 DictionaryValue* filter_dict = |
1610 static_cast<DictionaryValue*>(filter.get()); | 1610 static_cast<DictionaryValue*>(filter.get()); |
1611 | 1611 |
1612 const std::vector<scoped_refptr<net::X509Certificate> >& | 1612 const std::vector<scoped_refptr<net::X509Certificate> >& |
1613 all_client_certs = cert_request_info->client_certs; | 1613 all_client_certs = cert_request_info->client_certs; |
1614 for (size_t i = 0; i < all_client_certs.size(); ++i) { | 1614 for (size_t i = 0; i < all_client_certs.size(); ++i) { |
1615 if (CertMatchesFilter(*all_client_certs[i], *filter_dict)) { | 1615 if (CertMatchesFilter(*all_client_certs[i].get(), *filter_dict)) { |
1616 // Use the first certificate that is matched by the filter. | 1616 // Use the first certificate that is matched by the filter. |
1617 callback.Run(all_client_certs[i]); | 1617 callback.Run(all_client_certs[i].get()); |
1618 return; | 1618 return; |
1619 } | 1619 } |
1620 } | 1620 } |
1621 } else { | 1621 } else { |
1622 NOTREACHED(); | 1622 NOTREACHED(); |
1623 } | 1623 } |
1624 } | 1624 } |
1625 | 1625 |
1626 SSLTabHelper* ssl_tab_helper = SSLTabHelper::FromWebContents(tab); | 1626 SSLTabHelper* ssl_tab_helper = SSLTabHelper::FromWebContents(tab); |
1627 if (!ssl_tab_helper) { | 1627 if (!ssl_tab_helper) { |
(...skipping 656 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2284 #if defined(USE_NSS) | 2284 #if defined(USE_NSS) |
2285 crypto::CryptoModuleBlockingPasswordDelegate* | 2285 crypto::CryptoModuleBlockingPasswordDelegate* |
2286 ChromeContentBrowserClient::GetCryptoPasswordDelegate( | 2286 ChromeContentBrowserClient::GetCryptoPasswordDelegate( |
2287 const GURL& url) { | 2287 const GURL& url) { |
2288 return chrome::NewCryptoModuleBlockingDialogDelegate( | 2288 return chrome::NewCryptoModuleBlockingDialogDelegate( |
2289 chrome::kCryptoModulePasswordKeygen, url.host()); | 2289 chrome::kCryptoModulePasswordKeygen, url.host()); |
2290 } | 2290 } |
2291 #endif | 2291 #endif |
2292 | 2292 |
2293 } // namespace chrome | 2293 } // namespace chrome |
OLD | NEW |