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 #ifndef NET_CERT_NSS_CERT_DATABASE_H_ | 5 #ifndef NET_CERT_NSS_CERT_DATABASE_H_ |
6 #define NET_CERT_NSS_CERT_DATABASE_H_ | 6 #define NET_CERT_NSS_CERT_DATABASE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 protected: | 47 protected: |
48 Observer() {} | 48 Observer() {} |
49 | 49 |
50 private: | 50 private: |
51 DISALLOW_COPY_AND_ASSIGN(Observer); | 51 DISALLOW_COPY_AND_ASSIGN(Observer); |
52 }; | 52 }; |
53 | 53 |
54 // Stores per-certificate error codes for import failures. | 54 // Stores per-certificate error codes for import failures. |
55 struct NET_EXPORT ImportCertFailure { | 55 struct NET_EXPORT ImportCertFailure { |
56 public: | 56 public: |
57 ImportCertFailure(X509Certificate* cert, int err); | 57 ImportCertFailure(const scoped_refptr<X509Certificate>& cert, int err); |
58 ~ImportCertFailure(); | 58 ~ImportCertFailure(); |
59 | 59 |
60 scoped_refptr<X509Certificate> certificate; | 60 scoped_refptr<X509Certificate> certificate; |
61 int net_error; | 61 int net_error; |
62 }; | 62 }; |
63 typedef std::vector<ImportCertFailure> ImportCertFailureList; | 63 typedef std::vector<ImportCertFailure> ImportCertFailureList; |
64 | 64 |
65 // Constants that define which usages a certificate is trusted for. | 65 // Constants that define which usages a certificate is trusted for. |
66 // They are used in combination with CertType to specify trust for each type | 66 // They are used in combination with CertType to specify trust for each type |
67 // of certificate. | 67 // of certificate. |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 void NotifyObserversOfCertTrustChanged(const X509Certificate* cert); | 199 void NotifyObserversOfCertTrustChanged(const X509Certificate* cert); |
200 | 200 |
201 const scoped_refptr<ObserverListThreadSafe<Observer> > observer_list_; | 201 const scoped_refptr<ObserverListThreadSafe<Observer> > observer_list_; |
202 | 202 |
203 DISALLOW_COPY_AND_ASSIGN(NSSCertDatabase); | 203 DISALLOW_COPY_AND_ASSIGN(NSSCertDatabase); |
204 }; | 204 }; |
205 | 205 |
206 } // namespace net | 206 } // namespace net |
207 | 207 |
208 #endif // NET_CERT_NSS_CERT_DATABASE_H_ | 208 #endif // NET_CERT_NSS_CERT_DATABASE_H_ |
OLD | NEW |