fe081ddba8cb5facc9e36af2b0d5253fcfc4d72f
[openssl.git] / include / crypto / sm2err.h
1 /*
2  * Generated by util/mkerr.pl DO NOT EDIT
3  * Copyright 2020 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 #ifndef OSSL_CRYPTO_SM2ERR_H
12 # define OSSL_CRYPTO_SM2ERR_H
13 # pragma once
14
15 # include <openssl/opensslconf.h>
16 # include <openssl/symhacks.h>
17
18 # ifdef  __cplusplus
19 extern "C" {
20 # endif
21
22 # ifndef OPENSSL_NO_SM2
23
24 int err_load_SM2_strings_int(void);
25
26 /*
27  * SM2 function codes.
28  */
29 #  ifndef OPENSSL_NO_DEPRECATED_3_0
30 #   define SM2_F_PKEY_SM2_COPY                              0
31 #   define SM2_F_PKEY_SM2_CTRL                              0
32 #   define SM2_F_PKEY_SM2_CTRL_STR                          0
33 #   define SM2_F_PKEY_SM2_DIGEST_CUSTOM                     0
34 #   define SM2_F_PKEY_SM2_INIT                              0
35 #   define SM2_F_PKEY_SM2_SIGN                              0
36 #   define SM2_F_SM2_COMPUTE_MSG_HASH                       0
37 #   define SM2_F_SM2_COMPUTE_USERID_DIGEST                  0
38 #   define SM2_F_SM2_COMPUTE_Z_DIGEST                       0
39 #   define SM2_F_SM2_DECRYPT                                0
40 #   define SM2_F_SM2_ENCRYPT                                0
41 #   define SM2_F_SM2_INTERNAL_SIGN                          0
42 #   define SM2_F_SM2_INTERNAL_VERIFY                        0
43 #   define SM2_F_SM2_PLAINTEXT_SIZE                         0
44 #   define SM2_F_SM2_SIGN                                   0
45 #   define SM2_F_SM2_SIG_GEN                                0
46 #   define SM2_F_SM2_SIG_VERIFY                             0
47 #   define SM2_F_SM2_VERIFY                                 0
48 #  endif
49
50 /*
51  * SM2 reason codes.
52  */
53 #  define SM2_R_ASN1_ERROR                                 100
54 #  define SM2_R_BAD_SIGNATURE                              101
55 #  define SM2_R_BUFFER_TOO_SMALL                           107
56 #  define SM2_R_DIST_ID_TOO_LARGE                          110
57 #  define SM2_R_ID_NOT_SET                                 112
58 #  define SM2_R_ID_TOO_LARGE                               111
59 #  define SM2_R_INVALID_CURVE                              108
60 #  define SM2_R_INVALID_DIGEST                             102
61 #  define SM2_R_INVALID_DIGEST_TYPE                        103
62 #  define SM2_R_INVALID_ENCODING                           104
63 #  define SM2_R_INVALID_FIELD                              105
64 #  define SM2_R_INVALID_PRIVATE_KEY                        113
65 #  define SM2_R_NO_PARAMETERS_SET                          109
66 #  define SM2_R_USER_ID_TOO_LARGE                          106
67
68 # endif
69
70 # ifdef  __cplusplus
71 }
72 # endif
73 #endif