Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(420)

Side by Side Diff: net/base/x509_certificate.h

Issue 42255: SSL Fix: Step 2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | net/base/x509_certificate.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_BASE_X509_CERTIFICATE_H_ 5 #ifndef NET_BASE_X509_CERTIFICATE_H_
6 #define NET_BASE_X509_CERTIFICATE_H_ 6 #define NET_BASE_X509_CERTIFICATE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 103
104 // Returns the judgment this policy makes about this certificate. 104 // Returns the judgment this policy makes about this certificate.
105 Judgment Check(X509Certificate* cert) const; 105 Judgment Check(X509Certificate* cert) const;
106 106
107 // Causes the policy to allow this certificate. 107 // Causes the policy to allow this certificate.
108 void Allow(X509Certificate* cert); 108 void Allow(X509Certificate* cert);
109 109
110 // Causes the policy to deny this certificate. 110 // Causes the policy to deny this certificate.
111 void Deny(X509Certificate* cert); 111 void Deny(X509Certificate* cert);
112 112
113 // Returns true if this policy has allowed at least one certificate.
114 bool HasAllowedCert() const;
115
116 // Returns true if this policy has denied at least one certificate.
117 bool HasDeniedCert() const;
118
113 private: 119 private:
114 // The set of fingerprints of allowed certificates. 120 // The set of fingerprints of allowed certificates.
115 std::set<Fingerprint, FingerprintLessThan> allowed_; 121 std::set<Fingerprint, FingerprintLessThan> allowed_;
116 122
117 // The set of fingerprints of denied certificates. 123 // The set of fingerprints of denied certificates.
118 std::set<Fingerprint, FingerprintLessThan> denied_; 124 std::set<Fingerprint, FingerprintLessThan> denied_;
119 }; 125 };
120 126
121 // Where the certificate comes from. The enumeration constants are 127 // Where the certificate comes from. The enumeration constants are
122 // listed in increasing order of preference. 128 // listed in increasing order of preference.
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 290
285 // Where the certificate comes from. 291 // Where the certificate comes from.
286 Source source_; 292 Source source_;
287 293
288 DISALLOW_COPY_AND_ASSIGN(X509Certificate); 294 DISALLOW_COPY_AND_ASSIGN(X509Certificate);
289 }; 295 };
290 296
291 } // namespace net 297 } // namespace net
292 298
293 #endif // NET_BASE_X509_CERTIFICATE_H_ 299 #endif // NET_BASE_X509_CERTIFICATE_H_
OLDNEW
« no previous file with comments | « no previous file | net/base/x509_certificate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698