Googler | 1187115 | 2020-10-01 14:59:09 -0400 | [diff] [blame] | 1 | // Copyright (c) 2016 The Chromium Embedded Framework Authors. All rights |
| 2 | // reserved. Use of this source code is governed by a BSD-style license that |
| 3 | // can be found in the LICENSE file. |
| 4 | |
| 5 | #ifndef CEF_LIBCEF_BROWSER_SSL_STATUS_IMPL_H_ |
| 6 | #define CEF_LIBCEF_BROWSER_SSL_STATUS_IMPL_H_ |
| 7 | #pragma once |
| 8 | |
| 9 | #include "include/cef_ssl_status.h" |
| 10 | |
| 11 | #include "content/public/browser/ssl_status.h" |
| 12 | |
| 13 | // CefSSLStatus implementation |
| 14 | class CefSSLStatusImpl : public CefSSLStatus { |
| 15 | public: |
| 16 | explicit CefSSLStatusImpl(const content::SSLStatus& value); |
| 17 | |
Googler | 39a9757 | 2023-12-13 22:53:26 +0000 | [diff] [blame^] | 18 | CefSSLStatusImpl(const CefSSLStatusImpl&) = delete; |
| 19 | CefSSLStatusImpl& operator=(const CefSSLStatusImpl&) = delete; |
| 20 | |
Googler | 1187115 | 2020-10-01 14:59:09 -0400 | [diff] [blame] | 21 | // CefSSLStatus methods. |
| 22 | bool IsSecureConnection() override; |
| 23 | cef_cert_status_t GetCertStatus() override; |
| 24 | cef_ssl_version_t GetSSLVersion() override; |
| 25 | cef_ssl_content_status_t GetContentStatus() override; |
| 26 | CefRefPtr<CefX509Certificate> GetX509Certificate() override; |
| 27 | |
| 28 | private: |
| 29 | cef_cert_status_t cert_status_; |
| 30 | cef_ssl_version_t ssl_version_; |
| 31 | cef_ssl_content_status_t content_status_; |
| 32 | |
| 33 | // Don't create a CefX509Certificate object until requested. |
| 34 | scoped_refptr<net::X509Certificate> certificate_; |
| 35 | CefRefPtr<CefX509Certificate> cef_certificate_; |
| 36 | |
| 37 | IMPLEMENT_REFCOUNTING(CefSSLStatusImpl); |
Googler | 1187115 | 2020-10-01 14:59:09 -0400 | [diff] [blame] | 38 | }; |
| 39 | |
| 40 | #endif // CEF_LIBCEF_BROWSER_SSL_STATUS_IMPL_H_ |