OLD | NEW |
(Empty) | |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef IOS_WEB_NAVIGATION_CRW_SESSION_CERTIFICATE_POLICY_MANAGER_H_ |
| 6 #define IOS_WEB_NAVIGATION_CRW_SESSION_CERTIFICATE_POLICY_MANAGER_H_ |
| 7 |
| 8 #import <Foundation/Foundation.h> |
| 9 #include <string> |
| 10 |
| 11 #include "base/memory/ref_counted.h" |
| 12 #include "net/cert/cert_status_flags.h" |
| 13 |
| 14 @class CRWSessionEntry; |
| 15 |
| 16 namespace net { |
| 17 class X509Certificate; |
| 18 } |
| 19 |
| 20 namespace web { |
| 21 class CertificatePolicyCache; |
| 22 } |
| 23 |
| 24 // The CRWSessionCertificatePolicyManager keeps track of the certificates that |
| 25 // have been manually allowed by the user despite the errors. |
| 26 // The CRWSessionCertificatePolicyManager lives on the main thread. |
| 27 @interface CRWSessionCertificatePolicyManager : NSObject <NSCoding, NSCopying> |
| 28 |
| 29 - (void)registerAllowedCertificate:(net::X509Certificate*)certificate |
| 30 forHost:(const std::string&)host |
| 31 status:(net::CertStatus)status; |
| 32 |
| 33 // Removes all the certificates associated with this session. Note that this has |
| 34 // no effect on the policy cache service. |
| 35 - (void)clearCertificates; |
| 36 |
| 37 // Copies the certificate polices for the session into |cache|. |
| 38 - (void)updateCertificatePolicyCache: |
| 39 (const scoped_refptr<web::CertificatePolicyCache>&)cache; |
| 40 |
| 41 @end |
| 42 |
| 43 #endif // IOS_WEB_NAVIGATION_CRW_SESSION_CERTIFICATE_POLICY_MANAGER_H_ |
OLD | NEW |