pkcs7err.c revision 55714
16059Samurai/* crypto/pkcs7/pkcs7err.c */ 26059Samurai/* ==================================================================== 36059Samurai * Copyright (c) 1999 The OpenSSL Project. All rights reserved. 46059Samurai * 56059Samurai * Redistribution and use in source and binary forms, with or without 66059Samurai * modification, are permitted provided that the following conditions 76059Samurai * are met: 86059Samurai * 96059Samurai * 1. Redistributions of source code must retain the above copyright 106059Samurai * notice, this list of conditions and the following disclaimer. 116059Samurai * 126059Samurai * 2. Redistributions in binary form must reproduce the above copyright 136059Samurai * notice, this list of conditions and the following disclaimer in 146059Samurai * the documentation and/or other materials provided with the 156059Samurai * distribution. 166059Samurai * 176059Samurai * 3. All advertising materials mentioning features or use of this 186059Samurai * software must display the following acknowledgment: 196059Samurai * "This product includes software developed by the OpenSSL Project 2032663Sbrian * for use in the OpenSSL Toolkit. (http://www.OpenSSL.org/)" 218857Srgrimes * 226059Samurai * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to 2330715Sbrian * endorse or promote products derived from this software without 246059Samurai * prior written permission. For written permission, please contact 2530715Sbrian * openssl-core@OpenSSL.org. 266059Samurai * 2731176Sbrian * 5. Products derived from this software may not be called "OpenSSL" 2830715Sbrian * nor may "OpenSSL" appear in their names without prior written 2930715Sbrian * permission of the OpenSSL Project. 3030715Sbrian * 3130715Sbrian * 6. Redistributions of any form whatsoever must retain the following 3231176Sbrian * acknowledgment: 3320287Swollman * "This product includes software developed by the OpenSSL Project 3420287Swollman * for use in the OpenSSL Toolkit (http://www.OpenSSL.org/)" 3530715Sbrian * 3630715Sbrian * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY 376059Samurai * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 386059Samurai * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 3930715Sbrian * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR 4030715Sbrian * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 416059Samurai * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 4220287Swollman * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 4331343Sbrian * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 4430715Sbrian * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 459439Samurai * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 4626516Sbrian * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 4731070Sbrian * OF THE POSSIBILITY OF SUCH DAMAGE. 4826516Sbrian * ==================================================================== 4931061Sbrian * 5031690Sbrian * This product includes cryptographic software written by Eric Young 5131690Sbrian * (eay@cryptsoft.com). This product includes software written by Tim 5231690Sbrian * Hudson (tjh@cryptsoft.com). 5330715Sbrian * 546059Samurai */ 556059Samurai 566059Samurai/* NOTE: this file was auto generated by the mkerr.pl script: any changes 576059Samurai * made to it will be overwritten when the script next updates this file. 586059Samurai */ 596059Samurai 606059Samurai#include <stdio.h> 616059Samurai#include <openssl/err.h> 626059Samurai#include <openssl/pkcs7.h> 636059Samurai 646059Samurai/* BEGIN ERROR CODES */ 6528679Sbrian#ifndef NO_ERR 6628679Sbrianstatic ERR_STRING_DATA PKCS7_str_functs[]= 6728679Sbrian { 6832109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_ADD_CERTIFICATE,0), "PKCS7_add_certificate"}, 6932109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_ADD_CRL,0), "PKCS7_add_crl"}, 706059Samurai{ERR_PACK(0,PKCS7_F_PKCS7_ADD_RECIPIENT_INFO,0), "PKCS7_add_recipient_info"}, 716059Samurai{ERR_PACK(0,PKCS7_F_PKCS7_ADD_SIGNER,0), "PKCS7_add_signer"}, 726059Samurai{ERR_PACK(0,PKCS7_F_PKCS7_CTRL,0), "PKCS7_ctrl"}, 7331343Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_DATADECODE,0), "PKCS7_dataDecode"}, 7431343Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_DATAINIT,0), "PKCS7_dataInit"}, 756059Samurai{ERR_PACK(0,PKCS7_F_PKCS7_DATASIGN,0), "PKCS7_DATASIGN"}, 766059Samurai{ERR_PACK(0,PKCS7_F_PKCS7_DATAVERIFY,0), "PKCS7_dataVerify"}, 7732109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_SET_CIPHER,0), "PKCS7_set_cipher"}, 7832109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_SET_CONTENT,0), "PKCS7_set_content"}, 7932109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_SET_TYPE,0), "PKCS7_set_type"}, 8032109Sbrian{ERR_PACK(0,PKCS7_F_PKCS7_SIGNATUREVERIFY,0), "PKCS7_signatureVerify"}, 8131061Sbrian{0,NULL} 8227725Sbrian }; 8328974Sbrian 8427725Sbrianstatic ERR_STRING_DATA PKCS7_str_reasons[]= 8527725Sbrian { 8631962Sbrian{PKCS7_R_CIPHER_NOT_INITIALIZED ,"cipher not initialized"}, 876059Samurai{PKCS7_R_DECRYPTED_KEY_IS_WRONG_LENGTH ,"decrypted key is wrong length"}, 886059Samurai{PKCS7_R_DIGEST_FAILURE ,"digest failure"}, 8931598Sbrian{PKCS7_R_INTERNAL_ERROR ,"internal error"}, 906059Samurai{PKCS7_R_MISSING_CERIPEND_INFO ,"missing ceripend info"}, 916059Samurai{PKCS7_R_NO_RECIPIENT_MATCHES_CERTIFICATE,"no recipient matches certificate"}, 9217571Speter{PKCS7_R_OPERATION_NOT_SUPPORTED_ON_THIS_TYPE,"operation not supported on this type"}, 936059Samurai{PKCS7_R_SIGNATURE_FAILURE ,"signature failure"}, 9431962Sbrian{PKCS7_R_UNABLE_TO_FIND_CERTIFICATE ,"unable to find certificate"}, 956059Samurai{PKCS7_R_UNABLE_TO_FIND_MEM_BIO ,"unable to find mem bio"}, 966059Samurai{PKCS7_R_UNABLE_TO_FIND_MESSAGE_DIGEST ,"unable to find message digest"}, 976059Samurai{PKCS7_R_UNKNOWN_DIGEST_TYPE ,"unknown digest type"}, 986059Samurai{PKCS7_R_UNKNOWN_OPERATION ,"unknown operation"}, 996059Samurai{PKCS7_R_UNSUPPORTED_CIPHER_TYPE ,"unsupported cipher type"}, 1006059Samurai{PKCS7_R_UNSUPPORTED_CONTENT_TYPE ,"unsupported content type"}, 10130715Sbrian{PKCS7_R_WRONG_CONTENT_TYPE ,"wrong content type"}, 1026059Samurai{PKCS7_R_WRONG_PKCS7_TYPE ,"wrong pkcs7 type"}, 10331598Sbrian{0,NULL} 10431598Sbrian }; 10531598Sbrian 10631598Sbrian#endif 10731598Sbrian 10831598Sbrianvoid ERR_load_PKCS7_strings(void) 10931598Sbrian { 11031598Sbrian static int init=1; 11131598Sbrian 11231962Sbrian if (init) 11331598Sbrian { 11431598Sbrian init=0; 11531598Sbrian#ifndef NO_ERR 11631598Sbrian ERR_load_strings(ERR_LIB_PKCS7,PKCS7_str_functs); 11731598Sbrian ERR_load_strings(ERR_LIB_PKCS7,PKCS7_str_reasons); 11831598Sbrian#endif 11931962Sbrian 12031598Sbrian } 12131598Sbrian } 12231598Sbrian