1e1051a39Sopenharmony_ci/* 2e1051a39Sopenharmony_ci * Generated by util/mkerr.pl DO NOT EDIT 3e1051a39Sopenharmony_ci * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved. 4e1051a39Sopenharmony_ci * 5e1051a39Sopenharmony_ci * Licensed under the Apache License 2.0 (the "License"). You may not use 6e1051a39Sopenharmony_ci * this file except in compliance with the License. You can obtain a copy 7e1051a39Sopenharmony_ci * in the file LICENSE in the source distribution or at 8e1051a39Sopenharmony_ci * https://www.openssl.org/source/license.html 9e1051a39Sopenharmony_ci */ 10e1051a39Sopenharmony_ci 11e1051a39Sopenharmony_ci#include <openssl/err.h> 12e1051a39Sopenharmony_ci#include <openssl/pkcs12err.h> 13e1051a39Sopenharmony_ci#include "crypto/pkcs12err.h" 14e1051a39Sopenharmony_ci 15e1051a39Sopenharmony_ci#ifndef OPENSSL_NO_ERR 16e1051a39Sopenharmony_ci 17e1051a39Sopenharmony_cistatic const ERR_STRING_DATA PKCS12_str_reasons[] = { 18e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_CANT_PACK_STRUCTURE), 19e1051a39Sopenharmony_ci "cant pack structure"}, 20e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_CONTENT_TYPE_NOT_DATA), 21e1051a39Sopenharmony_ci "content type not data"}, 22e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_DECODE_ERROR), "decode error"}, 23e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_ENCODE_ERROR), "encode error"}, 24e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_ENCRYPT_ERROR), "encrypt error"}, 25e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_ERROR_SETTING_ENCRYPTED_DATA_TYPE), 26e1051a39Sopenharmony_ci "error setting encrypted data type"}, 27e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_INVALID_NULL_ARGUMENT), 28e1051a39Sopenharmony_ci "invalid null argument"}, 29e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_INVALID_NULL_PKCS12_POINTER), 30e1051a39Sopenharmony_ci "invalid null pkcs12 pointer"}, 31e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_INVALID_TYPE), "invalid type"}, 32e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_IV_GEN_ERROR), "iv gen error"}, 33e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_KEY_GEN_ERROR), "key gen error"}, 34e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_MAC_ABSENT), "mac absent"}, 35e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_MAC_GENERATION_ERROR), 36e1051a39Sopenharmony_ci "mac generation error"}, 37e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_MAC_SETUP_ERROR), "mac setup error"}, 38e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_MAC_STRING_SET_ERROR), 39e1051a39Sopenharmony_ci "mac string set error"}, 40e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_MAC_VERIFY_FAILURE), 41e1051a39Sopenharmony_ci "mac verify failure"}, 42e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_PARSE_ERROR), "parse error"}, 43e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_PKCS12_CIPHERFINAL_ERROR), 44e1051a39Sopenharmony_ci "pkcs12 cipherfinal error"}, 45e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_UNKNOWN_DIGEST_ALGORITHM), 46e1051a39Sopenharmony_ci "unknown digest algorithm"}, 47e1051a39Sopenharmony_ci {ERR_PACK(ERR_LIB_PKCS12, 0, PKCS12_R_UNSUPPORTED_PKCS12_MODE), 48e1051a39Sopenharmony_ci "unsupported pkcs12 mode"}, 49e1051a39Sopenharmony_ci {0, NULL} 50e1051a39Sopenharmony_ci}; 51e1051a39Sopenharmony_ci 52e1051a39Sopenharmony_ci#endif 53e1051a39Sopenharmony_ci 54e1051a39Sopenharmony_ciint ossl_err_load_PKCS12_strings(void) 55e1051a39Sopenharmony_ci{ 56e1051a39Sopenharmony_ci#ifndef OPENSSL_NO_ERR 57e1051a39Sopenharmony_ci if (ERR_reason_error_string(PKCS12_str_reasons[0].error) == NULL) 58e1051a39Sopenharmony_ci ERR_load_strings_const(PKCS12_str_reasons); 59e1051a39Sopenharmony_ci#endif 60e1051a39Sopenharmony_ci return 1; 61e1051a39Sopenharmony_ci} 62