1 /* 2 * Generated by util/mkerr.pl DO NOT EDIT 3 * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved. 4 * 5 * Licensed under the Apache License 2.0 (the "License"). You may not use 6 * this file except in compliance with the License. You can obtain a copy 7 * in the file LICENSE in the source distribution or at 8 * https://www.openssl.org/source/license.html 9 */ 10 11 #include <openssl/err.h> 12 #include <openssl/ocsperr.h> 13 #include "crypto/ocsperr.h" 14 15 #ifndef OPENSSL_NO_OCSP 16 17 # ifndef OPENSSL_NO_ERR 18 19 static const ERR_STRING_DATA OCSP_str_reasons[] = { 20 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_CERTIFICATE_VERIFY_ERROR), 21 "certificate verify error"}, 22 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_DIGEST_ERR), "digest err"}, 23 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_DIGEST_NAME_ERR), "digest name err"}, 24 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_DIGEST_SIZE_ERR), "digest size err"}, 25 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_ERROR_IN_NEXTUPDATE_FIELD), 26 "error in nextupdate field"}, 27 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_ERROR_IN_THISUPDATE_FIELD), 28 "error in thisupdate field"}, 29 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_MISSING_OCSPSIGNING_USAGE), 30 "missing ocspsigning usage"}, 31 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NEXTUPDATE_BEFORE_THISUPDATE), 32 "nextupdate before thisupdate"}, 33 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NOT_BASIC_RESPONSE), 34 "not basic response"}, 35 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NO_CERTIFICATES_IN_CHAIN), 36 "no certificates in chain"}, 37 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NO_RESPONSE_DATA), "no response data"}, 38 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NO_REVOKED_TIME), "no revoked time"}, 39 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_NO_SIGNER_KEY), "no signer key"}, 40 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE), 41 "private key does not match certificate"}, 42 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_REQUEST_NOT_SIGNED), 43 "request not signed"}, 44 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_RESPONSE_CONTAINS_NO_REVOCATION_DATA), 45 "response contains no revocation data"}, 46 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_ROOT_CA_NOT_TRUSTED), 47 "root ca not trusted"}, 48 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_SIGNATURE_FAILURE), "signature failure"}, 49 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_SIGNER_CERTIFICATE_NOT_FOUND), 50 "signer certificate not found"}, 51 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_STATUS_EXPIRED), "status expired"}, 52 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_STATUS_NOT_YET_VALID), 53 "status not yet valid"}, 54 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_STATUS_TOO_OLD), "status too old"}, 55 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_UNKNOWN_MESSAGE_DIGEST), 56 "unknown message digest"}, 57 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_UNKNOWN_NID), "unknown nid"}, 58 {ERR_PACK(ERR_LIB_OCSP, 0, OCSP_R_UNSUPPORTED_REQUESTORNAME_TYPE), 59 "unsupported requestorname type"}, 60 {0, NULL} 61 }; 62 63 # endif 64 65 int ossl_err_load_OCSP_strings(void) 66 { 67 # ifndef OPENSSL_NO_ERR 68 if (ERR_reason_error_string(OCSP_str_reasons[0].error) == NULL) 69 ERR_load_strings_const(OCSP_str_reasons); 70 # endif 71 return 1; 72 } 73 #else 74 NON_EMPTY_TRANSLATION_UNIT 75 #endif 76