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 1751 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1762 if (expired_previous_decision) | 1762 if (expired_previous_decision) |
1763 options_mask |= SSLBlockingPage::EXPIRED_BUT_PREVIOUSLY_ALLOWED; | 1763 options_mask |= SSLBlockingPage::EXPIRED_BUT_PREVIOUSLY_ALLOWED; |
1764 SSLBlockingPage* ssl_blocking_page = new SSLBlockingPage( | 1764 SSLBlockingPage* ssl_blocking_page = new SSLBlockingPage( |
1765 tab, cert_error, ssl_info, request_url, options_mask, callback); | 1765 tab, cert_error, ssl_info, request_url, options_mask, callback); |
1766 ssl_blocking_page->Show(); | 1766 ssl_blocking_page->Show(); |
1767 } | 1767 } |
1768 | 1768 |
1769 void ChromeContentBrowserClient::SelectClientCertificate( | 1769 void ChromeContentBrowserClient::SelectClientCertificate( |
1770 int render_process_id, | 1770 int render_process_id, |
1771 int render_frame_id, | 1771 int render_frame_id, |
1772 const net::HttpNetworkSession* network_session, | |
1773 net::SSLCertRequestInfo* cert_request_info, | 1772 net::SSLCertRequestInfo* cert_request_info, |
1774 const base::Callback<void(net::X509Certificate*)>& callback) { | 1773 const base::Callback<void(net::X509Certificate*)>& callback) { |
1775 content::RenderFrameHost* rfh = content::RenderFrameHost::FromID( | 1774 content::RenderFrameHost* rfh = content::RenderFrameHost::FromID( |
1776 render_process_id, render_frame_id); | 1775 render_process_id, render_frame_id); |
1777 WebContents* tab = WebContents::FromRenderFrameHost(rfh); | 1776 WebContents* tab = WebContents::FromRenderFrameHost(rfh); |
1778 if (!tab) { | 1777 if (!tab) { |
1779 NOTREACHED(); | 1778 NOTREACHED(); |
1780 return; | 1779 return; |
1781 } | 1780 } |
1782 | 1781 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1815 // Use the first certificate that is matched by the filter. | 1814 // Use the first certificate that is matched by the filter. |
1816 callback.Run(all_client_certs[i].get()); | 1815 callback.Run(all_client_certs[i].get()); |
1817 return; | 1816 return; |
1818 } | 1817 } |
1819 } | 1818 } |
1820 } else { | 1819 } else { |
1821 NOTREACHED(); | 1820 NOTREACHED(); |
1822 } | 1821 } |
1823 } | 1822 } |
1824 | 1823 |
1825 chrome::ShowSSLClientCertificateSelector(tab, network_session, | 1824 chrome::ShowSSLClientCertificateSelector(tab, cert_request_info, callback); |
1826 cert_request_info, callback); | |
1827 } | 1825 } |
1828 | 1826 |
1829 void ChromeContentBrowserClient::AddCertificate( | 1827 void ChromeContentBrowserClient::AddCertificate( |
1830 net::CertificateMimeType cert_type, | 1828 net::CertificateMimeType cert_type, |
1831 const void* cert_data, | 1829 const void* cert_data, |
1832 size_t cert_size, | 1830 size_t cert_size, |
1833 int render_process_id, | 1831 int render_process_id, |
1834 int render_frame_id) { | 1832 int render_frame_id) { |
1835 chrome::SSLAddCertificate(cert_type, cert_data, cert_size, | 1833 chrome::SSLAddCertificate(cert_type, cert_data, cert_size, |
1836 render_process_id, render_frame_id); | 1834 render_process_id, render_frame_id); |
(...skipping 777 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2614 switches::kDisableWebRtcEncryption, | 2612 switches::kDisableWebRtcEncryption, |
2615 }; | 2613 }; |
2616 to_command_line->CopySwitchesFrom(from_command_line, | 2614 to_command_line->CopySwitchesFrom(from_command_line, |
2617 kWebRtcDevSwitchNames, | 2615 kWebRtcDevSwitchNames, |
2618 arraysize(kWebRtcDevSwitchNames)); | 2616 arraysize(kWebRtcDevSwitchNames)); |
2619 } | 2617 } |
2620 } | 2618 } |
2621 #endif // defined(ENABLE_WEBRTC) | 2619 #endif // defined(ENABLE_WEBRTC) |
2622 | 2620 |
2623 } // namespace chrome | 2621 } // namespace chrome |
OLD | NEW |