| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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 #include "net/cert/ct_sct_to_string.h" | 5 #include "net/cert/ct_sct_to_string.h" |
| 6 | 6 |
| 7 namespace net { | 7 namespace net { |
| 8 | 8 |
| 9 namespace ct { | 9 namespace ct { |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 case SignedCertificateTimestamp::SCT_ORIGIN_MAX: | 55 case SignedCertificateTimestamp::SCT_ORIGIN_MAX: |
| 56 NOTREACHED(); | 56 NOTREACHED(); |
| 57 } | 57 } |
| 58 return "Unknown"; | 58 return "Unknown"; |
| 59 } | 59 } |
| 60 | 60 |
| 61 const std::string StatusToString(SCTVerifyStatus status) { | 61 const std::string StatusToString(SCTVerifyStatus status) { |
| 62 switch (status) { | 62 switch (status) { |
| 63 case SCT_STATUS_LOG_UNKNOWN: | 63 case SCT_STATUS_LOG_UNKNOWN: |
| 64 return "From unknown log"; | 64 return "From unknown log"; |
| 65 case SCT_STATUS_INVALID: | 65 case SCT_STATUS_INVALID_SIGNATURE: |
| 66 return "Invalid"; | 66 return "Invalid signature"; |
| 67 case SCT_STATUS_INVALID_TIMESTAMP: |
| 68 return "Invalid timestamp"; |
| 67 case SCT_STATUS_OK: | 69 case SCT_STATUS_OK: |
| 68 return "Verified"; | 70 return "Verified"; |
| 69 case SCT_STATUS_NONE: | 71 case SCT_STATUS_NONE: |
| 70 return "None"; | 72 return "None"; |
| 71 case SCT_STATUS_MAX: | 73 case SCT_STATUS_MAX: |
| 72 NOTREACHED(); | 74 NOTREACHED(); |
| 73 } | 75 } |
| 74 return "Unknown"; | 76 return "Unknown"; |
| 75 } | 77 } |
| 76 | 78 |
| 77 } // namespace ct | 79 } // namespace ct |
| 78 | 80 |
| 79 } // namespace net | 81 } // namespace net |
| OLD | NEW |