Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 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 NET_CERT_OCSP_VERIFY_RESULT_H | |
| 6 #define NET_CERT_OCSP_VERIFY_RESULT_H | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/optional.h" | |
| 11 #include "net/base/net_export.h" | |
| 12 #include "net/cert/internal/parse_ocsp.h" | |
| 13 | |
| 14 namespace net { | |
| 15 | |
| 16 class NET_EXPORT OCSPVerifyResult { | |
| 17 public: | |
| 18 OCSPVerifyResult(); | |
| 19 OCSPVerifyResult(const OCSPVerifyResult&); | |
| 20 ~OCSPVerifyResult(); | |
| 21 | |
| 22 void Reset(); | |
| 23 | |
| 24 enum ResponseStatus { | |
| 25 // No OCSPResponse was stapled. | |
| 26 MISSING, | |
| 27 | |
| 28 // An up-to-date OCSP response was stapled and matched the certificate. | |
| 29 PROVIDED, | |
| 30 | |
| 31 // The stapled OCSP response did not have a SUCCESFUL status. | |
| 32 BAD_RESPONSE, | |
| 33 | |
| 34 // At least one OCSPSingleResponse was stapled, but none matched the | |
| 35 // certificate. | |
| 36 NO_MATCHING_RESPONSE, | |
| 37 | |
| 38 // A matching OCSPSingleResponse was stapled, but was either expired or not | |
| 39 // yet valid. | |
| 40 INVALID_DATE, | |
| 41 | |
| 42 // The OCSPResponse structure could not be parsed. | |
| 43 PARSE_RESPONSE, | |
| 44 | |
| 45 // The OCSPResponseData structure could not be parsed. | |
| 46 PARSE_RESPONSE_DATA, | |
| 47 }; | |
| 48 | |
| 49 ResponseStatus response_status; | |
| 50 | |
| 51 // The strictest CertStatus matching the certificate. Only present if | |
| 52 // |response_status| = PROVIDED. | |
|
svaldez
2016/06/29 14:41:22
*is
Maybe explicitly call out what "strictest" Ce
dadrian
2016/06/30 21:52:43
Done.
| |
| 53 base::Optional<OCSPCertStatus::Status> cert_status; | |
| 54 }; | |
| 55 | |
| 56 } // namespace net | |
| 57 | |
| 58 #endif // NET_CERT_OCSP_VERIFY_RESULT_H | |
| OLD | NEW |