Download cpython_chunk_21.py from Ananthusajeev190/Python_codes_data: direct link, hf CLI and curl.
- Browser
- Download file 498 kB
-
https://huggingface.co/datasets/Ananthusajeev190/Python_codes_data/resolve/2df967223e88a90cd651f43981ca69c44191bf40/cpython_chunk_21.py
- Command line
-
hf download hf://datasets/Ananthusajeev190/Python_codes_data@2df967223e88a90cd651f43981ca69c44191bf40/cpython_chunk_21.py
-
curl -L -o cpython_chunk_21.py https://huggingface.co/datasets/Ananthusajeev190/Python_codes_data/resolve/2df967223e88a90cd651f43981ca69c44191bf40/cpython_chunk_21.py
498 kB
| # Auto-generated from cpython_chunk_21.txt | |
| TEXT_DATA = r""" | |
| /* File generated by Tools/ssl/make_ssl_data.py */ | |
| /* Generated on 2026-01-17T13:03:49.335767+00:00 */ | |
| /* Generated from Git commit openssl-3.6.0-0-g7b371d80d9 */ | |
| /* generated from args.lib2errnum */ | |
| static struct py_ssl_library_code library_codes[] = { | |
| #ifdef ERR_LIB_ASN1 | |
| {"ASN1", ERR_LIB_ASN1}, | |
| #endif | |
| #ifdef ERR_LIB_ASYNC | |
| {"ASYNC", ERR_LIB_ASYNC}, | |
| #endif | |
| #ifdef ERR_LIB_BIO | |
| {"BIO", ERR_LIB_BIO}, | |
| #endif | |
| #ifdef ERR_LIB_BN | |
| {"BN", ERR_LIB_BN}, | |
| #endif | |
| #ifdef ERR_LIB_BUF | |
| {"BUF", ERR_LIB_BUF}, | |
| #endif | |
| #ifdef ERR_LIB_CMP | |
| {"CMP", ERR_LIB_CMP}, | |
| #endif | |
| #ifdef ERR_LIB_CMS | |
| {"CMS", ERR_LIB_CMS}, | |
| #endif | |
| #ifdef ERR_LIB_COMP | |
| {"COMP", ERR_LIB_COMP}, | |
| #endif | |
| #ifdef ERR_LIB_CONF | |
| {"CONF", ERR_LIB_CONF}, | |
| #endif | |
| #ifdef ERR_LIB_CRMF | |
| {"CRMF", ERR_LIB_CRMF}, | |
| #endif | |
| #ifdef ERR_LIB_CRYPTO | |
| {"CRYPTO", ERR_LIB_CRYPTO}, | |
| #endif | |
| #ifdef ERR_LIB_CT | |
| {"CT", ERR_LIB_CT}, | |
| #endif | |
| #ifdef ERR_LIB_DH | |
| {"DH", ERR_LIB_DH}, | |
| #endif | |
| #ifdef ERR_LIB_DSA | |
| {"DSA", ERR_LIB_DSA}, | |
| #endif | |
| #ifdef ERR_LIB_DSO | |
| {"DSO", ERR_LIB_DSO}, | |
| #endif | |
| #ifdef ERR_LIB_EC | |
| {"EC", ERR_LIB_EC}, | |
| #endif | |
| #ifdef ERR_LIB_ECDH | |
| {"ECDH", ERR_LIB_ECDH}, | |
| #endif | |
| #ifdef ERR_LIB_ECDSA | |
| {"ECDSA", ERR_LIB_ECDSA}, | |
| #endif | |
| #ifdef ERR_LIB_ENGINE | |
| {"ENGINE", ERR_LIB_ENGINE}, | |
| #endif | |
| #ifdef ERR_LIB_ESS | |
| {"ESS", ERR_LIB_ESS}, | |
| #endif | |
| #ifdef ERR_LIB_EVP | |
| {"EVP", ERR_LIB_EVP}, | |
| #endif | |
| #ifdef ERR_LIB_FIPS | |
| {"FIPS", ERR_LIB_FIPS}, | |
| #endif | |
| #ifdef ERR_LIB_HMAC | |
| {"HMAC", ERR_LIB_HMAC}, | |
| #endif | |
| #ifdef ERR_LIB_HTTP | |
| {"HTTP", ERR_LIB_HTTP}, | |
| #endif | |
| #ifdef ERR_LIB_JPAKE | |
| {"JPAKE", ERR_LIB_JPAKE}, | |
| #endif | |
| #ifdef ERR_LIB_KDF | |
| {"KDF", ERR_LIB_KDF}, | |
| #endif | |
| #ifdef ERR_LIB_METH | |
| {"METH", ERR_LIB_METH}, | |
| #endif | |
| #ifdef ERR_LIB_NONE | |
| {"NONE", ERR_LIB_NONE}, | |
| #endif | |
| #ifdef ERR_LIB_OBJ | |
| {"OBJ", ERR_LIB_OBJ}, | |
| #endif | |
| #ifdef ERR_LIB_OCSP | |
| {"OCSP", ERR_LIB_OCSP}, | |
| #endif | |
| #ifdef ERR_LIB_OSSL_DECODER | |
| {"OSSL_DECODER", ERR_LIB_OSSL_DECODER}, | |
| #endif | |
| #ifdef ERR_LIB_OSSL_ENCODER | |
| {"OSSL_ENCODER", ERR_LIB_OSSL_ENCODER}, | |
| #endif | |
| #ifdef ERR_LIB_OSSL_STORE | |
| {"OSSL_STORE", ERR_LIB_OSSL_STORE}, | |
| #endif | |
| #ifdef ERR_LIB_PEM | |
| {"PEM", ERR_LIB_PEM}, | |
| #endif | |
| #ifdef ERR_LIB_PKCS12 | |
| {"PKCS12", ERR_LIB_PKCS12}, | |
| #endif | |
| #ifdef ERR_LIB_PKCS7 | |
| {"PKCS7", ERR_LIB_PKCS7}, | |
| #endif | |
| #ifdef ERR_LIB_PROP | |
| {"PROP", ERR_LIB_PROP}, | |
| #endif | |
| #ifdef ERR_LIB_PROV | |
| {"PROV", ERR_LIB_PROV}, | |
| #endif | |
| #ifdef ERR_LIB_PROXY | |
| {"PROXY", ERR_LIB_PROXY}, | |
| #endif | |
| #ifdef ERR_LIB_RAND | |
| {"RAND", ERR_LIB_RAND}, | |
| #endif | |
| #ifdef ERR_LIB_RSA | |
| {"RSA", ERR_LIB_RSA}, | |
| #endif | |
| #ifdef ERR_LIB_RSAREF | |
| {"RSAREF", ERR_LIB_RSAREF}, | |
| #endif | |
| #ifdef ERR_LIB_SM2 | |
| {"SM2", ERR_LIB_SM2}, | |
| #endif | |
| #ifdef ERR_LIB_SSL | |
| {"SSL", ERR_LIB_SSL}, | |
| #endif | |
| #ifdef ERR_LIB_SSL2 | |
| {"SSL2", ERR_LIB_SSL2}, | |
| #endif | |
| #ifdef ERR_LIB_SSL23 | |
| {"SSL23", ERR_LIB_SSL23}, | |
| #endif | |
| #ifdef ERR_LIB_SSL3 | |
| {"SSL3", ERR_LIB_SSL3}, | |
| #endif | |
| #ifdef ERR_LIB_SYS | |
| {"SYS", ERR_LIB_SYS}, | |
| #endif | |
| #ifdef ERR_LIB_TS | |
| {"TS", ERR_LIB_TS}, | |
| #endif | |
| #ifdef ERR_LIB_UI | |
| {"UI", ERR_LIB_UI}, | |
| #endif | |
| #ifdef ERR_LIB_USER | |
| {"USER", ERR_LIB_USER}, | |
| #endif | |
| #ifdef ERR_LIB_X509 | |
| {"X509", ERR_LIB_X509}, | |
| #endif | |
| #ifdef ERR_LIB_X509V3 | |
| {"X509V3", ERR_LIB_X509V3}, | |
| #endif | |
| {NULL, 0} /* sentinel */ | |
| }; | |
| /* generated from args.reasons */ | |
| static struct py_ssl_error_code error_codes[] = { | |
| #ifdef ASN1_R_ADDING_OBJECT | |
| {"ADDING_OBJECT", ERR_LIB_ASN1, ASN1_R_ADDING_OBJECT}, | |
| #else | |
| {"ADDING_OBJECT", 13, 171}, | |
| #endif | |
| #ifdef ASN1_R_ASN1_PARSE_ERROR | |
| {"ASN1_PARSE_ERROR", ERR_LIB_ASN1, ASN1_R_ASN1_PARSE_ERROR}, | |
| #else | |
| {"ASN1_PARSE_ERROR", 13, 203}, | |
| #endif | |
| #ifdef ASN1_R_ASN1_SIG_PARSE_ERROR | |
| {"ASN1_SIG_PARSE_ERROR", ERR_LIB_ASN1, ASN1_R_ASN1_SIG_PARSE_ERROR}, | |
| #else | |
| {"ASN1_SIG_PARSE_ERROR", 13, 204}, | |
| #endif | |
| #ifdef ASN1_R_AUX_ERROR | |
| {"AUX_ERROR", ERR_LIB_ASN1, ASN1_R_AUX_ERROR}, | |
| #else | |
| {"AUX_ERROR", 13, 100}, | |
| #endif | |
| #ifdef ASN1_R_BAD_OBJECT_HEADER | |
| {"BAD_OBJECT_HEADER", ERR_LIB_ASN1, ASN1_R_BAD_OBJECT_HEADER}, | |
| #else | |
| {"BAD_OBJECT_HEADER", 13, 102}, | |
| #endif | |
| #ifdef ASN1_R_BAD_TEMPLATE | |
| {"BAD_TEMPLATE", ERR_LIB_ASN1, ASN1_R_BAD_TEMPLATE}, | |
| #else | |
| {"BAD_TEMPLATE", 13, 230}, | |
| #endif | |
| #ifdef ASN1_R_BMPSTRING_IS_WRONG_LENGTH | |
| {"BMPSTRING_IS_WRONG_LENGTH", ERR_LIB_ASN1, ASN1_R_BMPSTRING_IS_WRONG_LENGTH}, | |
| #else | |
| {"BMPSTRING_IS_WRONG_LENGTH", 13, 214}, | |
| #endif | |
| #ifdef ASN1_R_BN_LIB | |
| {"BN_LIB", ERR_LIB_ASN1, ASN1_R_BN_LIB}, | |
| #else | |
| {"BN_LIB", 13, 105}, | |
| #endif | |
| #ifdef ASN1_R_BOOLEAN_IS_WRONG_LENGTH | |
| {"BOOLEAN_IS_WRONG_LENGTH", ERR_LIB_ASN1, ASN1_R_BOOLEAN_IS_WRONG_LENGTH}, | |
| #else | |
| {"BOOLEAN_IS_WRONG_LENGTH", 13, 106}, | |
| #endif | |
| #ifdef ASN1_R_BUFFER_TOO_SMALL | |
| {"BUFFER_TOO_SMALL", ERR_LIB_ASN1, ASN1_R_BUFFER_TOO_SMALL}, | |
| #else | |
| {"BUFFER_TOO_SMALL", 13, 107}, | |
| #endif | |
| #ifdef ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER | |
| {"CIPHER_HAS_NO_OBJECT_IDENTIFIER", ERR_LIB_ASN1, ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER}, | |
| #else | |
| {"CIPHER_HAS_NO_OBJECT_IDENTIFIER", 13, 108}, | |
| #endif | |
| #ifdef ASN1_R_CONTEXT_NOT_INITIALISED | |
| {"CONTEXT_NOT_INITIALISED", ERR_LIB_ASN1, ASN1_R_CONTEXT_NOT_INITIALISED}, | |
| #else | |
| {"CONTEXT_NOT_INITIALISED", 13, 217}, | |
| #endif | |
| #ifdef ASN1_R_DATA_IS_WRONG | |
| {"DATA_IS_WRONG", ERR_LIB_ASN1, ASN1_R_DATA_IS_WRONG}, | |
| #else | |
| {"DATA_IS_WRONG", 13, 109}, | |
| #endif | |
| #ifdef ASN1_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_ASN1, ASN1_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 13, 110}, | |
| #endif | |
| #ifdef ASN1_R_DEPTH_EXCEEDED | |
| {"DEPTH_EXCEEDED", ERR_LIB_ASN1, ASN1_R_DEPTH_EXCEEDED}, | |
| #else | |
| {"DEPTH_EXCEEDED", 13, 174}, | |
| #endif | |
| #ifdef ASN1_R_DIGEST_AND_KEY_TYPE_NOT_SUPPORTED | |
| {"DIGEST_AND_KEY_TYPE_NOT_SUPPORTED", ERR_LIB_ASN1, ASN1_R_DIGEST_AND_KEY_TYPE_NOT_SUPPORTED}, | |
| #else | |
| {"DIGEST_AND_KEY_TYPE_NOT_SUPPORTED", 13, 198}, | |
| #endif | |
| #ifdef ASN1_R_ENCODE_ERROR | |
| {"ENCODE_ERROR", ERR_LIB_ASN1, ASN1_R_ENCODE_ERROR}, | |
| #else | |
| {"ENCODE_ERROR", 13, 112}, | |
| #endif | |
| #ifdef ASN1_R_ERROR_GETTING_TIME | |
| {"ERROR_GETTING_TIME", ERR_LIB_ASN1, ASN1_R_ERROR_GETTING_TIME}, | |
| #else | |
| {"ERROR_GETTING_TIME", 13, 173}, | |
| #endif | |
| #ifdef ASN1_R_ERROR_LOADING_SECTION | |
| {"ERROR_LOADING_SECTION", ERR_LIB_ASN1, ASN1_R_ERROR_LOADING_SECTION}, | |
| #else | |
| {"ERROR_LOADING_SECTION", 13, 172}, | |
| #endif | |
| #ifdef ASN1_R_ERROR_SETTING_CIPHER_PARAMS | |
| {"ERROR_SETTING_CIPHER_PARAMS", ERR_LIB_ASN1, ASN1_R_ERROR_SETTING_CIPHER_PARAMS}, | |
| #else | |
| {"ERROR_SETTING_CIPHER_PARAMS", 13, 114}, | |
| #endif | |
| #ifdef ASN1_R_EXPECTING_AN_INTEGER | |
| {"EXPECTING_AN_INTEGER", ERR_LIB_ASN1, ASN1_R_EXPECTING_AN_INTEGER}, | |
| #else | |
| {"EXPECTING_AN_INTEGER", 13, 115}, | |
| #endif | |
| #ifdef ASN1_R_EXPECTING_AN_OBJECT | |
| {"EXPECTING_AN_OBJECT", ERR_LIB_ASN1, ASN1_R_EXPECTING_AN_OBJECT}, | |
| #else | |
| {"EXPECTING_AN_OBJECT", 13, 116}, | |
| #endif | |
| #ifdef ASN1_R_EXPLICIT_LENGTH_MISMATCH | |
| {"EXPLICIT_LENGTH_MISMATCH", ERR_LIB_ASN1, ASN1_R_EXPLICIT_LENGTH_MISMATCH}, | |
| #else | |
| {"EXPLICIT_LENGTH_MISMATCH", 13, 119}, | |
| #endif | |
| #ifdef ASN1_R_EXPLICIT_TAG_NOT_CONSTRUCTED | |
| {"EXPLICIT_TAG_NOT_CONSTRUCTED", ERR_LIB_ASN1, ASN1_R_EXPLICIT_TAG_NOT_CONSTRUCTED}, | |
| #else | |
| {"EXPLICIT_TAG_NOT_CONSTRUCTED", 13, 120}, | |
| #endif | |
| #ifdef ASN1_R_FIELD_MISSING | |
| {"FIELD_MISSING", ERR_LIB_ASN1, ASN1_R_FIELD_MISSING}, | |
| #else | |
| {"FIELD_MISSING", 13, 121}, | |
| #endif | |
| #ifdef ASN1_R_FIRST_NUM_TOO_LARGE | |
| {"FIRST_NUM_TOO_LARGE", ERR_LIB_ASN1, ASN1_R_FIRST_NUM_TOO_LARGE}, | |
| #else | |
| {"FIRST_NUM_TOO_LARGE", 13, 122}, | |
| #endif | |
| #ifdef ASN1_R_GENERALIZEDTIME_IS_TOO_SHORT | |
| {"GENERALIZEDTIME_IS_TOO_SHORT", ERR_LIB_ASN1, ASN1_R_GENERALIZEDTIME_IS_TOO_SHORT}, | |
| #else | |
| {"GENERALIZEDTIME_IS_TOO_SHORT", 13, 232}, | |
| #endif | |
| #ifdef ASN1_R_HEADER_TOO_LONG | |
| {"HEADER_TOO_LONG", ERR_LIB_ASN1, ASN1_R_HEADER_TOO_LONG}, | |
| #else | |
| {"HEADER_TOO_LONG", 13, 123}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_BITSTRING_FORMAT | |
| {"ILLEGAL_BITSTRING_FORMAT", ERR_LIB_ASN1, ASN1_R_ILLEGAL_BITSTRING_FORMAT}, | |
| #else | |
| {"ILLEGAL_BITSTRING_FORMAT", 13, 175}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_BOOLEAN | |
| {"ILLEGAL_BOOLEAN", ERR_LIB_ASN1, ASN1_R_ILLEGAL_BOOLEAN}, | |
| #else | |
| {"ILLEGAL_BOOLEAN", 13, 176}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_CHARACTERS | |
| {"ILLEGAL_CHARACTERS", ERR_LIB_ASN1, ASN1_R_ILLEGAL_CHARACTERS}, | |
| #else | |
| {"ILLEGAL_CHARACTERS", 13, 124}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_FORMAT | |
| {"ILLEGAL_FORMAT", ERR_LIB_ASN1, ASN1_R_ILLEGAL_FORMAT}, | |
| #else | |
| {"ILLEGAL_FORMAT", 13, 177}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_HEX | |
| {"ILLEGAL_HEX", ERR_LIB_ASN1, ASN1_R_ILLEGAL_HEX}, | |
| #else | |
| {"ILLEGAL_HEX", 13, 178}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_IMPLICIT_TAG | |
| {"ILLEGAL_IMPLICIT_TAG", ERR_LIB_ASN1, ASN1_R_ILLEGAL_IMPLICIT_TAG}, | |
| #else | |
| {"ILLEGAL_IMPLICIT_TAG", 13, 179}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_INTEGER | |
| {"ILLEGAL_INTEGER", ERR_LIB_ASN1, ASN1_R_ILLEGAL_INTEGER}, | |
| #else | |
| {"ILLEGAL_INTEGER", 13, 180}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_NEGATIVE_VALUE | |
| {"ILLEGAL_NEGATIVE_VALUE", ERR_LIB_ASN1, ASN1_R_ILLEGAL_NEGATIVE_VALUE}, | |
| #else | |
| {"ILLEGAL_NEGATIVE_VALUE", 13, 226}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_NESTED_TAGGING | |
| {"ILLEGAL_NESTED_TAGGING", ERR_LIB_ASN1, ASN1_R_ILLEGAL_NESTED_TAGGING}, | |
| #else | |
| {"ILLEGAL_NESTED_TAGGING", 13, 181}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_NULL | |
| {"ILLEGAL_NULL", ERR_LIB_ASN1, ASN1_R_ILLEGAL_NULL}, | |
| #else | |
| {"ILLEGAL_NULL", 13, 125}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_NULL_VALUE | |
| {"ILLEGAL_NULL_VALUE", ERR_LIB_ASN1, ASN1_R_ILLEGAL_NULL_VALUE}, | |
| #else | |
| {"ILLEGAL_NULL_VALUE", 13, 182}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_OBJECT | |
| {"ILLEGAL_OBJECT", ERR_LIB_ASN1, ASN1_R_ILLEGAL_OBJECT}, | |
| #else | |
| {"ILLEGAL_OBJECT", 13, 183}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_OPTIONAL_ANY | |
| {"ILLEGAL_OPTIONAL_ANY", ERR_LIB_ASN1, ASN1_R_ILLEGAL_OPTIONAL_ANY}, | |
| #else | |
| {"ILLEGAL_OPTIONAL_ANY", 13, 126}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_OPTIONS_ON_ITEM_TEMPLATE | |
| {"ILLEGAL_OPTIONS_ON_ITEM_TEMPLATE", ERR_LIB_ASN1, ASN1_R_ILLEGAL_OPTIONS_ON_ITEM_TEMPLATE}, | |
| #else | |
| {"ILLEGAL_OPTIONS_ON_ITEM_TEMPLATE", 13, 170}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_PADDING | |
| {"ILLEGAL_PADDING", ERR_LIB_ASN1, ASN1_R_ILLEGAL_PADDING}, | |
| #else | |
| {"ILLEGAL_PADDING", 13, 221}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_TAGGED_ANY | |
| {"ILLEGAL_TAGGED_ANY", ERR_LIB_ASN1, ASN1_R_ILLEGAL_TAGGED_ANY}, | |
| #else | |
| {"ILLEGAL_TAGGED_ANY", 13, 127}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_TIME_VALUE | |
| {"ILLEGAL_TIME_VALUE", ERR_LIB_ASN1, ASN1_R_ILLEGAL_TIME_VALUE}, | |
| #else | |
| {"ILLEGAL_TIME_VALUE", 13, 184}, | |
| #endif | |
| #ifdef ASN1_R_ILLEGAL_ZERO_CONTENT | |
| {"ILLEGAL_ZERO_CONTENT", ERR_LIB_ASN1, ASN1_R_ILLEGAL_ZERO_CONTENT}, | |
| #else | |
| {"ILLEGAL_ZERO_CONTENT", 13, 222}, | |
| #endif | |
| #ifdef ASN1_R_INTEGER_NOT_ASCII_FORMAT | |
| {"INTEGER_NOT_ASCII_FORMAT", ERR_LIB_ASN1, ASN1_R_INTEGER_NOT_ASCII_FORMAT}, | |
| #else | |
| {"INTEGER_NOT_ASCII_FORMAT", 13, 185}, | |
| #endif | |
| #ifdef ASN1_R_INTEGER_TOO_LARGE_FOR_LONG | |
| {"INTEGER_TOO_LARGE_FOR_LONG", ERR_LIB_ASN1, ASN1_R_INTEGER_TOO_LARGE_FOR_LONG}, | |
| #else | |
| {"INTEGER_TOO_LARGE_FOR_LONG", 13, 128}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_BIT_STRING_BITS_LEFT | |
| {"INVALID_BIT_STRING_BITS_LEFT", ERR_LIB_ASN1, ASN1_R_INVALID_BIT_STRING_BITS_LEFT}, | |
| #else | |
| {"INVALID_BIT_STRING_BITS_LEFT", 13, 220}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_BMPSTRING_LENGTH | |
| {"INVALID_BMPSTRING_LENGTH", ERR_LIB_ASN1, ASN1_R_INVALID_BMPSTRING_LENGTH}, | |
| #else | |
| {"INVALID_BMPSTRING_LENGTH", 13, 129}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_DIGIT | |
| {"INVALID_DIGIT", ERR_LIB_ASN1, ASN1_R_INVALID_DIGIT}, | |
| #else | |
| {"INVALID_DIGIT", 13, 130}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_MIME_TYPE | |
| {"INVALID_MIME_TYPE", ERR_LIB_ASN1, ASN1_R_INVALID_MIME_TYPE}, | |
| #else | |
| {"INVALID_MIME_TYPE", 13, 205}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_MODIFIER | |
| {"INVALID_MODIFIER", ERR_LIB_ASN1, ASN1_R_INVALID_MODIFIER}, | |
| #else | |
| {"INVALID_MODIFIER", 13, 186}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_NUMBER | |
| {"INVALID_NUMBER", ERR_LIB_ASN1, ASN1_R_INVALID_NUMBER}, | |
| #else | |
| {"INVALID_NUMBER", 13, 187}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_OBJECT_ENCODING | |
| {"INVALID_OBJECT_ENCODING", ERR_LIB_ASN1, ASN1_R_INVALID_OBJECT_ENCODING}, | |
| #else | |
| {"INVALID_OBJECT_ENCODING", 13, 216}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_SCRYPT_PARAMETERS | |
| {"INVALID_SCRYPT_PARAMETERS", ERR_LIB_ASN1, ASN1_R_INVALID_SCRYPT_PARAMETERS}, | |
| #else | |
| {"INVALID_SCRYPT_PARAMETERS", 13, 227}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_SEPARATOR | |
| {"INVALID_SEPARATOR", ERR_LIB_ASN1, ASN1_R_INVALID_SEPARATOR}, | |
| #else | |
| {"INVALID_SEPARATOR", 13, 131}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_STRING_TABLE_VALUE | |
| {"INVALID_STRING_TABLE_VALUE", ERR_LIB_ASN1, ASN1_R_INVALID_STRING_TABLE_VALUE}, | |
| #else | |
| {"INVALID_STRING_TABLE_VALUE", 13, 218}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_UNIVERSALSTRING_LENGTH | |
| {"INVALID_UNIVERSALSTRING_LENGTH", ERR_LIB_ASN1, ASN1_R_INVALID_UNIVERSALSTRING_LENGTH}, | |
| #else | |
| {"INVALID_UNIVERSALSTRING_LENGTH", 13, 133}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_UTF8STRING | |
| {"INVALID_UTF8STRING", ERR_LIB_ASN1, ASN1_R_INVALID_UTF8STRING}, | |
| #else | |
| {"INVALID_UTF8STRING", 13, 134}, | |
| #endif | |
| #ifdef ASN1_R_INVALID_VALUE | |
| {"INVALID_VALUE", ERR_LIB_ASN1, ASN1_R_INVALID_VALUE}, | |
| #else | |
| {"INVALID_VALUE", 13, 219}, | |
| #endif | |
| #ifdef ASN1_R_LENGTH_TOO_LONG | |
| {"LENGTH_TOO_LONG", ERR_LIB_ASN1, ASN1_R_LENGTH_TOO_LONG}, | |
| #else | |
| {"LENGTH_TOO_LONG", 13, 231}, | |
| #endif | |
| #ifdef ASN1_R_LIST_ERROR | |
| {"LIST_ERROR", ERR_LIB_ASN1, ASN1_R_LIST_ERROR}, | |
| #else | |
| {"LIST_ERROR", 13, 188}, | |
| #endif | |
| #ifdef ASN1_R_MIME_NO_CONTENT_TYPE | |
| {"MIME_NO_CONTENT_TYPE", ERR_LIB_ASN1, ASN1_R_MIME_NO_CONTENT_TYPE}, | |
| #else | |
| {"MIME_NO_CONTENT_TYPE", 13, 206}, | |
| #endif | |
| #ifdef ASN1_R_MIME_PARSE_ERROR | |
| {"MIME_PARSE_ERROR", ERR_LIB_ASN1, ASN1_R_MIME_PARSE_ERROR}, | |
| #else | |
| {"MIME_PARSE_ERROR", 13, 207}, | |
| #endif | |
| #ifdef ASN1_R_MIME_SIG_PARSE_ERROR | |
| {"MIME_SIG_PARSE_ERROR", ERR_LIB_ASN1, ASN1_R_MIME_SIG_PARSE_ERROR}, | |
| #else | |
| {"MIME_SIG_PARSE_ERROR", 13, 208}, | |
| #endif | |
| #ifdef ASN1_R_MISSING_EOC | |
| {"MISSING_EOC", ERR_LIB_ASN1, ASN1_R_MISSING_EOC}, | |
| #else | |
| {"MISSING_EOC", 13, 137}, | |
| #endif | |
| #ifdef ASN1_R_MISSING_SECOND_NUMBER | |
| {"MISSING_SECOND_NUMBER", ERR_LIB_ASN1, ASN1_R_MISSING_SECOND_NUMBER}, | |
| #else | |
| {"MISSING_SECOND_NUMBER", 13, 138}, | |
| #endif | |
| #ifdef ASN1_R_MISSING_VALUE | |
| {"MISSING_VALUE", ERR_LIB_ASN1, ASN1_R_MISSING_VALUE}, | |
| #else | |
| {"MISSING_VALUE", 13, 189}, | |
| #endif | |
| #ifdef ASN1_R_MSTRING_NOT_UNIVERSAL | |
| {"MSTRING_NOT_UNIVERSAL", ERR_LIB_ASN1, ASN1_R_MSTRING_NOT_UNIVERSAL}, | |
| #else | |
| {"MSTRING_NOT_UNIVERSAL", 13, 139}, | |
| #endif | |
| #ifdef ASN1_R_MSTRING_WRONG_TAG | |
| {"MSTRING_WRONG_TAG", ERR_LIB_ASN1, ASN1_R_MSTRING_WRONG_TAG}, | |
| #else | |
| {"MSTRING_WRONG_TAG", 13, 140}, | |
| #endif | |
| #ifdef ASN1_R_NESTED_ASN1_STRING | |
| {"NESTED_ASN1_STRING", ERR_LIB_ASN1, ASN1_R_NESTED_ASN1_STRING}, | |
| #else | |
| {"NESTED_ASN1_STRING", 13, 197}, | |
| #endif | |
| #ifdef ASN1_R_NESTED_TOO_DEEP | |
| {"NESTED_TOO_DEEP", ERR_LIB_ASN1, ASN1_R_NESTED_TOO_DEEP}, | |
| #else | |
| {"NESTED_TOO_DEEP", 13, 201}, | |
| #endif | |
| #ifdef ASN1_R_NON_HEX_CHARACTERS | |
| {"NON_HEX_CHARACTERS", ERR_LIB_ASN1, ASN1_R_NON_HEX_CHARACTERS}, | |
| #else | |
| {"NON_HEX_CHARACTERS", 13, 141}, | |
| #endif | |
| #ifdef ASN1_R_NOT_ASCII_FORMAT | |
| {"NOT_ASCII_FORMAT", ERR_LIB_ASN1, ASN1_R_NOT_ASCII_FORMAT}, | |
| #else | |
| {"NOT_ASCII_FORMAT", 13, 190}, | |
| #endif | |
| #ifdef ASN1_R_NOT_ENOUGH_DATA | |
| {"NOT_ENOUGH_DATA", ERR_LIB_ASN1, ASN1_R_NOT_ENOUGH_DATA}, | |
| #else | |
| {"NOT_ENOUGH_DATA", 13, 142}, | |
| #endif | |
| #ifdef ASN1_R_NO_CONTENT_TYPE | |
| {"NO_CONTENT_TYPE", ERR_LIB_ASN1, ASN1_R_NO_CONTENT_TYPE}, | |
| #else | |
| {"NO_CONTENT_TYPE", 13, 209}, | |
| #endif | |
| #ifdef ASN1_R_NO_MATCHING_CHOICE_TYPE | |
| {"NO_MATCHING_CHOICE_TYPE", ERR_LIB_ASN1, ASN1_R_NO_MATCHING_CHOICE_TYPE}, | |
| #else | |
| {"NO_MATCHING_CHOICE_TYPE", 13, 143}, | |
| #endif | |
| #ifdef ASN1_R_NO_MULTIPART_BODY_FAILURE | |
| {"NO_MULTIPART_BODY_FAILURE", ERR_LIB_ASN1, ASN1_R_NO_MULTIPART_BODY_FAILURE}, | |
| #else | |
| {"NO_MULTIPART_BODY_FAILURE", 13, 210}, | |
| #endif | |
| #ifdef ASN1_R_NO_MULTIPART_BOUNDARY | |
| {"NO_MULTIPART_BOUNDARY", ERR_LIB_ASN1, ASN1_R_NO_MULTIPART_BOUNDARY}, | |
| #else | |
| {"NO_MULTIPART_BOUNDARY", 13, 211}, | |
| #endif | |
| #ifdef ASN1_R_NO_SIG_CONTENT_TYPE | |
| {"NO_SIG_CONTENT_TYPE", ERR_LIB_ASN1, ASN1_R_NO_SIG_CONTENT_TYPE}, | |
| #else | |
| {"NO_SIG_CONTENT_TYPE", 13, 212}, | |
| #endif | |
| #ifdef ASN1_R_NULL_IS_WRONG_LENGTH | |
| {"NULL_IS_WRONG_LENGTH", ERR_LIB_ASN1, ASN1_R_NULL_IS_WRONG_LENGTH}, | |
| #else | |
| {"NULL_IS_WRONG_LENGTH", 13, 144}, | |
| #endif | |
| #ifdef ASN1_R_OBJECT_NOT_ASCII_FORMAT | |
| {"OBJECT_NOT_ASCII_FORMAT", ERR_LIB_ASN1, ASN1_R_OBJECT_NOT_ASCII_FORMAT}, | |
| #else | |
| {"OBJECT_NOT_ASCII_FORMAT", 13, 191}, | |
| #endif | |
| #ifdef ASN1_R_ODD_NUMBER_OF_CHARS | |
| {"ODD_NUMBER_OF_CHARS", ERR_LIB_ASN1, ASN1_R_ODD_NUMBER_OF_CHARS}, | |
| #else | |
| {"ODD_NUMBER_OF_CHARS", 13, 145}, | |
| #endif | |
| #ifdef ASN1_R_SECOND_NUMBER_TOO_LARGE | |
| {"SECOND_NUMBER_TOO_LARGE", ERR_LIB_ASN1, ASN1_R_SECOND_NUMBER_TOO_LARGE}, | |
| #else | |
| {"SECOND_NUMBER_TOO_LARGE", 13, 147}, | |
| #endif | |
| #ifdef ASN1_R_SEQUENCE_LENGTH_MISMATCH | |
| {"SEQUENCE_LENGTH_MISMATCH", ERR_LIB_ASN1, ASN1_R_SEQUENCE_LENGTH_MISMATCH}, | |
| #else | |
| {"SEQUENCE_LENGTH_MISMATCH", 13, 148}, | |
| #endif | |
| #ifdef ASN1_R_SEQUENCE_NOT_CONSTRUCTED | |
| {"SEQUENCE_NOT_CONSTRUCTED", ERR_LIB_ASN1, ASN1_R_SEQUENCE_NOT_CONSTRUCTED}, | |
| #else | |
| {"SEQUENCE_NOT_CONSTRUCTED", 13, 149}, | |
| #endif | |
| #ifdef ASN1_R_SEQUENCE_OR_SET_NEEDS_CONFIG | |
| {"SEQUENCE_OR_SET_NEEDS_CONFIG", ERR_LIB_ASN1, ASN1_R_SEQUENCE_OR_SET_NEEDS_CONFIG}, | |
| #else | |
| {"SEQUENCE_OR_SET_NEEDS_CONFIG", 13, 192}, | |
| #endif | |
| #ifdef ASN1_R_SHORT_LINE | |
| {"SHORT_LINE", ERR_LIB_ASN1, ASN1_R_SHORT_LINE}, | |
| #else | |
| {"SHORT_LINE", 13, 150}, | |
| #endif | |
| #ifdef ASN1_R_SIG_INVALID_MIME_TYPE | |
| {"SIG_INVALID_MIME_TYPE", ERR_LIB_ASN1, ASN1_R_SIG_INVALID_MIME_TYPE}, | |
| #else | |
| {"SIG_INVALID_MIME_TYPE", 13, 213}, | |
| #endif | |
| #ifdef ASN1_R_STREAMING_NOT_SUPPORTED | |
| {"STREAMING_NOT_SUPPORTED", ERR_LIB_ASN1, ASN1_R_STREAMING_NOT_SUPPORTED}, | |
| #else | |
| {"STREAMING_NOT_SUPPORTED", 13, 202}, | |
| #endif | |
| #ifdef ASN1_R_STRING_TOO_LONG | |
| {"STRING_TOO_LONG", ERR_LIB_ASN1, ASN1_R_STRING_TOO_LONG}, | |
| #else | |
| {"STRING_TOO_LONG", 13, 151}, | |
| #endif | |
| #ifdef ASN1_R_STRING_TOO_SHORT | |
| {"STRING_TOO_SHORT", ERR_LIB_ASN1, ASN1_R_STRING_TOO_SHORT}, | |
| #else | |
| {"STRING_TOO_SHORT", 13, 152}, | |
| #endif | |
| #ifdef ASN1_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD | |
| {"THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD", ERR_LIB_ASN1, ASN1_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD}, | |
| #else | |
| {"THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD", 13, 154}, | |
| #endif | |
| #ifdef ASN1_R_TIME_NOT_ASCII_FORMAT | |
| {"TIME_NOT_ASCII_FORMAT", ERR_LIB_ASN1, ASN1_R_TIME_NOT_ASCII_FORMAT}, | |
| #else | |
| {"TIME_NOT_ASCII_FORMAT", 13, 193}, | |
| #endif | |
| #ifdef ASN1_R_TOO_LARGE | |
| {"TOO_LARGE", ERR_LIB_ASN1, ASN1_R_TOO_LARGE}, | |
| #else | |
| {"TOO_LARGE", 13, 223}, | |
| #endif | |
| #ifdef ASN1_R_TOO_LONG | |
| {"TOO_LONG", ERR_LIB_ASN1, ASN1_R_TOO_LONG}, | |
| #else | |
| {"TOO_LONG", 13, 155}, | |
| #endif | |
| #ifdef ASN1_R_TOO_SMALL | |
| {"TOO_SMALL", ERR_LIB_ASN1, ASN1_R_TOO_SMALL}, | |
| #else | |
| {"TOO_SMALL", 13, 224}, | |
| #endif | |
| #ifdef ASN1_R_TYPE_NOT_CONSTRUCTED | |
| {"TYPE_NOT_CONSTRUCTED", ERR_LIB_ASN1, ASN1_R_TYPE_NOT_CONSTRUCTED}, | |
| #else | |
| {"TYPE_NOT_CONSTRUCTED", 13, 156}, | |
| #endif | |
| #ifdef ASN1_R_TYPE_NOT_PRIMITIVE | |
| {"TYPE_NOT_PRIMITIVE", ERR_LIB_ASN1, ASN1_R_TYPE_NOT_PRIMITIVE}, | |
| #else | |
| {"TYPE_NOT_PRIMITIVE", 13, 195}, | |
| #endif | |
| #ifdef ASN1_R_UNEXPECTED_EOC | |
| {"UNEXPECTED_EOC", ERR_LIB_ASN1, ASN1_R_UNEXPECTED_EOC}, | |
| #else | |
| {"UNEXPECTED_EOC", 13, 159}, | |
| #endif | |
| #ifdef ASN1_R_UNIVERSALSTRING_IS_WRONG_LENGTH | |
| {"UNIVERSALSTRING_IS_WRONG_LENGTH", ERR_LIB_ASN1, ASN1_R_UNIVERSALSTRING_IS_WRONG_LENGTH}, | |
| #else | |
| {"UNIVERSALSTRING_IS_WRONG_LENGTH", 13, 215}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_DIGEST | |
| {"UNKNOWN_DIGEST", ERR_LIB_ASN1, ASN1_R_UNKNOWN_DIGEST}, | |
| #else | |
| {"UNKNOWN_DIGEST", 13, 229}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_FORMAT | |
| {"UNKNOWN_FORMAT", ERR_LIB_ASN1, ASN1_R_UNKNOWN_FORMAT}, | |
| #else | |
| {"UNKNOWN_FORMAT", 13, 160}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM | |
| {"UNKNOWN_MESSAGE_DIGEST_ALGORITHM", ERR_LIB_ASN1, ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_MESSAGE_DIGEST_ALGORITHM", 13, 161}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_OBJECT_TYPE | |
| {"UNKNOWN_OBJECT_TYPE", ERR_LIB_ASN1, ASN1_R_UNKNOWN_OBJECT_TYPE}, | |
| #else | |
| {"UNKNOWN_OBJECT_TYPE", 13, 162}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_PUBLIC_KEY_TYPE | |
| {"UNKNOWN_PUBLIC_KEY_TYPE", ERR_LIB_ASN1, ASN1_R_UNKNOWN_PUBLIC_KEY_TYPE}, | |
| #else | |
| {"UNKNOWN_PUBLIC_KEY_TYPE", 13, 163}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_SIGNATURE_ALGORITHM | |
| {"UNKNOWN_SIGNATURE_ALGORITHM", ERR_LIB_ASN1, ASN1_R_UNKNOWN_SIGNATURE_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_SIGNATURE_ALGORITHM", 13, 199}, | |
| #endif | |
| #ifdef ASN1_R_UNKNOWN_TAG | |
| {"UNKNOWN_TAG", ERR_LIB_ASN1, ASN1_R_UNKNOWN_TAG}, | |
| #else | |
| {"UNKNOWN_TAG", 13, 194}, | |
| #endif | |
| #ifdef ASN1_R_UNSUPPORTED_ANY_DEFINED_BY_TYPE | |
| {"UNSUPPORTED_ANY_DEFINED_BY_TYPE", ERR_LIB_ASN1, ASN1_R_UNSUPPORTED_ANY_DEFINED_BY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_ANY_DEFINED_BY_TYPE", 13, 164}, | |
| #endif | |
| #ifdef ASN1_R_UNSUPPORTED_CIPHER | |
| {"UNSUPPORTED_CIPHER", ERR_LIB_ASN1, ASN1_R_UNSUPPORTED_CIPHER}, | |
| #else | |
| {"UNSUPPORTED_CIPHER", 13, 228}, | |
| #endif | |
| #ifdef ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE | |
| {"UNSUPPORTED_PUBLIC_KEY_TYPE", ERR_LIB_ASN1, ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_PUBLIC_KEY_TYPE", 13, 167}, | |
| #endif | |
| #ifdef ASN1_R_UNSUPPORTED_TYPE | |
| {"UNSUPPORTED_TYPE", ERR_LIB_ASN1, ASN1_R_UNSUPPORTED_TYPE}, | |
| #else | |
| {"UNSUPPORTED_TYPE", 13, 196}, | |
| #endif | |
| #ifdef ASN1_R_UTCTIME_IS_TOO_SHORT | |
| {"UTCTIME_IS_TOO_SHORT", ERR_LIB_ASN1, ASN1_R_UTCTIME_IS_TOO_SHORT}, | |
| #else | |
| {"UTCTIME_IS_TOO_SHORT", 13, 233}, | |
| #endif | |
| #ifdef ASN1_R_WRONG_INTEGER_TYPE | |
| {"WRONG_INTEGER_TYPE", ERR_LIB_ASN1, ASN1_R_WRONG_INTEGER_TYPE}, | |
| #else | |
| {"WRONG_INTEGER_TYPE", 13, 225}, | |
| #endif | |
| #ifdef ASN1_R_WRONG_PUBLIC_KEY_TYPE | |
| {"WRONG_PUBLIC_KEY_TYPE", ERR_LIB_ASN1, ASN1_R_WRONG_PUBLIC_KEY_TYPE}, | |
| #else | |
| {"WRONG_PUBLIC_KEY_TYPE", 13, 200}, | |
| #endif | |
| #ifdef ASN1_R_WRONG_TAG | |
| {"WRONG_TAG", ERR_LIB_ASN1, ASN1_R_WRONG_TAG}, | |
| #else | |
| {"WRONG_TAG", 13, 168}, | |
| #endif | |
| #ifdef ASYNC_R_FAILED_TO_SET_POOL | |
| {"FAILED_TO_SET_POOL", ERR_LIB_ASYNC, ASYNC_R_FAILED_TO_SET_POOL}, | |
| #else | |
| {"FAILED_TO_SET_POOL", 51, 101}, | |
| #endif | |
| #ifdef ASYNC_R_FAILED_TO_SWAP_CONTEXT | |
| {"FAILED_TO_SWAP_CONTEXT", ERR_LIB_ASYNC, ASYNC_R_FAILED_TO_SWAP_CONTEXT}, | |
| #else | |
| {"FAILED_TO_SWAP_CONTEXT", 51, 102}, | |
| #endif | |
| #ifdef ASYNC_R_INIT_FAILED | |
| {"INIT_FAILED", ERR_LIB_ASYNC, ASYNC_R_INIT_FAILED}, | |
| #else | |
| {"INIT_FAILED", 51, 105}, | |
| #endif | |
| #ifdef ASYNC_R_INVALID_POOL_SIZE | |
| {"INVALID_POOL_SIZE", ERR_LIB_ASYNC, ASYNC_R_INVALID_POOL_SIZE}, | |
| #else | |
| {"INVALID_POOL_SIZE", 51, 103}, | |
| #endif | |
| #ifdef BIO_R_ACCEPT_ERROR | |
| {"ACCEPT_ERROR", ERR_LIB_BIO, BIO_R_ACCEPT_ERROR}, | |
| #else | |
| {"ACCEPT_ERROR", 32, 100}, | |
| #endif | |
| #ifdef BIO_R_ADDRINFO_ADDR_IS_NOT_AF_INET | |
| {"ADDRINFO_ADDR_IS_NOT_AF_INET", ERR_LIB_BIO, BIO_R_ADDRINFO_ADDR_IS_NOT_AF_INET}, | |
| #else | |
| {"ADDRINFO_ADDR_IS_NOT_AF_INET", 32, 141}, | |
| #endif | |
| #ifdef BIO_R_AMBIGUOUS_HOST_OR_SERVICE | |
| {"AMBIGUOUS_HOST_OR_SERVICE", ERR_LIB_BIO, BIO_R_AMBIGUOUS_HOST_OR_SERVICE}, | |
| #else | |
| {"AMBIGUOUS_HOST_OR_SERVICE", 32, 129}, | |
| #endif | |
| #ifdef BIO_R_BAD_FOPEN_MODE | |
| {"BAD_FOPEN_MODE", ERR_LIB_BIO, BIO_R_BAD_FOPEN_MODE}, | |
| #else | |
| {"BAD_FOPEN_MODE", 32, 101}, | |
| #endif | |
| #ifdef BIO_R_BROKEN_PIPE | |
| {"BROKEN_PIPE", ERR_LIB_BIO, BIO_R_BROKEN_PIPE}, | |
| #else | |
| {"BROKEN_PIPE", 32, 124}, | |
| #endif | |
| #ifdef BIO_R_CONNECT_ERROR | |
| {"CONNECT_ERROR", ERR_LIB_BIO, BIO_R_CONNECT_ERROR}, | |
| #else | |
| {"CONNECT_ERROR", 32, 103}, | |
| #endif | |
| #ifdef BIO_R_CONNECT_TIMEOUT | |
| {"CONNECT_TIMEOUT", ERR_LIB_BIO, BIO_R_CONNECT_TIMEOUT}, | |
| #else | |
| {"CONNECT_TIMEOUT", 32, 147}, | |
| #endif | |
| #ifdef BIO_R_GETHOSTBYNAME_ADDR_IS_NOT_AF_INET | |
| {"GETHOSTBYNAME_ADDR_IS_NOT_AF_INET", ERR_LIB_BIO, BIO_R_GETHOSTBYNAME_ADDR_IS_NOT_AF_INET}, | |
| #else | |
| {"GETHOSTBYNAME_ADDR_IS_NOT_AF_INET", 32, 107}, | |
| #endif | |
| #ifdef BIO_R_GETSOCKNAME_ERROR | |
| {"GETSOCKNAME_ERROR", ERR_LIB_BIO, BIO_R_GETSOCKNAME_ERROR}, | |
| #else | |
| {"GETSOCKNAME_ERROR", 32, 132}, | |
| #endif | |
| #ifdef BIO_R_GETSOCKNAME_TRUNCATED_ADDRESS | |
| {"GETSOCKNAME_TRUNCATED_ADDRESS", ERR_LIB_BIO, BIO_R_GETSOCKNAME_TRUNCATED_ADDRESS}, | |
| #else | |
| {"GETSOCKNAME_TRUNCATED_ADDRESS", 32, 133}, | |
| #endif | |
| #ifdef BIO_R_GETTING_SOCKTYPE | |
| {"GETTING_SOCKTYPE", ERR_LIB_BIO, BIO_R_GETTING_SOCKTYPE}, | |
| #else | |
| {"GETTING_SOCKTYPE", 32, 134}, | |
| #endif | |
| #ifdef BIO_R_INVALID_ARGUMENT | |
| {"INVALID_ARGUMENT", ERR_LIB_BIO, BIO_R_INVALID_ARGUMENT}, | |
| #else | |
| {"INVALID_ARGUMENT", 32, 125}, | |
| #endif | |
| #ifdef BIO_R_INVALID_SOCKET | |
| {"INVALID_SOCKET", ERR_LIB_BIO, BIO_R_INVALID_SOCKET}, | |
| #else | |
| {"INVALID_SOCKET", 32, 135}, | |
| #endif | |
| #ifdef BIO_R_IN_USE | |
| {"IN_USE", ERR_LIB_BIO, BIO_R_IN_USE}, | |
| #else | |
| {"IN_USE", 32, 123}, | |
| #endif | |
| #ifdef BIO_R_LENGTH_TOO_LONG | |
| {"LENGTH_TOO_LONG", ERR_LIB_BIO, BIO_R_LENGTH_TOO_LONG}, | |
| #else | |
| {"LENGTH_TOO_LONG", 32, 102}, | |
| #endif | |
| #ifdef BIO_R_LISTEN_V6_ONLY | |
| {"LISTEN_V6_ONLY", ERR_LIB_BIO, BIO_R_LISTEN_V6_ONLY}, | |
| #else | |
| {"LISTEN_V6_ONLY", 32, 136}, | |
| #endif | |
| #ifdef BIO_R_LOCAL_ADDR_NOT_AVAILABLE | |
| {"LOCAL_ADDR_NOT_AVAILABLE", ERR_LIB_BIO, BIO_R_LOCAL_ADDR_NOT_AVAILABLE}, | |
| #else | |
| {"LOCAL_ADDR_NOT_AVAILABLE", 32, 111}, | |
| #endif | |
| #ifdef BIO_R_LOOKUP_RETURNED_NOTHING | |
| {"LOOKUP_RETURNED_NOTHING", ERR_LIB_BIO, BIO_R_LOOKUP_RETURNED_NOTHING}, | |
| #else | |
| {"LOOKUP_RETURNED_NOTHING", 32, 142}, | |
| #endif | |
| #ifdef BIO_R_MALFORMED_HOST_OR_SERVICE | |
| {"MALFORMED_HOST_OR_SERVICE", ERR_LIB_BIO, BIO_R_MALFORMED_HOST_OR_SERVICE}, | |
| #else | |
| {"MALFORMED_HOST_OR_SERVICE", 32, 130}, | |
| #endif | |
| #ifdef BIO_R_NBIO_CONNECT_ERROR | |
| {"NBIO_CONNECT_ERROR", ERR_LIB_BIO, BIO_R_NBIO_CONNECT_ERROR}, | |
| #else | |
| {"NBIO_CONNECT_ERROR", 32, 110}, | |
| #endif | |
| #ifdef BIO_R_NON_FATAL | |
| {"NON_FATAL", ERR_LIB_BIO, BIO_R_NON_FATAL}, | |
| #else | |
| {"NON_FATAL", 32, 112}, | |
| #endif | |
| #ifdef BIO_R_NO_ACCEPT_ADDR_OR_SERVICE_SPECIFIED | |
| {"NO_ACCEPT_ADDR_OR_SERVICE_SPECIFIED", ERR_LIB_BIO, BIO_R_NO_ACCEPT_ADDR_OR_SERVICE_SPECIFIED}, | |
| #else | |
| {"NO_ACCEPT_ADDR_OR_SERVICE_SPECIFIED", 32, 143}, | |
| #endif | |
| #ifdef BIO_R_NO_HOSTNAME_OR_SERVICE_SPECIFIED | |
| {"NO_HOSTNAME_OR_SERVICE_SPECIFIED", ERR_LIB_BIO, BIO_R_NO_HOSTNAME_OR_SERVICE_SPECIFIED}, | |
| #else | |
| {"NO_HOSTNAME_OR_SERVICE_SPECIFIED", 32, 144}, | |
| #endif | |
| #ifdef BIO_R_NO_PORT_DEFINED | |
| {"NO_PORT_DEFINED", ERR_LIB_BIO, BIO_R_NO_PORT_DEFINED}, | |
| #else | |
| {"NO_PORT_DEFINED", 32, 113}, | |
| #endif | |
| #ifdef BIO_R_NO_SUCH_FILE | |
| {"NO_SUCH_FILE", ERR_LIB_BIO, BIO_R_NO_SUCH_FILE}, | |
| #else | |
| {"NO_SUCH_FILE", 32, 128}, | |
| #endif | |
| #ifdef BIO_R_PEER_ADDR_NOT_AVAILABLE | |
| {"PEER_ADDR_NOT_AVAILABLE", ERR_LIB_BIO, BIO_R_PEER_ADDR_NOT_AVAILABLE}, | |
| #else | |
| {"PEER_ADDR_NOT_AVAILABLE", 32, 114}, | |
| #endif | |
| #ifdef BIO_R_PORT_MISMATCH | |
| {"PORT_MISMATCH", ERR_LIB_BIO, BIO_R_PORT_MISMATCH}, | |
| #else | |
| {"PORT_MISMATCH", 32, 150}, | |
| #endif | |
| #ifdef BIO_R_TFO_DISABLED | |
| {"TFO_DISABLED", ERR_LIB_BIO, BIO_R_TFO_DISABLED}, | |
| #else | |
| {"TFO_DISABLED", 32, 106}, | |
| #endif | |
| #ifdef BIO_R_TFO_NO_KERNEL_SUPPORT | |
| {"TFO_NO_KERNEL_SUPPORT", ERR_LIB_BIO, BIO_R_TFO_NO_KERNEL_SUPPORT}, | |
| #else | |
| {"TFO_NO_KERNEL_SUPPORT", 32, 108}, | |
| #endif | |
| #ifdef BIO_R_TRANSFER_ERROR | |
| {"TRANSFER_ERROR", ERR_LIB_BIO, BIO_R_TRANSFER_ERROR}, | |
| #else | |
| {"TRANSFER_ERROR", 32, 104}, | |
| #endif | |
| #ifdef BIO_R_TRANSFER_TIMEOUT | |
| {"TRANSFER_TIMEOUT", ERR_LIB_BIO, BIO_R_TRANSFER_TIMEOUT}, | |
| #else | |
| {"TRANSFER_TIMEOUT", 32, 105}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_BIND_SOCKET | |
| {"UNABLE_TO_BIND_SOCKET", ERR_LIB_BIO, BIO_R_UNABLE_TO_BIND_SOCKET}, | |
| #else | |
| {"UNABLE_TO_BIND_SOCKET", 32, 117}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_CREATE_SOCKET | |
| {"UNABLE_TO_CREATE_SOCKET", ERR_LIB_BIO, BIO_R_UNABLE_TO_CREATE_SOCKET}, | |
| #else | |
| {"UNABLE_TO_CREATE_SOCKET", 32, 118}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_KEEPALIVE | |
| {"UNABLE_TO_KEEPALIVE", ERR_LIB_BIO, BIO_R_UNABLE_TO_KEEPALIVE}, | |
| #else | |
| {"UNABLE_TO_KEEPALIVE", 32, 137}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_LISTEN_SOCKET | |
| {"UNABLE_TO_LISTEN_SOCKET", ERR_LIB_BIO, BIO_R_UNABLE_TO_LISTEN_SOCKET}, | |
| #else | |
| {"UNABLE_TO_LISTEN_SOCKET", 32, 119}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_NODELAY | |
| {"UNABLE_TO_NODELAY", ERR_LIB_BIO, BIO_R_UNABLE_TO_NODELAY}, | |
| #else | |
| {"UNABLE_TO_NODELAY", 32, 138}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_REUSEADDR | |
| {"UNABLE_TO_REUSEADDR", ERR_LIB_BIO, BIO_R_UNABLE_TO_REUSEADDR}, | |
| #else | |
| {"UNABLE_TO_REUSEADDR", 32, 139}, | |
| #endif | |
| #ifdef BIO_R_UNABLE_TO_TFO | |
| {"UNABLE_TO_TFO", ERR_LIB_BIO, BIO_R_UNABLE_TO_TFO}, | |
| #else | |
| {"UNABLE_TO_TFO", 32, 109}, | |
| #endif | |
| #ifdef BIO_R_UNAVAILABLE_IP_FAMILY | |
| {"UNAVAILABLE_IP_FAMILY", ERR_LIB_BIO, BIO_R_UNAVAILABLE_IP_FAMILY}, | |
| #else | |
| {"UNAVAILABLE_IP_FAMILY", 32, 145}, | |
| #endif | |
| #ifdef BIO_R_UNINITIALIZED | |
| {"UNINITIALIZED", ERR_LIB_BIO, BIO_R_UNINITIALIZED}, | |
| #else | |
| {"UNINITIALIZED", 32, 120}, | |
| #endif | |
| #ifdef BIO_R_UNKNOWN_INFO_TYPE | |
| {"UNKNOWN_INFO_TYPE", ERR_LIB_BIO, BIO_R_UNKNOWN_INFO_TYPE}, | |
| #else | |
| {"UNKNOWN_INFO_TYPE", 32, 140}, | |
| #endif | |
| #ifdef BIO_R_UNSUPPORTED_IP_FAMILY | |
| {"UNSUPPORTED_IP_FAMILY", ERR_LIB_BIO, BIO_R_UNSUPPORTED_IP_FAMILY}, | |
| #else | |
| {"UNSUPPORTED_IP_FAMILY", 32, 146}, | |
| #endif | |
| #ifdef BIO_R_UNSUPPORTED_METHOD | |
| {"UNSUPPORTED_METHOD", ERR_LIB_BIO, BIO_R_UNSUPPORTED_METHOD}, | |
| #else | |
| {"UNSUPPORTED_METHOD", 32, 121}, | |
| #endif | |
| #ifdef BIO_R_UNSUPPORTED_PROTOCOL_FAMILY | |
| {"UNSUPPORTED_PROTOCOL_FAMILY", ERR_LIB_BIO, BIO_R_UNSUPPORTED_PROTOCOL_FAMILY}, | |
| #else | |
| {"UNSUPPORTED_PROTOCOL_FAMILY", 32, 131}, | |
| #endif | |
| #ifdef BIO_R_WRITE_TO_READ_ONLY_BIO | |
| {"WRITE_TO_READ_ONLY_BIO", ERR_LIB_BIO, BIO_R_WRITE_TO_READ_ONLY_BIO}, | |
| #else | |
| {"WRITE_TO_READ_ONLY_BIO", 32, 126}, | |
| #endif | |
| #ifdef BIO_R_WSASTARTUP | |
| {"WSASTARTUP", ERR_LIB_BIO, BIO_R_WSASTARTUP}, | |
| #else | |
| {"WSASTARTUP", 32, 122}, | |
| #endif | |
| #ifdef BN_R_ARG2_LT_ARG3 | |
| {"ARG2_LT_ARG3", ERR_LIB_BN, BN_R_ARG2_LT_ARG3}, | |
| #else | |
| {"ARG2_LT_ARG3", 3, 100}, | |
| #endif | |
| #ifdef BN_R_BAD_RECIPROCAL | |
| {"BAD_RECIPROCAL", ERR_LIB_BN, BN_R_BAD_RECIPROCAL}, | |
| #else | |
| {"BAD_RECIPROCAL", 3, 101}, | |
| #endif | |
| #ifdef BN_R_BIGNUM_TOO_LONG | |
| {"BIGNUM_TOO_LONG", ERR_LIB_BN, BN_R_BIGNUM_TOO_LONG}, | |
| #else | |
| {"BIGNUM_TOO_LONG", 3, 114}, | |
| #endif | |
| #ifdef BN_R_BITS_TOO_SMALL | |
| {"BITS_TOO_SMALL", ERR_LIB_BN, BN_R_BITS_TOO_SMALL}, | |
| #else | |
| {"BITS_TOO_SMALL", 3, 118}, | |
| #endif | |
| #ifdef BN_R_CALLED_WITH_EVEN_MODULUS | |
| {"CALLED_WITH_EVEN_MODULUS", ERR_LIB_BN, BN_R_CALLED_WITH_EVEN_MODULUS}, | |
| #else | |
| {"CALLED_WITH_EVEN_MODULUS", 3, 102}, | |
| #endif | |
| #ifdef BN_R_DIV_BY_ZERO | |
| {"DIV_BY_ZERO", ERR_LIB_BN, BN_R_DIV_BY_ZERO}, | |
| #else | |
| {"DIV_BY_ZERO", 3, 103}, | |
| #endif | |
| #ifdef BN_R_ENCODING_ERROR | |
| {"ENCODING_ERROR", ERR_LIB_BN, BN_R_ENCODING_ERROR}, | |
| #else | |
| {"ENCODING_ERROR", 3, 104}, | |
| #endif | |
| #ifdef BN_R_EXPAND_ON_STATIC_BIGNUM_DATA | |
| {"EXPAND_ON_STATIC_BIGNUM_DATA", ERR_LIB_BN, BN_R_EXPAND_ON_STATIC_BIGNUM_DATA}, | |
| #else | |
| {"EXPAND_ON_STATIC_BIGNUM_DATA", 3, 105}, | |
| #endif | |
| #ifdef BN_R_INPUT_NOT_REDUCED | |
| {"INPUT_NOT_REDUCED", ERR_LIB_BN, BN_R_INPUT_NOT_REDUCED}, | |
| #else | |
| {"INPUT_NOT_REDUCED", 3, 110}, | |
| #endif | |
| #ifdef BN_R_INVALID_LENGTH | |
| {"INVALID_LENGTH", ERR_LIB_BN, BN_R_INVALID_LENGTH}, | |
| #else | |
| {"INVALID_LENGTH", 3, 106}, | |
| #endif | |
| #ifdef BN_R_INVALID_RANGE | |
| {"INVALID_RANGE", ERR_LIB_BN, BN_R_INVALID_RANGE}, | |
| #else | |
| {"INVALID_RANGE", 3, 115}, | |
| #endif | |
| #ifdef BN_R_INVALID_SHIFT | |
| {"INVALID_SHIFT", ERR_LIB_BN, BN_R_INVALID_SHIFT}, | |
| #else | |
| {"INVALID_SHIFT", 3, 119}, | |
| #endif | |
| #ifdef BN_R_NOT_A_SQUARE | |
| {"NOT_A_SQUARE", ERR_LIB_BN, BN_R_NOT_A_SQUARE}, | |
| #else | |
| {"NOT_A_SQUARE", 3, 111}, | |
| #endif | |
| #ifdef BN_R_NOT_INITIALIZED | |
| {"NOT_INITIALIZED", ERR_LIB_BN, BN_R_NOT_INITIALIZED}, | |
| #else | |
| {"NOT_INITIALIZED", 3, 107}, | |
| #endif | |
| #ifdef BN_R_NO_INVERSE | |
| {"NO_INVERSE", ERR_LIB_BN, BN_R_NO_INVERSE}, | |
| #else | |
| {"NO_INVERSE", 3, 108}, | |
| #endif | |
| #ifdef BN_R_NO_PRIME_CANDIDATE | |
| {"NO_PRIME_CANDIDATE", ERR_LIB_BN, BN_R_NO_PRIME_CANDIDATE}, | |
| #else | |
| {"NO_PRIME_CANDIDATE", 3, 121}, | |
| #endif | |
| #ifdef BN_R_NO_SOLUTION | |
| {"NO_SOLUTION", ERR_LIB_BN, BN_R_NO_SOLUTION}, | |
| #else | |
| {"NO_SOLUTION", 3, 116}, | |
| #endif | |
| #ifdef BN_R_NO_SUITABLE_DIGEST | |
| {"NO_SUITABLE_DIGEST", ERR_LIB_BN, BN_R_NO_SUITABLE_DIGEST}, | |
| #else | |
| {"NO_SUITABLE_DIGEST", 3, 120}, | |
| #endif | |
| #ifdef BN_R_PRIVATE_KEY_TOO_LARGE | |
| {"PRIVATE_KEY_TOO_LARGE", ERR_LIB_BN, BN_R_PRIVATE_KEY_TOO_LARGE}, | |
| #else | |
| {"PRIVATE_KEY_TOO_LARGE", 3, 117}, | |
| #endif | |
| #ifdef BN_R_P_IS_NOT_PRIME | |
| {"P_IS_NOT_PRIME", ERR_LIB_BN, BN_R_P_IS_NOT_PRIME}, | |
| #else | |
| {"P_IS_NOT_PRIME", 3, 112}, | |
| #endif | |
| #ifdef BN_R_TOO_MANY_ITERATIONS | |
| {"TOO_MANY_ITERATIONS", ERR_LIB_BN, BN_R_TOO_MANY_ITERATIONS}, | |
| #else | |
| {"TOO_MANY_ITERATIONS", 3, 113}, | |
| #endif | |
| #ifdef BN_R_TOO_MANY_TEMPORARY_VARIABLES | |
| {"TOO_MANY_TEMPORARY_VARIABLES", ERR_LIB_BN, BN_R_TOO_MANY_TEMPORARY_VARIABLES}, | |
| #else | |
| {"TOO_MANY_TEMPORARY_VARIABLES", 3, 109}, | |
| #endif | |
| #ifdef CMP_R_ALGORITHM_NOT_SUPPORTED | |
| {"ALGORITHM_NOT_SUPPORTED", ERR_LIB_CMP, CMP_R_ALGORITHM_NOT_SUPPORTED}, | |
| #else | |
| {"ALGORITHM_NOT_SUPPORTED", 58, 139}, | |
| #endif | |
| #ifdef CMP_R_BAD_CHECKAFTER_IN_POLLREP | |
| {"BAD_CHECKAFTER_IN_POLLREP", ERR_LIB_CMP, CMP_R_BAD_CHECKAFTER_IN_POLLREP}, | |
| #else | |
| {"BAD_CHECKAFTER_IN_POLLREP", 58, 167}, | |
| #endif | |
| #ifdef CMP_R_BAD_REQUEST_ID | |
| {"BAD_REQUEST_ID", ERR_LIB_CMP, CMP_R_BAD_REQUEST_ID}, | |
| #else | |
| {"BAD_REQUEST_ID", 58, 108}, | |
| #endif | |
| #ifdef CMP_R_CERTHASH_UNMATCHED | |
| {"CERTHASH_UNMATCHED", ERR_LIB_CMP, CMP_R_CERTHASH_UNMATCHED}, | |
| #else | |
| {"CERTHASH_UNMATCHED", 58, 156}, | |
| #endif | |
| #ifdef CMP_R_CERTID_NOT_FOUND | |
| {"CERTID_NOT_FOUND", ERR_LIB_CMP, CMP_R_CERTID_NOT_FOUND}, | |
| #else | |
| {"CERTID_NOT_FOUND", 58, 109}, | |
| #endif | |
| #ifdef CMP_R_CERTIFICATE_NOT_ACCEPTED | |
| {"CERTIFICATE_NOT_ACCEPTED", ERR_LIB_CMP, CMP_R_CERTIFICATE_NOT_ACCEPTED}, | |
| #else | |
| {"CERTIFICATE_NOT_ACCEPTED", 58, 169}, | |
| #endif | |
| #ifdef CMP_R_CERTIFICATE_NOT_FOUND | |
| {"CERTIFICATE_NOT_FOUND", ERR_LIB_CMP, CMP_R_CERTIFICATE_NOT_FOUND}, | |
| #else | |
| {"CERTIFICATE_NOT_FOUND", 58, 112}, | |
| #endif | |
| #ifdef CMP_R_CERTREQMSG_NOT_FOUND | |
| {"CERTREQMSG_NOT_FOUND", ERR_LIB_CMP, CMP_R_CERTREQMSG_NOT_FOUND}, | |
| #else | |
| {"CERTREQMSG_NOT_FOUND", 58, 157}, | |
| #endif | |
| #ifdef CMP_R_CERTRESPONSE_NOT_FOUND | |
| {"CERTRESPONSE_NOT_FOUND", ERR_LIB_CMP, CMP_R_CERTRESPONSE_NOT_FOUND}, | |
| #else | |
| {"CERTRESPONSE_NOT_FOUND", 58, 113}, | |
| #endif | |
| #ifdef CMP_R_CERT_AND_KEY_DO_NOT_MATCH | |
| {"CERT_AND_KEY_DO_NOT_MATCH", ERR_LIB_CMP, CMP_R_CERT_AND_KEY_DO_NOT_MATCH}, | |
| #else | |
| {"CERT_AND_KEY_DO_NOT_MATCH", 58, 114}, | |
| #endif | |
| #ifdef CMP_R_CHECKAFTER_OUT_OF_RANGE | |
| {"CHECKAFTER_OUT_OF_RANGE", ERR_LIB_CMP, CMP_R_CHECKAFTER_OUT_OF_RANGE}, | |
| #else | |
| {"CHECKAFTER_OUT_OF_RANGE", 58, 181}, | |
| #endif | |
| #ifdef CMP_R_ENCOUNTERED_KEYUPDATEWARNING | |
| {"ENCOUNTERED_KEYUPDATEWARNING", ERR_LIB_CMP, CMP_R_ENCOUNTERED_KEYUPDATEWARNING}, | |
| #else | |
| {"ENCOUNTERED_KEYUPDATEWARNING", 58, 176}, | |
| #endif | |
| #ifdef CMP_R_ENCOUNTERED_WAITING | |
| {"ENCOUNTERED_WAITING", ERR_LIB_CMP, CMP_R_ENCOUNTERED_WAITING}, | |
| #else | |
| {"ENCOUNTERED_WAITING", 58, 162}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CALCULATING_PROTECTION | |
| {"ERROR_CALCULATING_PROTECTION", ERR_LIB_CMP, CMP_R_ERROR_CALCULATING_PROTECTION}, | |
| #else | |
| {"ERROR_CALCULATING_PROTECTION", 58, 115}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_CERTCONF | |
| {"ERROR_CREATING_CERTCONF", ERR_LIB_CMP, CMP_R_ERROR_CREATING_CERTCONF}, | |
| #else | |
| {"ERROR_CREATING_CERTCONF", 58, 116}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_CERTREP | |
| {"ERROR_CREATING_CERTREP", ERR_LIB_CMP, CMP_R_ERROR_CREATING_CERTREP}, | |
| #else | |
| {"ERROR_CREATING_CERTREP", 58, 117}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_CERTREQ | |
| {"ERROR_CREATING_CERTREQ", ERR_LIB_CMP, CMP_R_ERROR_CREATING_CERTREQ}, | |
| #else | |
| {"ERROR_CREATING_CERTREQ", 58, 163}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_ERROR | |
| {"ERROR_CREATING_ERROR", ERR_LIB_CMP, CMP_R_ERROR_CREATING_ERROR}, | |
| #else | |
| {"ERROR_CREATING_ERROR", 58, 118}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_GENM | |
| {"ERROR_CREATING_GENM", ERR_LIB_CMP, CMP_R_ERROR_CREATING_GENM}, | |
| #else | |
| {"ERROR_CREATING_GENM", 58, 119}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_GENP | |
| {"ERROR_CREATING_GENP", ERR_LIB_CMP, CMP_R_ERROR_CREATING_GENP}, | |
| #else | |
| {"ERROR_CREATING_GENP", 58, 120}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_PKICONF | |
| {"ERROR_CREATING_PKICONF", ERR_LIB_CMP, CMP_R_ERROR_CREATING_PKICONF}, | |
| #else | |
| {"ERROR_CREATING_PKICONF", 58, 122}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_POLLREP | |
| {"ERROR_CREATING_POLLREP", ERR_LIB_CMP, CMP_R_ERROR_CREATING_POLLREP}, | |
| #else | |
| {"ERROR_CREATING_POLLREP", 58, 123}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_POLLREQ | |
| {"ERROR_CREATING_POLLREQ", ERR_LIB_CMP, CMP_R_ERROR_CREATING_POLLREQ}, | |
| #else | |
| {"ERROR_CREATING_POLLREQ", 58, 124}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_RP | |
| {"ERROR_CREATING_RP", ERR_LIB_CMP, CMP_R_ERROR_CREATING_RP}, | |
| #else | |
| {"ERROR_CREATING_RP", 58, 125}, | |
| #endif | |
| #ifdef CMP_R_ERROR_CREATING_RR | |
| {"ERROR_CREATING_RR", ERR_LIB_CMP, CMP_R_ERROR_CREATING_RR}, | |
| #else | |
| {"ERROR_CREATING_RR", 58, 126}, | |
| #endif | |
| #ifdef CMP_R_ERROR_PARSING_PKISTATUS | |
| {"ERROR_PARSING_PKISTATUS", ERR_LIB_CMP, CMP_R_ERROR_PARSING_PKISTATUS}, | |
| #else | |
| {"ERROR_PARSING_PKISTATUS", 58, 107}, | |
| #endif | |
| #ifdef CMP_R_ERROR_PROCESSING_MESSAGE | |
| {"ERROR_PROCESSING_MESSAGE", ERR_LIB_CMP, CMP_R_ERROR_PROCESSING_MESSAGE}, | |
| #else | |
| {"ERROR_PROCESSING_MESSAGE", 58, 158}, | |
| #endif | |
| #ifdef CMP_R_ERROR_PROTECTING_MESSAGE | |
| {"ERROR_PROTECTING_MESSAGE", ERR_LIB_CMP, CMP_R_ERROR_PROTECTING_MESSAGE}, | |
| #else | |
| {"ERROR_PROTECTING_MESSAGE", 58, 127}, | |
| #endif | |
| #ifdef CMP_R_ERROR_SETTING_CERTHASH | |
| {"ERROR_SETTING_CERTHASH", ERR_LIB_CMP, CMP_R_ERROR_SETTING_CERTHASH}, | |
| #else | |
| {"ERROR_SETTING_CERTHASH", 58, 128}, | |
| #endif | |
| #ifdef CMP_R_ERROR_UNEXPECTED_CERTCONF | |
| {"ERROR_UNEXPECTED_CERTCONF", ERR_LIB_CMP, CMP_R_ERROR_UNEXPECTED_CERTCONF}, | |
| #else | |
| {"ERROR_UNEXPECTED_CERTCONF", 58, 160}, | |
| #endif | |
| #ifdef CMP_R_ERROR_VALIDATING_PROTECTION | |
| {"ERROR_VALIDATING_PROTECTION", ERR_LIB_CMP, CMP_R_ERROR_VALIDATING_PROTECTION}, | |
| #else | |
| {"ERROR_VALIDATING_PROTECTION", 58, 140}, | |
| #endif | |
| #ifdef CMP_R_ERROR_VALIDATING_SIGNATURE | |
| {"ERROR_VALIDATING_SIGNATURE", ERR_LIB_CMP, CMP_R_ERROR_VALIDATING_SIGNATURE}, | |
| #else | |
| {"ERROR_VALIDATING_SIGNATURE", 58, 171}, | |
| #endif | |
| #ifdef CMP_R_EXPECTED_POLLREQ | |
| {"EXPECTED_POLLREQ", ERR_LIB_CMP, CMP_R_EXPECTED_POLLREQ}, | |
| #else | |
| {"EXPECTED_POLLREQ", 58, 104}, | |
| #endif | |
| #ifdef CMP_R_FAILED_BUILDING_OWN_CHAIN | |
| {"FAILED_BUILDING_OWN_CHAIN", ERR_LIB_CMP, CMP_R_FAILED_BUILDING_OWN_CHAIN}, | |
| #else | |
| {"FAILED_BUILDING_OWN_CHAIN", 58, 164}, | |
| #endif | |
| #ifdef CMP_R_FAILED_EXTRACTING_CENTRAL_GEN_KEY | |
| {"FAILED_EXTRACTING_CENTRAL_GEN_KEY", ERR_LIB_CMP, CMP_R_FAILED_EXTRACTING_CENTRAL_GEN_KEY}, | |
| #else | |
| {"FAILED_EXTRACTING_CENTRAL_GEN_KEY", 58, 203}, | |
| #endif | |
| #ifdef CMP_R_FAILED_EXTRACTING_PUBKEY | |
| {"FAILED_EXTRACTING_PUBKEY", ERR_LIB_CMP, CMP_R_FAILED_EXTRACTING_PUBKEY}, | |
| #else | |
| {"FAILED_EXTRACTING_PUBKEY", 58, 141}, | |
| #endif | |
| #ifdef CMP_R_FAILURE_OBTAINING_RANDOM | |
| {"FAILURE_OBTAINING_RANDOM", ERR_LIB_CMP, CMP_R_FAILURE_OBTAINING_RANDOM}, | |
| #else | |
| {"FAILURE_OBTAINING_RANDOM", 58, 110}, | |
| #endif | |
| #ifdef CMP_R_FAIL_INFO_OUT_OF_RANGE | |
| {"FAIL_INFO_OUT_OF_RANGE", ERR_LIB_CMP, CMP_R_FAIL_INFO_OUT_OF_RANGE}, | |
| #else | |
| {"FAIL_INFO_OUT_OF_RANGE", 58, 129}, | |
| #endif | |
| #ifdef CMP_R_GENERATE_CERTREQTEMPLATE | |
| {"GENERATE_CERTREQTEMPLATE", ERR_LIB_CMP, CMP_R_GENERATE_CERTREQTEMPLATE}, | |
| #else | |
| {"GENERATE_CERTREQTEMPLATE", 58, 197}, | |
| #endif | |
| #ifdef CMP_R_GENERATE_CRLSTATUS | |
| {"GENERATE_CRLSTATUS", ERR_LIB_CMP, CMP_R_GENERATE_CRLSTATUS}, | |
| #else | |
| {"GENERATE_CRLSTATUS", 58, 198}, | |
| #endif | |
| #ifdef CMP_R_GETTING_GENP | |
| {"GETTING_GENP", ERR_LIB_CMP, CMP_R_GETTING_GENP}, | |
| #else | |
| {"GETTING_GENP", 58, 192}, | |
| #endif | |
| #ifdef CMP_R_GET_ITAV | |
| {"GET_ITAV", ERR_LIB_CMP, CMP_R_GET_ITAV}, | |
| #else | |
| {"GET_ITAV", 58, 199}, | |
| #endif | |
| #ifdef CMP_R_INVALID_ARGS | |
| {"INVALID_ARGS", ERR_LIB_CMP, CMP_R_INVALID_ARGS}, | |
| #else | |
| {"INVALID_ARGS", 58, 100}, | |
| #endif | |
| #ifdef CMP_R_INVALID_GENP | |
| {"INVALID_GENP", ERR_LIB_CMP, CMP_R_INVALID_GENP}, | |
| #else | |
| {"INVALID_GENP", 58, 193}, | |
| #endif | |
| #ifdef CMP_R_INVALID_KEYSPEC | |
| {"INVALID_KEYSPEC", ERR_LIB_CMP, CMP_R_INVALID_KEYSPEC}, | |
| #else | |
| {"INVALID_KEYSPEC", 58, 202}, | |
| #endif | |
| #ifdef CMP_R_INVALID_OPTION | |
| {"INVALID_OPTION", ERR_LIB_CMP, CMP_R_INVALID_OPTION}, | |
| #else | |
| {"INVALID_OPTION", 58, 174}, | |
| #endif | |
| #ifdef CMP_R_INVALID_ROOTCAKEYUPDATE | |
| {"INVALID_ROOTCAKEYUPDATE", ERR_LIB_CMP, CMP_R_INVALID_ROOTCAKEYUPDATE}, | |
| #else | |
| {"INVALID_ROOTCAKEYUPDATE", 58, 195}, | |
| #endif | |
| #ifdef CMP_R_MISSING_CENTRAL_GEN_KEY | |
| {"MISSING_CENTRAL_GEN_KEY", ERR_LIB_CMP, CMP_R_MISSING_CENTRAL_GEN_KEY}, | |
| #else | |
| {"MISSING_CENTRAL_GEN_KEY", 58, 204}, | |
| #endif | |
| #ifdef CMP_R_MISSING_CERTID | |
| {"MISSING_CERTID", ERR_LIB_CMP, CMP_R_MISSING_CERTID}, | |
| #else | |
| {"MISSING_CERTID", 58, 165}, | |
| #endif | |
| #ifdef CMP_R_MISSING_KEY_INPUT_FOR_CREATING_PROTECTION | |
| {"MISSING_KEY_INPUT_FOR_CREATING_PROTECTION", ERR_LIB_CMP, CMP_R_MISSING_KEY_INPUT_FOR_CREATING_PROTECTION}, | |
| #else | |
| {"MISSING_KEY_INPUT_FOR_CREATING_PROTECTION", 58, 130}, | |
| #endif | |
| #ifdef CMP_R_MISSING_KEY_USAGE_DIGITALSIGNATURE | |
| {"MISSING_KEY_USAGE_DIGITALSIGNATURE", ERR_LIB_CMP, CMP_R_MISSING_KEY_USAGE_DIGITALSIGNATURE}, | |
| #else | |
| {"MISSING_KEY_USAGE_DIGITALSIGNATURE", 58, 142}, | |
| #endif | |
| #ifdef CMP_R_MISSING_P10CSR | |
| {"MISSING_P10CSR", ERR_LIB_CMP, CMP_R_MISSING_P10CSR}, | |
| #else | |
| {"MISSING_P10CSR", 58, 121}, | |
| #endif | |
| #ifdef CMP_R_MISSING_PBM_SECRET | |
| {"MISSING_PBM_SECRET", ERR_LIB_CMP, CMP_R_MISSING_PBM_SECRET}, | |
| #else | |
| {"MISSING_PBM_SECRET", 58, 166}, | |
| #endif | |
| #ifdef CMP_R_MISSING_PRIVATE_KEY | |
| {"MISSING_PRIVATE_KEY", ERR_LIB_CMP, CMP_R_MISSING_PRIVATE_KEY}, | |
| #else | |
| {"MISSING_PRIVATE_KEY", 58, 131}, | |
| #endif | |
| #ifdef CMP_R_MISSING_PRIVATE_KEY_FOR_POPO | |
| {"MISSING_PRIVATE_KEY_FOR_POPO", ERR_LIB_CMP, CMP_R_MISSING_PRIVATE_KEY_FOR_POPO}, | |
| #else | |
| {"MISSING_PRIVATE_KEY_FOR_POPO", 58, 190}, | |
| #endif | |
| #ifdef CMP_R_MISSING_PROTECTION | |
| {"MISSING_PROTECTION", ERR_LIB_CMP, CMP_R_MISSING_PROTECTION}, | |
| #else | |
| {"MISSING_PROTECTION", 58, 143}, | |
| #endif | |
| #ifdef CMP_R_MISSING_PUBLIC_KEY | |
| {"MISSING_PUBLIC_KEY", ERR_LIB_CMP, CMP_R_MISSING_PUBLIC_KEY}, | |
| #else | |
| {"MISSING_PUBLIC_KEY", 58, 183}, | |
| #endif | |
| #ifdef CMP_R_MISSING_REFERENCE_CERT | |
| {"MISSING_REFERENCE_CERT", ERR_LIB_CMP, CMP_R_MISSING_REFERENCE_CERT}, | |
| #else | |
| {"MISSING_REFERENCE_CERT", 58, 168}, | |
| #endif | |
| #ifdef CMP_R_MISSING_SECRET | |
| {"MISSING_SECRET", ERR_LIB_CMP, CMP_R_MISSING_SECRET}, | |
| #else | |
| {"MISSING_SECRET", 58, 178}, | |
| #endif | |
| #ifdef CMP_R_MISSING_SENDER_IDENTIFICATION | |
| {"MISSING_SENDER_IDENTIFICATION", ERR_LIB_CMP, CMP_R_MISSING_SENDER_IDENTIFICATION}, | |
| #else | |
| {"MISSING_SENDER_IDENTIFICATION", 58, 111}, | |
| #endif | |
| #ifdef CMP_R_MISSING_TRUST_ANCHOR | |
| {"MISSING_TRUST_ANCHOR", ERR_LIB_CMP, CMP_R_MISSING_TRUST_ANCHOR}, | |
| #else | |
| {"MISSING_TRUST_ANCHOR", 58, 179}, | |
| #endif | |
| #ifdef CMP_R_MISSING_TRUST_STORE | |
| {"MISSING_TRUST_STORE", ERR_LIB_CMP, CMP_R_MISSING_TRUST_STORE}, | |
| #else | |
| {"MISSING_TRUST_STORE", 58, 144}, | |
| #endif | |
| #ifdef CMP_R_MULTIPLE_REQUESTS_NOT_SUPPORTED | |
| {"MULTIPLE_REQUESTS_NOT_SUPPORTED", ERR_LIB_CMP, CMP_R_MULTIPLE_REQUESTS_NOT_SUPPORTED}, | |
| #else | |
| {"MULTIPLE_REQUESTS_NOT_SUPPORTED", 58, 161}, | |
| #endif | |
| #ifdef CMP_R_MULTIPLE_RESPONSES_NOT_SUPPORTED | |
| {"MULTIPLE_RESPONSES_NOT_SUPPORTED", ERR_LIB_CMP, CMP_R_MULTIPLE_RESPONSES_NOT_SUPPORTED}, | |
| #else | |
| {"MULTIPLE_RESPONSES_NOT_SUPPORTED", 58, 170}, | |
| #endif | |
| #ifdef CMP_R_MULTIPLE_SAN_SOURCES | |
| {"MULTIPLE_SAN_SOURCES", ERR_LIB_CMP, CMP_R_MULTIPLE_SAN_SOURCES}, | |
| #else | |
| {"MULTIPLE_SAN_SOURCES", 58, 102}, | |
| #endif | |
| #ifdef CMP_R_NO_STDIO | |
| {"NO_STDIO", ERR_LIB_CMP, CMP_R_NO_STDIO}, | |
| #else | |
| {"NO_STDIO", 58, 194}, | |
| #endif | |
| #ifdef CMP_R_NO_SUITABLE_SENDER_CERT | |
| {"NO_SUITABLE_SENDER_CERT", ERR_LIB_CMP, CMP_R_NO_SUITABLE_SENDER_CERT}, | |
| #else | |
| {"NO_SUITABLE_SENDER_CERT", 58, 145}, | |
| #endif | |
| #ifdef CMP_R_NULL_ARGUMENT | |
| {"NULL_ARGUMENT", ERR_LIB_CMP, CMP_R_NULL_ARGUMENT}, | |
| #else | |
| {"NULL_ARGUMENT", 58, 103}, | |
| #endif | |
| #ifdef CMP_R_PKIBODY_ERROR | |
| {"PKIBODY_ERROR", ERR_LIB_CMP, CMP_R_PKIBODY_ERROR}, | |
| #else | |
| {"PKIBODY_ERROR", 58, 146}, | |
| #endif | |
| #ifdef CMP_R_PKISTATUSINFO_NOT_FOUND | |
| {"PKISTATUSINFO_NOT_FOUND", ERR_LIB_CMP, CMP_R_PKISTATUSINFO_NOT_FOUND}, | |
| #else | |
| {"PKISTATUSINFO_NOT_FOUND", 58, 132}, | |
| #endif | |
| #ifdef CMP_R_POLLING_FAILED | |
| {"POLLING_FAILED", ERR_LIB_CMP, CMP_R_POLLING_FAILED}, | |
| #else | |
| {"POLLING_FAILED", 58, 172}, | |
| #endif | |
| #ifdef CMP_R_POTENTIALLY_INVALID_CERTIFICATE | |
| {"POTENTIALLY_INVALID_CERTIFICATE", ERR_LIB_CMP, CMP_R_POTENTIALLY_INVALID_CERTIFICATE}, | |
| #else | |
| {"POTENTIALLY_INVALID_CERTIFICATE", 58, 147}, | |
| #endif | |
| #ifdef CMP_R_RECEIVED_ERROR | |
| {"RECEIVED_ERROR", ERR_LIB_CMP, CMP_R_RECEIVED_ERROR}, | |
| #else | |
| {"RECEIVED_ERROR", 58, 180}, | |
| #endif | |
| #ifdef CMP_R_RECIPNONCE_UNMATCHED | |
| {"RECIPNONCE_UNMATCHED", ERR_LIB_CMP, CMP_R_RECIPNONCE_UNMATCHED}, | |
| #else | |
| {"RECIPNONCE_UNMATCHED", 58, 148}, | |
| #endif | |
| #ifdef CMP_R_REQUEST_NOT_ACCEPTED | |
| {"REQUEST_NOT_ACCEPTED", ERR_LIB_CMP, CMP_R_REQUEST_NOT_ACCEPTED}, | |
| #else | |
| {"REQUEST_NOT_ACCEPTED", 58, 149}, | |
| #endif | |
| #ifdef CMP_R_REQUEST_REJECTED_BY_SERVER | |
| {"REQUEST_REJECTED_BY_SERVER", ERR_LIB_CMP, CMP_R_REQUEST_REJECTED_BY_SERVER}, | |
| #else | |
| {"REQUEST_REJECTED_BY_SERVER", 58, 182}, | |
| #endif | |
| #ifdef CMP_R_SENDER_GENERALNAME_TYPE_NOT_SUPPORTED | |
| {"SENDER_GENERALNAME_TYPE_NOT_SUPPORTED", ERR_LIB_CMP, CMP_R_SENDER_GENERALNAME_TYPE_NOT_SUPPORTED}, | |
| #else | |
| {"SENDER_GENERALNAME_TYPE_NOT_SUPPORTED", 58, 150}, | |
| #endif | |
| #ifdef CMP_R_SRVCERT_DOES_NOT_VALIDATE_MSG | |
| {"SRVCERT_DOES_NOT_VALIDATE_MSG", ERR_LIB_CMP, CMP_R_SRVCERT_DOES_NOT_VALIDATE_MSG}, | |
| #else | |
| {"SRVCERT_DOES_NOT_VALIDATE_MSG", 58, 151}, | |
| #endif | |
| #ifdef CMP_R_TOTAL_TIMEOUT | |
| {"TOTAL_TIMEOUT", ERR_LIB_CMP, CMP_R_TOTAL_TIMEOUT}, | |
| #else | |
| {"TOTAL_TIMEOUT", 58, 184}, | |
| #endif | |
| #ifdef CMP_R_TRANSACTIONID_UNMATCHED | |
| {"TRANSACTIONID_UNMATCHED", ERR_LIB_CMP, CMP_R_TRANSACTIONID_UNMATCHED}, | |
| #else | |
| {"TRANSACTIONID_UNMATCHED", 58, 152}, | |
| #endif | |
| #ifdef CMP_R_TRANSFER_ERROR | |
| {"TRANSFER_ERROR", ERR_LIB_CMP, CMP_R_TRANSFER_ERROR}, | |
| #else | |
| {"TRANSFER_ERROR", 58, 159}, | |
| #endif | |
| #ifdef CMP_R_UNCLEAN_CTX | |
| {"UNCLEAN_CTX", ERR_LIB_CMP, CMP_R_UNCLEAN_CTX}, | |
| #else | |
| {"UNCLEAN_CTX", 58, 191}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_CENTRAL_GEN_KEY | |
| {"UNEXPECTED_CENTRAL_GEN_KEY", ERR_LIB_CMP, CMP_R_UNEXPECTED_CENTRAL_GEN_KEY}, | |
| #else | |
| {"UNEXPECTED_CENTRAL_GEN_KEY", 58, 205}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_CERTPROFILE | |
| {"UNEXPECTED_CERTPROFILE", ERR_LIB_CMP, CMP_R_UNEXPECTED_CERTPROFILE}, | |
| #else | |
| {"UNEXPECTED_CERTPROFILE", 58, 196}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_CRLSTATUSLIST | |
| {"UNEXPECTED_CRLSTATUSLIST", ERR_LIB_CMP, CMP_R_UNEXPECTED_CRLSTATUSLIST}, | |
| #else | |
| {"UNEXPECTED_CRLSTATUSLIST", 58, 201}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_PKIBODY | |
| {"UNEXPECTED_PKIBODY", ERR_LIB_CMP, CMP_R_UNEXPECTED_PKIBODY}, | |
| #else | |
| {"UNEXPECTED_PKIBODY", 58, 133}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_PKISTATUS | |
| {"UNEXPECTED_PKISTATUS", ERR_LIB_CMP, CMP_R_UNEXPECTED_PKISTATUS}, | |
| #else | |
| {"UNEXPECTED_PKISTATUS", 58, 185}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_POLLREQ | |
| {"UNEXPECTED_POLLREQ", ERR_LIB_CMP, CMP_R_UNEXPECTED_POLLREQ}, | |
| #else | |
| {"UNEXPECTED_POLLREQ", 58, 105}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_PVNO | |
| {"UNEXPECTED_PVNO", ERR_LIB_CMP, CMP_R_UNEXPECTED_PVNO}, | |
| #else | |
| {"UNEXPECTED_PVNO", 58, 153}, | |
| #endif | |
| #ifdef CMP_R_UNEXPECTED_SENDER | |
| {"UNEXPECTED_SENDER", ERR_LIB_CMP, CMP_R_UNEXPECTED_SENDER}, | |
| #else | |
| {"UNEXPECTED_SENDER", 58, 106}, | |
| #endif | |
| #ifdef CMP_R_UNKNOWN_ALGORITHM_ID | |
| {"UNKNOWN_ALGORITHM_ID", ERR_LIB_CMP, CMP_R_UNKNOWN_ALGORITHM_ID}, | |
| #else | |
| {"UNKNOWN_ALGORITHM_ID", 58, 134}, | |
| #endif | |
| #ifdef CMP_R_UNKNOWN_CERT_TYPE | |
| {"UNKNOWN_CERT_TYPE", ERR_LIB_CMP, CMP_R_UNKNOWN_CERT_TYPE}, | |
| #else | |
| {"UNKNOWN_CERT_TYPE", 58, 135}, | |
| #endif | |
| #ifdef CMP_R_UNKNOWN_CRL_ISSUER | |
| {"UNKNOWN_CRL_ISSUER", ERR_LIB_CMP, CMP_R_UNKNOWN_CRL_ISSUER}, | |
| #else | |
| {"UNKNOWN_CRL_ISSUER", 58, 200}, | |
| #endif | |
| #ifdef CMP_R_UNKNOWN_PKISTATUS | |
| {"UNKNOWN_PKISTATUS", ERR_LIB_CMP, CMP_R_UNKNOWN_PKISTATUS}, | |
| #else | |
| {"UNKNOWN_PKISTATUS", 58, 186}, | |
| #endif | |
| #ifdef CMP_R_UNSUPPORTED_ALGORITHM | |
| {"UNSUPPORTED_ALGORITHM", ERR_LIB_CMP, CMP_R_UNSUPPORTED_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_ALGORITHM", 58, 136}, | |
| #endif | |
| #ifdef CMP_R_UNSUPPORTED_KEY_TYPE | |
| {"UNSUPPORTED_KEY_TYPE", ERR_LIB_CMP, CMP_R_UNSUPPORTED_KEY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_KEY_TYPE", 58, 137}, | |
| #endif | |
| #ifdef CMP_R_UNSUPPORTED_PKIBODY | |
| {"UNSUPPORTED_PKIBODY", ERR_LIB_CMP, CMP_R_UNSUPPORTED_PKIBODY}, | |
| #else | |
| {"UNSUPPORTED_PKIBODY", 58, 101}, | |
| #endif | |
| #ifdef CMP_R_UNSUPPORTED_PROTECTION_ALG_DHBASEDMAC | |
| {"UNSUPPORTED_PROTECTION_ALG_DHBASEDMAC", ERR_LIB_CMP, CMP_R_UNSUPPORTED_PROTECTION_ALG_DHBASEDMAC}, | |
| #else | |
| {"UNSUPPORTED_PROTECTION_ALG_DHBASEDMAC", 58, 154}, | |
| #endif | |
| #ifdef CMP_R_VALUE_TOO_LARGE | |
| {"VALUE_TOO_LARGE", ERR_LIB_CMP, CMP_R_VALUE_TOO_LARGE}, | |
| #else | |
| {"VALUE_TOO_LARGE", 58, 175}, | |
| #endif | |
| #ifdef CMP_R_VALUE_TOO_SMALL | |
| {"VALUE_TOO_SMALL", ERR_LIB_CMP, CMP_R_VALUE_TOO_SMALL}, | |
| #else | |
| {"VALUE_TOO_SMALL", 58, 177}, | |
| #endif | |
| #ifdef CMP_R_WRONG_ALGORITHM_OID | |
| {"WRONG_ALGORITHM_OID", ERR_LIB_CMP, CMP_R_WRONG_ALGORITHM_OID}, | |
| #else | |
| {"WRONG_ALGORITHM_OID", 58, 138}, | |
| #endif | |
| #ifdef CMP_R_WRONG_CERTID | |
| {"WRONG_CERTID", ERR_LIB_CMP, CMP_R_WRONG_CERTID}, | |
| #else | |
| {"WRONG_CERTID", 58, 189}, | |
| #endif | |
| #ifdef CMP_R_WRONG_CERTID_IN_RP | |
| {"WRONG_CERTID_IN_RP", ERR_LIB_CMP, CMP_R_WRONG_CERTID_IN_RP}, | |
| #else | |
| {"WRONG_CERTID_IN_RP", 58, 187}, | |
| #endif | |
| #ifdef CMP_R_WRONG_PBM_VALUE | |
| {"WRONG_PBM_VALUE", ERR_LIB_CMP, CMP_R_WRONG_PBM_VALUE}, | |
| #else | |
| {"WRONG_PBM_VALUE", 58, 155}, | |
| #endif | |
| #ifdef CMP_R_WRONG_RP_COMPONENT_COUNT | |
| {"WRONG_RP_COMPONENT_COUNT", ERR_LIB_CMP, CMP_R_WRONG_RP_COMPONENT_COUNT}, | |
| #else | |
| {"WRONG_RP_COMPONENT_COUNT", 58, 188}, | |
| #endif | |
| #ifdef CMP_R_WRONG_SERIAL_IN_RP | |
| {"WRONG_SERIAL_IN_RP", ERR_LIB_CMP, CMP_R_WRONG_SERIAL_IN_RP}, | |
| #else | |
| {"WRONG_SERIAL_IN_RP", 58, 173}, | |
| #endif | |
| #ifdef CMS_R_ADD_SIGNER_ERROR | |
| {"ADD_SIGNER_ERROR", ERR_LIB_CMS, CMS_R_ADD_SIGNER_ERROR}, | |
| #else | |
| {"ADD_SIGNER_ERROR", 46, 99}, | |
| #endif | |
| #ifdef CMS_R_ATTRIBUTE_ERROR | |
| {"ATTRIBUTE_ERROR", ERR_LIB_CMS, CMS_R_ATTRIBUTE_ERROR}, | |
| #else | |
| {"ATTRIBUTE_ERROR", 46, 161}, | |
| #endif | |
| #ifdef CMS_R_CERTIFICATE_ALREADY_PRESENT | |
| {"CERTIFICATE_ALREADY_PRESENT", ERR_LIB_CMS, CMS_R_CERTIFICATE_ALREADY_PRESENT}, | |
| #else | |
| {"CERTIFICATE_ALREADY_PRESENT", 46, 175}, | |
| #endif | |
| #ifdef CMS_R_CERTIFICATE_HAS_NO_KEYID | |
| {"CERTIFICATE_HAS_NO_KEYID", ERR_LIB_CMS, CMS_R_CERTIFICATE_HAS_NO_KEYID}, | |
| #else | |
| {"CERTIFICATE_HAS_NO_KEYID", 46, 160}, | |
| #endif | |
| #ifdef CMS_R_CERTIFICATE_VERIFY_ERROR | |
| {"CERTIFICATE_VERIFY_ERROR", ERR_LIB_CMS, CMS_R_CERTIFICATE_VERIFY_ERROR}, | |
| #else | |
| {"CERTIFICATE_VERIFY_ERROR", 46, 100}, | |
| #endif | |
| #ifdef CMS_R_CIPHER_AEAD_SET_TAG_ERROR | |
| {"CIPHER_AEAD_SET_TAG_ERROR", ERR_LIB_CMS, CMS_R_CIPHER_AEAD_SET_TAG_ERROR}, | |
| #else | |
| {"CIPHER_AEAD_SET_TAG_ERROR", 46, 184}, | |
| #endif | |
| #ifdef CMS_R_CIPHER_GET_TAG | |
| {"CIPHER_GET_TAG", ERR_LIB_CMS, CMS_R_CIPHER_GET_TAG}, | |
| #else | |
| {"CIPHER_GET_TAG", 46, 185}, | |
| #endif | |
| #ifdef CMS_R_CIPHER_INITIALISATION_ERROR | |
| {"CIPHER_INITIALISATION_ERROR", ERR_LIB_CMS, CMS_R_CIPHER_INITIALISATION_ERROR}, | |
| #else | |
| {"CIPHER_INITIALISATION_ERROR", 46, 101}, | |
| #endif | |
| #ifdef CMS_R_CIPHER_PARAMETER_INITIALISATION_ERROR | |
| {"CIPHER_PARAMETER_INITIALISATION_ERROR", ERR_LIB_CMS, CMS_R_CIPHER_PARAMETER_INITIALISATION_ERROR}, | |
| #else | |
| {"CIPHER_PARAMETER_INITIALISATION_ERROR", 46, 102}, | |
| #endif | |
| #ifdef CMS_R_CMS_DATAFINAL_ERROR | |
| {"CMS_DATAFINAL_ERROR", ERR_LIB_CMS, CMS_R_CMS_DATAFINAL_ERROR}, | |
| #else | |
| {"CMS_DATAFINAL_ERROR", 46, 103}, | |
| #endif | |
| #ifdef CMS_R_CMS_LIB | |
| {"CMS_LIB", ERR_LIB_CMS, CMS_R_CMS_LIB}, | |
| #else | |
| {"CMS_LIB", 46, 104}, | |
| #endif | |
| #ifdef CMS_R_CONTENTIDENTIFIER_MISMATCH | |
| {"CONTENTIDENTIFIER_MISMATCH", ERR_LIB_CMS, CMS_R_CONTENTIDENTIFIER_MISMATCH}, | |
| #else | |
| {"CONTENTIDENTIFIER_MISMATCH", 46, 170}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_NOT_FOUND | |
| {"CONTENT_NOT_FOUND", ERR_LIB_CMS, CMS_R_CONTENT_NOT_FOUND}, | |
| #else | |
| {"CONTENT_NOT_FOUND", 46, 105}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_TYPE_MISMATCH | |
| {"CONTENT_TYPE_MISMATCH", ERR_LIB_CMS, CMS_R_CONTENT_TYPE_MISMATCH}, | |
| #else | |
| {"CONTENT_TYPE_MISMATCH", 46, 171}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_TYPE_NOT_COMPRESSED_DATA | |
| {"CONTENT_TYPE_NOT_COMPRESSED_DATA", ERR_LIB_CMS, CMS_R_CONTENT_TYPE_NOT_COMPRESSED_DATA}, | |
| #else | |
| {"CONTENT_TYPE_NOT_COMPRESSED_DATA", 46, 106}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_TYPE_NOT_ENVELOPED_DATA | |
| {"CONTENT_TYPE_NOT_ENVELOPED_DATA", ERR_LIB_CMS, CMS_R_CONTENT_TYPE_NOT_ENVELOPED_DATA}, | |
| #else | |
| {"CONTENT_TYPE_NOT_ENVELOPED_DATA", 46, 107}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_TYPE_NOT_SIGNED_DATA | |
| {"CONTENT_TYPE_NOT_SIGNED_DATA", ERR_LIB_CMS, CMS_R_CONTENT_TYPE_NOT_SIGNED_DATA}, | |
| #else | |
| {"CONTENT_TYPE_NOT_SIGNED_DATA", 46, 108}, | |
| #endif | |
| #ifdef CMS_R_CONTENT_VERIFY_ERROR | |
| {"CONTENT_VERIFY_ERROR", ERR_LIB_CMS, CMS_R_CONTENT_VERIFY_ERROR}, | |
| #else | |
| {"CONTENT_VERIFY_ERROR", 46, 109}, | |
| #endif | |
| #ifdef CMS_R_CTRL_ERROR | |
| {"CTRL_ERROR", ERR_LIB_CMS, CMS_R_CTRL_ERROR}, | |
| #else | |
| {"CTRL_ERROR", 46, 110}, | |
| #endif | |
| #ifdef CMS_R_CTRL_FAILURE | |
| {"CTRL_FAILURE", ERR_LIB_CMS, CMS_R_CTRL_FAILURE}, | |
| #else | |
| {"CTRL_FAILURE", 46, 111}, | |
| #endif | |
| #ifdef CMS_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_CMS, CMS_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 46, 187}, | |
| #endif | |
| #ifdef CMS_R_DECRYPT_ERROR | |
| {"DECRYPT_ERROR", ERR_LIB_CMS, CMS_R_DECRYPT_ERROR}, | |
| #else | |
| {"DECRYPT_ERROR", 46, 112}, | |
| #endif | |
| #ifdef CMS_R_ERROR_GETTING_PUBLIC_KEY | |
| {"ERROR_GETTING_PUBLIC_KEY", ERR_LIB_CMS, CMS_R_ERROR_GETTING_PUBLIC_KEY}, | |
| #else | |
| {"ERROR_GETTING_PUBLIC_KEY", 46, 113}, | |
| #endif | |
| #ifdef CMS_R_ERROR_READING_MESSAGEDIGEST_ATTRIBUTE | |
| {"ERROR_READING_MESSAGEDIGEST_ATTRIBUTE", ERR_LIB_CMS, CMS_R_ERROR_READING_MESSAGEDIGEST_ATTRIBUTE}, | |
| #else | |
| {"ERROR_READING_MESSAGEDIGEST_ATTRIBUTE", 46, 114}, | |
| #endif | |
| #ifdef CMS_R_ERROR_SETTING_KEY | |
| {"ERROR_SETTING_KEY", ERR_LIB_CMS, CMS_R_ERROR_SETTING_KEY}, | |
| #else | |
| {"ERROR_SETTING_KEY", 46, 115}, | |
| #endif | |
| #ifdef CMS_R_ERROR_SETTING_RECIPIENTINFO | |
| {"ERROR_SETTING_RECIPIENTINFO", ERR_LIB_CMS, CMS_R_ERROR_SETTING_RECIPIENTINFO}, | |
| #else | |
| {"ERROR_SETTING_RECIPIENTINFO", 46, 116}, | |
| #endif | |
| #ifdef CMS_R_ERROR_UNSUPPORTED_STATIC_KEY_AGREEMENT | |
| {"ERROR_UNSUPPORTED_STATIC_KEY_AGREEMENT", ERR_LIB_CMS, CMS_R_ERROR_UNSUPPORTED_STATIC_KEY_AGREEMENT}, | |
| #else | |
| {"ERROR_UNSUPPORTED_STATIC_KEY_AGREEMENT", 46, 196}, | |
| #endif | |
| #ifdef CMS_R_ESS_SIGNING_CERTID_MISMATCH_ERROR | |
| {"ESS_SIGNING_CERTID_MISMATCH_ERROR", ERR_LIB_CMS, CMS_R_ESS_SIGNING_CERTID_MISMATCH_ERROR}, | |
| #else | |
| {"ESS_SIGNING_CERTID_MISMATCH_ERROR", 46, 183}, | |
| #endif | |
| #ifdef CMS_R_INVALID_ENCRYPTED_KEY_LENGTH | |
| {"INVALID_ENCRYPTED_KEY_LENGTH", ERR_LIB_CMS, CMS_R_INVALID_ENCRYPTED_KEY_LENGTH}, | |
| #else | |
| {"INVALID_ENCRYPTED_KEY_LENGTH", 46, 117}, | |
| #endif | |
| #ifdef CMS_R_INVALID_KEY_ENCRYPTION_PARAMETER | |
| {"INVALID_KEY_ENCRYPTION_PARAMETER", ERR_LIB_CMS, CMS_R_INVALID_KEY_ENCRYPTION_PARAMETER}, | |
| #else | |
| {"INVALID_KEY_ENCRYPTION_PARAMETER", 46, 176}, | |
| #endif | |
| #ifdef CMS_R_INVALID_KEY_LENGTH | |
| {"INVALID_KEY_LENGTH", ERR_LIB_CMS, CMS_R_INVALID_KEY_LENGTH}, | |
| #else | |
| {"INVALID_KEY_LENGTH", 46, 118}, | |
| #endif | |
| #ifdef CMS_R_INVALID_LABEL | |
| {"INVALID_LABEL", ERR_LIB_CMS, CMS_R_INVALID_LABEL}, | |
| #else | |
| {"INVALID_LABEL", 46, 190}, | |
| #endif | |
| #ifdef CMS_R_INVALID_OAEP_PARAMETERS | |
| {"INVALID_OAEP_PARAMETERS", ERR_LIB_CMS, CMS_R_INVALID_OAEP_PARAMETERS}, | |
| #else | |
| {"INVALID_OAEP_PARAMETERS", 46, 191}, | |
| #endif | |
| #ifdef CMS_R_KDF_PARAMETER_ERROR | |
| {"KDF_PARAMETER_ERROR", ERR_LIB_CMS, CMS_R_KDF_PARAMETER_ERROR}, | |
| #else | |
| {"KDF_PARAMETER_ERROR", 46, 186}, | |
| #endif | |
| #ifdef CMS_R_MD_BIO_INIT_ERROR | |
| {"MD_BIO_INIT_ERROR", ERR_LIB_CMS, CMS_R_MD_BIO_INIT_ERROR}, | |
| #else | |
| {"MD_BIO_INIT_ERROR", 46, 119}, | |
| #endif | |
| #ifdef CMS_R_MESSAGEDIGEST_ATTRIBUTE_WRONG_LENGTH | |
| {"MESSAGEDIGEST_ATTRIBUTE_WRONG_LENGTH", ERR_LIB_CMS, CMS_R_MESSAGEDIGEST_ATTRIBUTE_WRONG_LENGTH}, | |
| #else | |
| {"MESSAGEDIGEST_ATTRIBUTE_WRONG_LENGTH", 46, 120}, | |
| #endif | |
| #ifdef CMS_R_MESSAGEDIGEST_WRONG_LENGTH | |
| {"MESSAGEDIGEST_WRONG_LENGTH", ERR_LIB_CMS, CMS_R_MESSAGEDIGEST_WRONG_LENGTH}, | |
| #else | |
| {"MESSAGEDIGEST_WRONG_LENGTH", 46, 121}, | |
| #endif | |
| #ifdef CMS_R_MSGSIGDIGEST_ERROR | |
| {"MSGSIGDIGEST_ERROR", ERR_LIB_CMS, CMS_R_MSGSIGDIGEST_ERROR}, | |
| #else | |
| {"MSGSIGDIGEST_ERROR", 46, 172}, | |
| #endif | |
| #ifdef CMS_R_MSGSIGDIGEST_VERIFICATION_FAILURE | |
| {"MSGSIGDIGEST_VERIFICATION_FAILURE", ERR_LIB_CMS, CMS_R_MSGSIGDIGEST_VERIFICATION_FAILURE}, | |
| #else | |
| {"MSGSIGDIGEST_VERIFICATION_FAILURE", 46, 162}, | |
| #endif | |
| #ifdef CMS_R_MSGSIGDIGEST_WRONG_LENGTH | |
| {"MSGSIGDIGEST_WRONG_LENGTH", ERR_LIB_CMS, CMS_R_MSGSIGDIGEST_WRONG_LENGTH}, | |
| #else | |
| {"MSGSIGDIGEST_WRONG_LENGTH", 46, 163}, | |
| #endif | |
| #ifdef CMS_R_NEED_ONE_SIGNER | |
| {"NEED_ONE_SIGNER", ERR_LIB_CMS, CMS_R_NEED_ONE_SIGNER}, | |
| #else | |
| {"NEED_ONE_SIGNER", 46, 164}, | |
| #endif | |
| #ifdef CMS_R_NOT_A_SIGNED_RECEIPT | |
| {"NOT_A_SIGNED_RECEIPT", ERR_LIB_CMS, CMS_R_NOT_A_SIGNED_RECEIPT}, | |
| #else | |
| {"NOT_A_SIGNED_RECEIPT", 46, 165}, | |
| #endif | |
| #ifdef CMS_R_NOT_ENCRYPTED_DATA | |
| {"NOT_ENCRYPTED_DATA", ERR_LIB_CMS, CMS_R_NOT_ENCRYPTED_DATA}, | |
| #else | |
| {"NOT_ENCRYPTED_DATA", 46, 122}, | |
| #endif | |
| #ifdef CMS_R_NOT_KEK | |
| {"NOT_KEK", ERR_LIB_CMS, CMS_R_NOT_KEK}, | |
| #else | |
| {"NOT_KEK", 46, 123}, | |
| #endif | |
| #ifdef CMS_R_NOT_KEM | |
| {"NOT_KEM", ERR_LIB_CMS, CMS_R_NOT_KEM}, | |
| #else | |
| {"NOT_KEM", 46, 197}, | |
| #endif | |
| #ifdef CMS_R_NOT_KEY_AGREEMENT | |
| {"NOT_KEY_AGREEMENT", ERR_LIB_CMS, CMS_R_NOT_KEY_AGREEMENT}, | |
| #else | |
| {"NOT_KEY_AGREEMENT", 46, 181}, | |
| #endif | |
| #ifdef CMS_R_NOT_KEY_TRANSPORT | |
| {"NOT_KEY_TRANSPORT", ERR_LIB_CMS, CMS_R_NOT_KEY_TRANSPORT}, | |
| #else | |
| {"NOT_KEY_TRANSPORT", 46, 124}, | |
| #endif | |
| #ifdef CMS_R_NOT_PWRI | |
| {"NOT_PWRI", ERR_LIB_CMS, CMS_R_NOT_PWRI}, | |
| #else | |
| {"NOT_PWRI", 46, 177}, | |
| #endif | |
| #ifdef CMS_R_NOT_SUPPORTED_FOR_THIS_KEY_TYPE | |
| {"NOT_SUPPORTED_FOR_THIS_KEY_TYPE", ERR_LIB_CMS, CMS_R_NOT_SUPPORTED_FOR_THIS_KEY_TYPE}, | |
| #else | |
| {"NOT_SUPPORTED_FOR_THIS_KEY_TYPE", 46, 125}, | |
| #endif | |
| #ifdef CMS_R_NO_CIPHER | |
| {"NO_CIPHER", ERR_LIB_CMS, CMS_R_NO_CIPHER}, | |
| #else | |
| {"NO_CIPHER", 46, 126}, | |
| #endif | |
| #ifdef CMS_R_NO_CONTENT | |
| {"NO_CONTENT", ERR_LIB_CMS, CMS_R_NO_CONTENT}, | |
| #else | |
| {"NO_CONTENT", 46, 127}, | |
| #endif | |
| #ifdef CMS_R_NO_CONTENT_TYPE | |
| {"NO_CONTENT_TYPE", ERR_LIB_CMS, CMS_R_NO_CONTENT_TYPE}, | |
| #else | |
| {"NO_CONTENT_TYPE", 46, 173}, | |
| #endif | |
| #ifdef CMS_R_NO_DEFAULT_DIGEST | |
| {"NO_DEFAULT_DIGEST", ERR_LIB_CMS, CMS_R_NO_DEFAULT_DIGEST}, | |
| #else | |
| {"NO_DEFAULT_DIGEST", 46, 128}, | |
| #endif | |
| #ifdef CMS_R_NO_DIGEST_SET | |
| {"NO_DIGEST_SET", ERR_LIB_CMS, CMS_R_NO_DIGEST_SET}, | |
| #else | |
| {"NO_DIGEST_SET", 46, 129}, | |
| #endif | |
| #ifdef CMS_R_NO_KEY | |
| {"NO_KEY", ERR_LIB_CMS, CMS_R_NO_KEY}, | |
| #else | |
| {"NO_KEY", 46, 130}, | |
| #endif | |
| #ifdef CMS_R_NO_KEY_OR_CERT | |
| {"NO_KEY_OR_CERT", ERR_LIB_CMS, CMS_R_NO_KEY_OR_CERT}, | |
| #else | |
| {"NO_KEY_OR_CERT", 46, 174}, | |
| #endif | |
| #ifdef CMS_R_NO_MATCHING_DIGEST | |
| {"NO_MATCHING_DIGEST", ERR_LIB_CMS, CMS_R_NO_MATCHING_DIGEST}, | |
| #else | |
| {"NO_MATCHING_DIGEST", 46, 131}, | |
| #endif | |
| #ifdef CMS_R_NO_MATCHING_RECIPIENT | |
| {"NO_MATCHING_RECIPIENT", ERR_LIB_CMS, CMS_R_NO_MATCHING_RECIPIENT}, | |
| #else | |
| {"NO_MATCHING_RECIPIENT", 46, 132}, | |
| #endif | |
| #ifdef CMS_R_NO_MATCHING_SIGNATURE | |
| {"NO_MATCHING_SIGNATURE", ERR_LIB_CMS, CMS_R_NO_MATCHING_SIGNATURE}, | |
| #else | |
| {"NO_MATCHING_SIGNATURE", 46, 166}, | |
| #endif | |
| #ifdef CMS_R_NO_MSGSIGDIGEST | |
| {"NO_MSGSIGDIGEST", ERR_LIB_CMS, CMS_R_NO_MSGSIGDIGEST}, | |
| #else | |
| {"NO_MSGSIGDIGEST", 46, 167}, | |
| #endif | |
| #ifdef CMS_R_NO_PASSWORD | |
| {"NO_PASSWORD", ERR_LIB_CMS, CMS_R_NO_PASSWORD}, | |
| #else | |
| {"NO_PASSWORD", 46, 178}, | |
| #endif | |
| #ifdef CMS_R_NO_PRIVATE_KEY | |
| {"NO_PRIVATE_KEY", ERR_LIB_CMS, CMS_R_NO_PRIVATE_KEY}, | |
| #else | |
| {"NO_PRIVATE_KEY", 46, 133}, | |
| #endif | |
| #ifdef CMS_R_NO_PUBLIC_KEY | |
| {"NO_PUBLIC_KEY", ERR_LIB_CMS, CMS_R_NO_PUBLIC_KEY}, | |
| #else | |
| {"NO_PUBLIC_KEY", 46, 134}, | |
| #endif | |
| #ifdef CMS_R_NO_RECEIPT_REQUEST | |
| {"NO_RECEIPT_REQUEST", ERR_LIB_CMS, CMS_R_NO_RECEIPT_REQUEST}, | |
| #else | |
| {"NO_RECEIPT_REQUEST", 46, 168}, | |
| #endif | |
| #ifdef CMS_R_NO_SIGNERS | |
| {"NO_SIGNERS", ERR_LIB_CMS, CMS_R_NO_SIGNERS}, | |
| #else | |
| {"NO_SIGNERS", 46, 135}, | |
| #endif | |
| #ifdef CMS_R_OPERATION_UNSUPPORTED | |
| {"OPERATION_UNSUPPORTED", ERR_LIB_CMS, CMS_R_OPERATION_UNSUPPORTED}, | |
| #else | |
| {"OPERATION_UNSUPPORTED", 46, 182}, | |
| #endif | |
| #ifdef CMS_R_PEER_KEY_ERROR | |
| {"PEER_KEY_ERROR", ERR_LIB_CMS, CMS_R_PEER_KEY_ERROR}, | |
| #else | |
| {"PEER_KEY_ERROR", 46, 188}, | |
| #endif | |
| #ifdef CMS_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", ERR_LIB_CMS, CMS_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE}, | |
| #else | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", 46, 136}, | |
| #endif | |
| #ifdef CMS_R_RECEIPT_DECODE_ERROR | |
| {"RECEIPT_DECODE_ERROR", ERR_LIB_CMS, CMS_R_RECEIPT_DECODE_ERROR}, | |
| #else | |
| {"RECEIPT_DECODE_ERROR", 46, 169}, | |
| #endif | |
| #ifdef CMS_R_RECIPIENT_ERROR | |
| {"RECIPIENT_ERROR", ERR_LIB_CMS, CMS_R_RECIPIENT_ERROR}, | |
| #else | |
| {"RECIPIENT_ERROR", 46, 137}, | |
| #endif | |
| #ifdef CMS_R_SHARED_INFO_ERROR | |
| {"SHARED_INFO_ERROR", ERR_LIB_CMS, CMS_R_SHARED_INFO_ERROR}, | |
| #else | |
| {"SHARED_INFO_ERROR", 46, 189}, | |
| #endif | |
| #ifdef CMS_R_SIGNER_CERTIFICATE_NOT_FOUND | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", ERR_LIB_CMS, CMS_R_SIGNER_CERTIFICATE_NOT_FOUND}, | |
| #else | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", 46, 138}, | |
| #endif | |
| #ifdef CMS_R_SIGNFINAL_ERROR | |
| {"SIGNFINAL_ERROR", ERR_LIB_CMS, CMS_R_SIGNFINAL_ERROR}, | |
| #else | |
| {"SIGNFINAL_ERROR", 46, 139}, | |
| #endif | |
| #ifdef CMS_R_SMIME_TEXT_ERROR | |
| {"SMIME_TEXT_ERROR", ERR_LIB_CMS, CMS_R_SMIME_TEXT_ERROR}, | |
| #else | |
| {"SMIME_TEXT_ERROR", 46, 140}, | |
| #endif | |
| #ifdef CMS_R_STORE_INIT_ERROR | |
| {"STORE_INIT_ERROR", ERR_LIB_CMS, CMS_R_STORE_INIT_ERROR}, | |
| #else | |
| {"STORE_INIT_ERROR", 46, 141}, | |
| #endif | |
| #ifdef CMS_R_TYPE_NOT_COMPRESSED_DATA | |
| {"TYPE_NOT_COMPRESSED_DATA", ERR_LIB_CMS, CMS_R_TYPE_NOT_COMPRESSED_DATA}, | |
| #else | |
| {"TYPE_NOT_COMPRESSED_DATA", 46, 142}, | |
| #endif | |
| #ifdef CMS_R_TYPE_NOT_DATA | |
| {"TYPE_NOT_DATA", ERR_LIB_CMS, CMS_R_TYPE_NOT_DATA}, | |
| #else | |
| {"TYPE_NOT_DATA", 46, 143}, | |
| #endif | |
| #ifdef CMS_R_TYPE_NOT_DIGESTED_DATA | |
| {"TYPE_NOT_DIGESTED_DATA", ERR_LIB_CMS, CMS_R_TYPE_NOT_DIGESTED_DATA}, | |
| #else | |
| {"TYPE_NOT_DIGESTED_DATA", 46, 144}, | |
| #endif | |
| #ifdef CMS_R_TYPE_NOT_ENCRYPTED_DATA | |
| {"TYPE_NOT_ENCRYPTED_DATA", ERR_LIB_CMS, CMS_R_TYPE_NOT_ENCRYPTED_DATA}, | |
| #else | |
| {"TYPE_NOT_ENCRYPTED_DATA", 46, 145}, | |
| #endif | |
| #ifdef CMS_R_TYPE_NOT_ENVELOPED_DATA | |
| {"TYPE_NOT_ENVELOPED_DATA", ERR_LIB_CMS, CMS_R_TYPE_NOT_ENVELOPED_DATA}, | |
| #else | |
| {"TYPE_NOT_ENVELOPED_DATA", 46, 146}, | |
| #endif | |
| #ifdef CMS_R_UNABLE_TO_FINALIZE_CONTEXT | |
| {"UNABLE_TO_FINALIZE_CONTEXT", ERR_LIB_CMS, CMS_R_UNABLE_TO_FINALIZE_CONTEXT}, | |
| #else | |
| {"UNABLE_TO_FINALIZE_CONTEXT", 46, 147}, | |
| #endif | |
| #ifdef CMS_R_UNKNOWN_CIPHER | |
| {"UNKNOWN_CIPHER", ERR_LIB_CMS, CMS_R_UNKNOWN_CIPHER}, | |
| #else | |
| {"UNKNOWN_CIPHER", 46, 148}, | |
| #endif | |
| #ifdef CMS_R_UNKNOWN_DIGEST_ALGORITHM | |
| {"UNKNOWN_DIGEST_ALGORITHM", ERR_LIB_CMS, CMS_R_UNKNOWN_DIGEST_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_DIGEST_ALGORITHM", 46, 149}, | |
| #endif | |
| #ifdef CMS_R_UNKNOWN_ID | |
| {"UNKNOWN_ID", ERR_LIB_CMS, CMS_R_UNKNOWN_ID}, | |
| #else | |
| {"UNKNOWN_ID", 46, 150}, | |
| #endif | |
| #ifdef CMS_R_UNKNOWN_KDF_ALGORITHM | |
| {"UNKNOWN_KDF_ALGORITHM", ERR_LIB_CMS, CMS_R_UNKNOWN_KDF_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_KDF_ALGORITHM", 46, 198}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_COMPRESSION_ALGORITHM | |
| {"UNSUPPORTED_COMPRESSION_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_COMPRESSION_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_COMPRESSION_ALGORITHM", 46, 151}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_CONTENT_ENCRYPTION_ALGORITHM | |
| {"UNSUPPORTED_CONTENT_ENCRYPTION_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_CONTENT_ENCRYPTION_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_CONTENT_ENCRYPTION_ALGORITHM", 46, 194}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_CONTENT_TYPE | |
| {"UNSUPPORTED_CONTENT_TYPE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_CONTENT_TYPE}, | |
| #else | |
| {"UNSUPPORTED_CONTENT_TYPE", 46, 152}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_ENCRYPTION_TYPE | |
| {"UNSUPPORTED_ENCRYPTION_TYPE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_ENCRYPTION_TYPE}, | |
| #else | |
| {"UNSUPPORTED_ENCRYPTION_TYPE", 46, 192}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_KDF_ALGORITHM | |
| {"UNSUPPORTED_KDF_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_KDF_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_KDF_ALGORITHM", 46, 199}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_KEK_ALGORITHM | |
| {"UNSUPPORTED_KEK_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_KEK_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_KEK_ALGORITHM", 46, 153}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM | |
| {"UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_KEY_ENCRYPTION_ALGORITHM", 46, 179}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_LABEL_SOURCE | |
| {"UNSUPPORTED_LABEL_SOURCE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_LABEL_SOURCE}, | |
| #else | |
| {"UNSUPPORTED_LABEL_SOURCE", 46, 193}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_RECIPIENTINFO_TYPE | |
| {"UNSUPPORTED_RECIPIENTINFO_TYPE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_RECIPIENTINFO_TYPE}, | |
| #else | |
| {"UNSUPPORTED_RECIPIENTINFO_TYPE", 46, 155}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_RECIPIENT_TYPE | |
| {"UNSUPPORTED_RECIPIENT_TYPE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_RECIPIENT_TYPE}, | |
| #else | |
| {"UNSUPPORTED_RECIPIENT_TYPE", 46, 154}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_SIGNATURE_ALGORITHM | |
| {"UNSUPPORTED_SIGNATURE_ALGORITHM", ERR_LIB_CMS, CMS_R_UNSUPPORTED_SIGNATURE_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_SIGNATURE_ALGORITHM", 46, 195}, | |
| #endif | |
| #ifdef CMS_R_UNSUPPORTED_TYPE | |
| {"UNSUPPORTED_TYPE", ERR_LIB_CMS, CMS_R_UNSUPPORTED_TYPE}, | |
| #else | |
| {"UNSUPPORTED_TYPE", 46, 156}, | |
| #endif | |
| #ifdef CMS_R_UNWRAP_ERROR | |
| {"UNWRAP_ERROR", ERR_LIB_CMS, CMS_R_UNWRAP_ERROR}, | |
| #else | |
| {"UNWRAP_ERROR", 46, 157}, | |
| #endif | |
| #ifdef CMS_R_UNWRAP_FAILURE | |
| {"UNWRAP_FAILURE", ERR_LIB_CMS, CMS_R_UNWRAP_FAILURE}, | |
| #else | |
| {"UNWRAP_FAILURE", 46, 180}, | |
| #endif | |
| #ifdef CMS_R_VERIFICATION_FAILURE | |
| {"VERIFICATION_FAILURE", ERR_LIB_CMS, CMS_R_VERIFICATION_FAILURE}, | |
| #else | |
| {"VERIFICATION_FAILURE", 46, 158}, | |
| #endif | |
| #ifdef CMS_R_WRAP_ERROR | |
| {"WRAP_ERROR", ERR_LIB_CMS, CMS_R_WRAP_ERROR}, | |
| #else | |
| {"WRAP_ERROR", 46, 159}, | |
| #endif | |
| #ifdef COMP_R_BROTLI_DECODE_ERROR | |
| {"BROTLI_DECODE_ERROR", ERR_LIB_COMP, COMP_R_BROTLI_DECODE_ERROR}, | |
| #else | |
| {"BROTLI_DECODE_ERROR", 41, 102}, | |
| #endif | |
| #ifdef COMP_R_BROTLI_ENCODE_ERROR | |
| {"BROTLI_ENCODE_ERROR", ERR_LIB_COMP, COMP_R_BROTLI_ENCODE_ERROR}, | |
| #else | |
| {"BROTLI_ENCODE_ERROR", 41, 103}, | |
| #endif | |
| #ifdef COMP_R_BROTLI_NOT_SUPPORTED | |
| {"BROTLI_NOT_SUPPORTED", ERR_LIB_COMP, COMP_R_BROTLI_NOT_SUPPORTED}, | |
| #else | |
| {"BROTLI_NOT_SUPPORTED", 41, 104}, | |
| #endif | |
| #ifdef COMP_R_ZLIB_DEFLATE_ERROR | |
| {"ZLIB_DEFLATE_ERROR", ERR_LIB_COMP, COMP_R_ZLIB_DEFLATE_ERROR}, | |
| #else | |
| {"ZLIB_DEFLATE_ERROR", 41, 99}, | |
| #endif | |
| #ifdef COMP_R_ZLIB_INFLATE_ERROR | |
| {"ZLIB_INFLATE_ERROR", ERR_LIB_COMP, COMP_R_ZLIB_INFLATE_ERROR}, | |
| #else | |
| {"ZLIB_INFLATE_ERROR", 41, 100}, | |
| #endif | |
| #ifdef COMP_R_ZLIB_NOT_SUPPORTED | |
| {"ZLIB_NOT_SUPPORTED", ERR_LIB_COMP, COMP_R_ZLIB_NOT_SUPPORTED}, | |
| #else | |
| {"ZLIB_NOT_SUPPORTED", 41, 101}, | |
| #endif | |
| #ifdef COMP_R_ZSTD_COMPRESS_ERROR | |
| {"ZSTD_COMPRESS_ERROR", ERR_LIB_COMP, COMP_R_ZSTD_COMPRESS_ERROR}, | |
| #else | |
| {"ZSTD_COMPRESS_ERROR", 41, 105}, | |
| #endif | |
| #ifdef COMP_R_ZSTD_DECODE_ERROR | |
| {"ZSTD_DECODE_ERROR", ERR_LIB_COMP, COMP_R_ZSTD_DECODE_ERROR}, | |
| #else | |
| {"ZSTD_DECODE_ERROR", 41, 106}, | |
| #endif | |
| #ifdef COMP_R_ZSTD_DECOMPRESS_ERROR | |
| {"ZSTD_DECOMPRESS_ERROR", ERR_LIB_COMP, COMP_R_ZSTD_DECOMPRESS_ERROR}, | |
| #else | |
| {"ZSTD_DECOMPRESS_ERROR", 41, 107}, | |
| #endif | |
| #ifdef COMP_R_ZSTD_NOT_SUPPORTED | |
| {"ZSTD_NOT_SUPPORTED", ERR_LIB_COMP, COMP_R_ZSTD_NOT_SUPPORTED}, | |
| #else | |
| {"ZSTD_NOT_SUPPORTED", 41, 108}, | |
| #endif | |
| #ifdef CONF_R_ERROR_LOADING_DSO | |
| {"ERROR_LOADING_DSO", ERR_LIB_CONF, CONF_R_ERROR_LOADING_DSO}, | |
| #else | |
| {"ERROR_LOADING_DSO", 14, 110}, | |
| #endif | |
| #ifdef CONF_R_INVALID_PRAGMA | |
| {"INVALID_PRAGMA", ERR_LIB_CONF, CONF_R_INVALID_PRAGMA}, | |
| #else | |
| {"INVALID_PRAGMA", 14, 122}, | |
| #endif | |
| #ifdef CONF_R_LIST_CANNOT_BE_NULL | |
| {"LIST_CANNOT_BE_NULL", ERR_LIB_CONF, CONF_R_LIST_CANNOT_BE_NULL}, | |
| #else | |
| {"LIST_CANNOT_BE_NULL", 14, 115}, | |
| #endif | |
| #ifdef CONF_R_MANDATORY_BRACES_IN_VARIABLE_EXPANSION | |
| {"MANDATORY_BRACES_IN_VARIABLE_EXPANSION", ERR_LIB_CONF, CONF_R_MANDATORY_BRACES_IN_VARIABLE_EXPANSION}, | |
| #else | |
| {"MANDATORY_BRACES_IN_VARIABLE_EXPANSION", 14, 123}, | |
| #endif | |
| #ifdef CONF_R_MISSING_CLOSE_SQUARE_BRACKET | |
| {"MISSING_CLOSE_SQUARE_BRACKET", ERR_LIB_CONF, CONF_R_MISSING_CLOSE_SQUARE_BRACKET}, | |
| #else | |
| {"MISSING_CLOSE_SQUARE_BRACKET", 14, 100}, | |
| #endif | |
| #ifdef CONF_R_MISSING_EQUAL_SIGN | |
| {"MISSING_EQUAL_SIGN", ERR_LIB_CONF, CONF_R_MISSING_EQUAL_SIGN}, | |
| #else | |
| {"MISSING_EQUAL_SIGN", 14, 101}, | |
| #endif | |
| #ifdef CONF_R_MISSING_INIT_FUNCTION | |
| {"MISSING_INIT_FUNCTION", ERR_LIB_CONF, CONF_R_MISSING_INIT_FUNCTION}, | |
| #else | |
| {"MISSING_INIT_FUNCTION", 14, 112}, | |
| #endif | |
| #ifdef CONF_R_MODULE_INITIALIZATION_ERROR | |
| {"MODULE_INITIALIZATION_ERROR", ERR_LIB_CONF, CONF_R_MODULE_INITIALIZATION_ERROR}, | |
| #else | |
| {"MODULE_INITIALIZATION_ERROR", 14, 109}, | |
| #endif | |
| #ifdef CONF_R_NO_CLOSE_BRACE | |
| {"NO_CLOSE_BRACE", ERR_LIB_CONF, CONF_R_NO_CLOSE_BRACE}, | |
| #else | |
| {"NO_CLOSE_BRACE", 14, 102}, | |
| #endif | |
| #ifdef CONF_R_NO_CONF | |
| {"NO_CONF", ERR_LIB_CONF, CONF_R_NO_CONF}, | |
| #else | |
| {"NO_CONF", 14, 105}, | |
| #endif | |
| #ifdef CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE | |
| {"NO_CONF_OR_ENVIRONMENT_VARIABLE", ERR_LIB_CONF, CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE}, | |
| #else | |
| {"NO_CONF_OR_ENVIRONMENT_VARIABLE", 14, 106}, | |
| #endif | |
| #ifdef CONF_R_NO_SECTION | |
| {"NO_SECTION", ERR_LIB_CONF, CONF_R_NO_SECTION}, | |
| #else | |
| {"NO_SECTION", 14, 107}, | |
| #endif | |
| #ifdef CONF_R_NO_SUCH_FILE | |
| {"NO_SUCH_FILE", ERR_LIB_CONF, CONF_R_NO_SUCH_FILE}, | |
| #else | |
| {"NO_SUCH_FILE", 14, 114}, | |
| #endif | |
| #ifdef CONF_R_NO_VALUE | |
| {"NO_VALUE", ERR_LIB_CONF, CONF_R_NO_VALUE}, | |
| #else | |
| {"NO_VALUE", 14, 108}, | |
| #endif | |
| #ifdef CONF_R_NUMBER_TOO_LARGE | |
| {"NUMBER_TOO_LARGE", ERR_LIB_CONF, CONF_R_NUMBER_TOO_LARGE}, | |
| #else | |
| {"NUMBER_TOO_LARGE", 14, 121}, | |
| #endif | |
| #ifdef CONF_R_OPENSSL_CONF_REFERENCES_MISSING_SECTION | |
| {"OPENSSL_CONF_REFERENCES_MISSING_SECTION", ERR_LIB_CONF, CONF_R_OPENSSL_CONF_REFERENCES_MISSING_SECTION}, | |
| #else | |
| {"OPENSSL_CONF_REFERENCES_MISSING_SECTION", 14, 124}, | |
| #endif | |
| #ifdef CONF_R_RECURSIVE_DIRECTORY_INCLUDE | |
| {"RECURSIVE_DIRECTORY_INCLUDE", ERR_LIB_CONF, CONF_R_RECURSIVE_DIRECTORY_INCLUDE}, | |
| #else | |
| {"RECURSIVE_DIRECTORY_INCLUDE", 14, 111}, | |
| #endif | |
| #ifdef CONF_R_RECURSIVE_SECTION_REFERENCE | |
| {"RECURSIVE_SECTION_REFERENCE", ERR_LIB_CONF, CONF_R_RECURSIVE_SECTION_REFERENCE}, | |
| #else | |
| {"RECURSIVE_SECTION_REFERENCE", 14, 126}, | |
| #endif | |
| #ifdef CONF_R_RELATIVE_PATH | |
| {"RELATIVE_PATH", ERR_LIB_CONF, CONF_R_RELATIVE_PATH}, | |
| #else | |
| {"RELATIVE_PATH", 14, 125}, | |
| #endif | |
| #ifdef CONF_R_SSL_COMMAND_SECTION_EMPTY | |
| {"SSL_COMMAND_SECTION_EMPTY", ERR_LIB_CONF, CONF_R_SSL_COMMAND_SECTION_EMPTY}, | |
| #else | |
| {"SSL_COMMAND_SECTION_EMPTY", 14, 117}, | |
| #endif | |
| #ifdef CONF_R_SSL_COMMAND_SECTION_NOT_FOUND | |
| {"SSL_COMMAND_SECTION_NOT_FOUND", ERR_LIB_CONF, CONF_R_SSL_COMMAND_SECTION_NOT_FOUND}, | |
| #else | |
| {"SSL_COMMAND_SECTION_NOT_FOUND", 14, 118}, | |
| #endif | |
| #ifdef CONF_R_SSL_SECTION_EMPTY | |
| {"SSL_SECTION_EMPTY", ERR_LIB_CONF, CONF_R_SSL_SECTION_EMPTY}, | |
| #else | |
| {"SSL_SECTION_EMPTY", 14, 119}, | |
| #endif | |
| #ifdef CONF_R_SSL_SECTION_NOT_FOUND | |
| {"SSL_SECTION_NOT_FOUND", ERR_LIB_CONF, CONF_R_SSL_SECTION_NOT_FOUND}, | |
| #else | |
| {"SSL_SECTION_NOT_FOUND", 14, 120}, | |
| #endif | |
| #ifdef CONF_R_UNABLE_TO_CREATE_NEW_SECTION | |
| {"UNABLE_TO_CREATE_NEW_SECTION", ERR_LIB_CONF, CONF_R_UNABLE_TO_CREATE_NEW_SECTION}, | |
| #else | |
| {"UNABLE_TO_CREATE_NEW_SECTION", 14, 103}, | |
| #endif | |
| #ifdef CONF_R_UNKNOWN_MODULE_NAME | |
| {"UNKNOWN_MODULE_NAME", ERR_LIB_CONF, CONF_R_UNKNOWN_MODULE_NAME}, | |
| #else | |
| {"UNKNOWN_MODULE_NAME", 14, 113}, | |
| #endif | |
| #ifdef CONF_R_VARIABLE_EXPANSION_TOO_LONG | |
| {"VARIABLE_EXPANSION_TOO_LONG", ERR_LIB_CONF, CONF_R_VARIABLE_EXPANSION_TOO_LONG}, | |
| #else | |
| {"VARIABLE_EXPANSION_TOO_LONG", 14, 116}, | |
| #endif | |
| #ifdef CONF_R_VARIABLE_HAS_NO_VALUE | |
| {"VARIABLE_HAS_NO_VALUE", ERR_LIB_CONF, CONF_R_VARIABLE_HAS_NO_VALUE}, | |
| #else | |
| {"VARIABLE_HAS_NO_VALUE", 14, 104}, | |
| #endif | |
| #ifdef CRMF_R_BAD_PBM_ITERATIONCOUNT | |
| {"BAD_PBM_ITERATIONCOUNT", ERR_LIB_CRMF, CRMF_R_BAD_PBM_ITERATIONCOUNT}, | |
| #else | |
| {"BAD_PBM_ITERATIONCOUNT", 56, 100}, | |
| #endif | |
| #ifdef CRMF_R_CMS_NOT_SUPPORTED | |
| {"CMS_NOT_SUPPORTED", ERR_LIB_CRMF, CRMF_R_CMS_NOT_SUPPORTED}, | |
| #else | |
| {"CMS_NOT_SUPPORTED", 56, 122}, | |
| #endif | |
| #ifdef CRMF_R_CRMFERROR | |
| {"CRMFERROR", ERR_LIB_CRMF, CRMF_R_CRMFERROR}, | |
| #else | |
| {"CRMFERROR", 56, 102}, | |
| #endif | |
| #ifdef CRMF_R_ERROR | |
| {"ERROR", ERR_LIB_CRMF, CRMF_R_ERROR}, | |
| #else | |
| {"ERROR", 56, 103}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECODING_CERTIFICATE | |
| {"ERROR_DECODING_CERTIFICATE", ERR_LIB_CRMF, CRMF_R_ERROR_DECODING_CERTIFICATE}, | |
| #else | |
| {"ERROR_DECODING_CERTIFICATE", 56, 104}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECODING_ENCRYPTEDKEY | |
| {"ERROR_DECODING_ENCRYPTEDKEY", ERR_LIB_CRMF, CRMF_R_ERROR_DECODING_ENCRYPTEDKEY}, | |
| #else | |
| {"ERROR_DECODING_ENCRYPTEDKEY", 56, 123}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECRYPTING_CERTIFICATE | |
| {"ERROR_DECRYPTING_CERTIFICATE", ERR_LIB_CRMF, CRMF_R_ERROR_DECRYPTING_CERTIFICATE}, | |
| #else | |
| {"ERROR_DECRYPTING_CERTIFICATE", 56, 105}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECRYPTING_ENCRYPTEDKEY | |
| {"ERROR_DECRYPTING_ENCRYPTEDKEY", ERR_LIB_CRMF, CRMF_R_ERROR_DECRYPTING_ENCRYPTEDKEY}, | |
| #else | |
| {"ERROR_DECRYPTING_ENCRYPTEDKEY", 56, 124}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECRYPTING_ENCRYPTEDVALUE | |
| {"ERROR_DECRYPTING_ENCRYPTEDVALUE", ERR_LIB_CRMF, CRMF_R_ERROR_DECRYPTING_ENCRYPTEDVALUE}, | |
| #else | |
| {"ERROR_DECRYPTING_ENCRYPTEDVALUE", 56, 125}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_DECRYPTING_SYMMETRIC_KEY | |
| {"ERROR_DECRYPTING_SYMMETRIC_KEY", ERR_LIB_CRMF, CRMF_R_ERROR_DECRYPTING_SYMMETRIC_KEY}, | |
| #else | |
| {"ERROR_DECRYPTING_SYMMETRIC_KEY", 56, 106}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_SETTING_PURPOSE | |
| {"ERROR_SETTING_PURPOSE", ERR_LIB_CRMF, CRMF_R_ERROR_SETTING_PURPOSE}, | |
| #else | |
| {"ERROR_SETTING_PURPOSE", 56, 126}, | |
| #endif | |
| #ifdef CRMF_R_ERROR_VERIFYING_ENCRYPTEDKEY | |
| {"ERROR_VERIFYING_ENCRYPTEDKEY", ERR_LIB_CRMF, CRMF_R_ERROR_VERIFYING_ENCRYPTEDKEY}, | |
| #else | |
| {"ERROR_VERIFYING_ENCRYPTEDKEY", 56, 127}, | |
| #endif | |
| #ifdef CRMF_R_FAILURE_OBTAINING_RANDOM | |
| {"FAILURE_OBTAINING_RANDOM", ERR_LIB_CRMF, CRMF_R_FAILURE_OBTAINING_RANDOM}, | |
| #else | |
| {"FAILURE_OBTAINING_RANDOM", 56, 107}, | |
| #endif | |
| #ifdef CRMF_R_ITERATIONCOUNT_BELOW_100 | |
| {"ITERATIONCOUNT_BELOW_100", ERR_LIB_CRMF, CRMF_R_ITERATIONCOUNT_BELOW_100}, | |
| #else | |
| {"ITERATIONCOUNT_BELOW_100", 56, 108}, | |
| #endif | |
| #ifdef CRMF_R_MALFORMED_IV | |
| {"MALFORMED_IV", ERR_LIB_CRMF, CRMF_R_MALFORMED_IV}, | |
| #else | |
| {"MALFORMED_IV", 56, 101}, | |
| #endif | |
| #ifdef CRMF_R_NULL_ARGUMENT | |
| {"NULL_ARGUMENT", ERR_LIB_CRMF, CRMF_R_NULL_ARGUMENT}, | |
| #else | |
| {"NULL_ARGUMENT", 56, 109}, | |
| #endif | |
| #ifdef CRMF_R_POPOSKINPUT_NOT_SUPPORTED | |
| {"POPOSKINPUT_NOT_SUPPORTED", ERR_LIB_CRMF, CRMF_R_POPOSKINPUT_NOT_SUPPORTED}, | |
| #else | |
| {"POPOSKINPUT_NOT_SUPPORTED", 56, 113}, | |
| #endif | |
| #ifdef CRMF_R_POPO_INCONSISTENT_CENTRAL_KEYGEN | |
| {"POPO_INCONSISTENT_CENTRAL_KEYGEN", ERR_LIB_CRMF, CRMF_R_POPO_INCONSISTENT_CENTRAL_KEYGEN}, | |
| #else | |
| {"POPO_INCONSISTENT_CENTRAL_KEYGEN", 56, 128}, | |
| #endif | |
| #ifdef CRMF_R_POPO_INCONSISTENT_PUBLIC_KEY | |
| {"POPO_INCONSISTENT_PUBLIC_KEY", ERR_LIB_CRMF, CRMF_R_POPO_INCONSISTENT_PUBLIC_KEY}, | |
| #else | |
| {"POPO_INCONSISTENT_PUBLIC_KEY", 56, 117}, | |
| #endif | |
| #ifdef CRMF_R_POPO_MISSING | |
| {"POPO_MISSING", ERR_LIB_CRMF, CRMF_R_POPO_MISSING}, | |
| #else | |
| {"POPO_MISSING", 56, 121}, | |
| #endif | |
| #ifdef CRMF_R_POPO_MISSING_PUBLIC_KEY | |
| {"POPO_MISSING_PUBLIC_KEY", ERR_LIB_CRMF, CRMF_R_POPO_MISSING_PUBLIC_KEY}, | |
| #else | |
| {"POPO_MISSING_PUBLIC_KEY", 56, 118}, | |
| #endif | |
| #ifdef CRMF_R_POPO_MISSING_SUBJECT | |
| {"POPO_MISSING_SUBJECT", ERR_LIB_CRMF, CRMF_R_POPO_MISSING_SUBJECT}, | |
| #else | |
| {"POPO_MISSING_SUBJECT", 56, 119}, | |
| #endif | |
| #ifdef CRMF_R_POPO_RAVERIFIED_NOT_ACCEPTED | |
| {"POPO_RAVERIFIED_NOT_ACCEPTED", ERR_LIB_CRMF, CRMF_R_POPO_RAVERIFIED_NOT_ACCEPTED}, | |
| #else | |
| {"POPO_RAVERIFIED_NOT_ACCEPTED", 56, 120}, | |
| #endif | |
| #ifdef CRMF_R_SETTING_MAC_ALGOR_FAILURE | |
| {"SETTING_MAC_ALGOR_FAILURE", ERR_LIB_CRMF, CRMF_R_SETTING_MAC_ALGOR_FAILURE}, | |
| #else | |
| {"SETTING_MAC_ALGOR_FAILURE", 56, 110}, | |
| #endif | |
| #ifdef CRMF_R_SETTING_OWF_ALGOR_FAILURE | |
| {"SETTING_OWF_ALGOR_FAILURE", ERR_LIB_CRMF, CRMF_R_SETTING_OWF_ALGOR_FAILURE}, | |
| #else | |
| {"SETTING_OWF_ALGOR_FAILURE", 56, 111}, | |
| #endif | |
| #ifdef CRMF_R_UNSUPPORTED_ALGORITHM | |
| {"UNSUPPORTED_ALGORITHM", ERR_LIB_CRMF, CRMF_R_UNSUPPORTED_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_ALGORITHM", 56, 112}, | |
| #endif | |
| #ifdef CRMF_R_UNSUPPORTED_CIPHER | |
| {"UNSUPPORTED_CIPHER", ERR_LIB_CRMF, CRMF_R_UNSUPPORTED_CIPHER}, | |
| #else | |
| {"UNSUPPORTED_CIPHER", 56, 114}, | |
| #endif | |
| #ifdef CRMF_R_UNSUPPORTED_METHOD_FOR_CREATING_POPO | |
| {"UNSUPPORTED_METHOD_FOR_CREATING_POPO", ERR_LIB_CRMF, CRMF_R_UNSUPPORTED_METHOD_FOR_CREATING_POPO}, | |
| #else | |
| {"UNSUPPORTED_METHOD_FOR_CREATING_POPO", 56, 115}, | |
| #endif | |
| #ifdef CRMF_R_UNSUPPORTED_POPO_METHOD | |
| {"UNSUPPORTED_POPO_METHOD", ERR_LIB_CRMF, CRMF_R_UNSUPPORTED_POPO_METHOD}, | |
| #else | |
| {"UNSUPPORTED_POPO_METHOD", 56, 116}, | |
| #endif | |
| #ifdef CRYPTO_R_BAD_ALGORITHM_NAME | |
| {"BAD_ALGORITHM_NAME", ERR_LIB_CRYPTO, CRYPTO_R_BAD_ALGORITHM_NAME}, | |
| #else | |
| {"BAD_ALGORITHM_NAME", 15, 117}, | |
| #endif | |
| #ifdef CRYPTO_R_CONFLICTING_NAMES | |
| {"CONFLICTING_NAMES", ERR_LIB_CRYPTO, CRYPTO_R_CONFLICTING_NAMES}, | |
| #else | |
| {"CONFLICTING_NAMES", 15, 118}, | |
| #endif | |
| #ifdef CRYPTO_R_HEX_STRING_TOO_SHORT | |
| {"HEX_STRING_TOO_SHORT", ERR_LIB_CRYPTO, CRYPTO_R_HEX_STRING_TOO_SHORT}, | |
| #else | |
| {"HEX_STRING_TOO_SHORT", 15, 121}, | |
| #endif | |
| #ifdef CRYPTO_R_ILLEGAL_HEX_DIGIT | |
| {"ILLEGAL_HEX_DIGIT", ERR_LIB_CRYPTO, CRYPTO_R_ILLEGAL_HEX_DIGIT}, | |
| #else | |
| {"ILLEGAL_HEX_DIGIT", 15, 102}, | |
| #endif | |
| #ifdef CRYPTO_R_INSUFFICIENT_DATA_SPACE | |
| {"INSUFFICIENT_DATA_SPACE", ERR_LIB_CRYPTO, CRYPTO_R_INSUFFICIENT_DATA_SPACE}, | |
| #else | |
| {"INSUFFICIENT_DATA_SPACE", 15, 106}, | |
| #endif | |
| #ifdef CRYPTO_R_INSUFFICIENT_PARAM_SIZE | |
| {"INSUFFICIENT_PARAM_SIZE", ERR_LIB_CRYPTO, CRYPTO_R_INSUFFICIENT_PARAM_SIZE}, | |
| #else | |
| {"INSUFFICIENT_PARAM_SIZE", 15, 107}, | |
| #endif | |
| #ifdef CRYPTO_R_INSUFFICIENT_SECURE_DATA_SPACE | |
| {"INSUFFICIENT_SECURE_DATA_SPACE", ERR_LIB_CRYPTO, CRYPTO_R_INSUFFICIENT_SECURE_DATA_SPACE}, | |
| #else | |
| {"INSUFFICIENT_SECURE_DATA_SPACE", 15, 108}, | |
| #endif | |
| #ifdef CRYPTO_R_INTEGER_OVERFLOW | |
| {"INTEGER_OVERFLOW", ERR_LIB_CRYPTO, CRYPTO_R_INTEGER_OVERFLOW}, | |
| #else | |
| {"INTEGER_OVERFLOW", 15, 127}, | |
| #endif | |
| #ifdef CRYPTO_R_INVALID_NEGATIVE_VALUE | |
| {"INVALID_NEGATIVE_VALUE", ERR_LIB_CRYPTO, CRYPTO_R_INVALID_NEGATIVE_VALUE}, | |
| #else | |
| {"INVALID_NEGATIVE_VALUE", 15, 122}, | |
| #endif | |
| #ifdef CRYPTO_R_INVALID_NULL_ARGUMENT | |
| {"INVALID_NULL_ARGUMENT", ERR_LIB_CRYPTO, CRYPTO_R_INVALID_NULL_ARGUMENT}, | |
| #else | |
| {"INVALID_NULL_ARGUMENT", 15, 109}, | |
| #endif | |
| #ifdef CRYPTO_R_INVALID_OSSL_PARAM_TYPE | |
| {"INVALID_OSSL_PARAM_TYPE", ERR_LIB_CRYPTO, CRYPTO_R_INVALID_OSSL_PARAM_TYPE}, | |
| #else | |
| {"INVALID_OSSL_PARAM_TYPE", 15, 110}, | |
| #endif | |
| #ifdef CRYPTO_R_NO_PARAMS_TO_MERGE | |
| {"NO_PARAMS_TO_MERGE", ERR_LIB_CRYPTO, CRYPTO_R_NO_PARAMS_TO_MERGE}, | |
| #else | |
| {"NO_PARAMS_TO_MERGE", 15, 131}, | |
| #endif | |
| #ifdef CRYPTO_R_NO_SPACE_FOR_TERMINATING_NULL | |
| {"NO_SPACE_FOR_TERMINATING_NULL", ERR_LIB_CRYPTO, CRYPTO_R_NO_SPACE_FOR_TERMINATING_NULL}, | |
| #else | |
| {"NO_SPACE_FOR_TERMINATING_NULL", 15, 128}, | |
| #endif | |
| #ifdef CRYPTO_R_ODD_NUMBER_OF_DIGITS | |
| {"ODD_NUMBER_OF_DIGITS", ERR_LIB_CRYPTO, CRYPTO_R_ODD_NUMBER_OF_DIGITS}, | |
| #else | |
| {"ODD_NUMBER_OF_DIGITS", 15, 103}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_CANNOT_BE_REPRESENTED_EXACTLY | |
| {"PARAM_CANNOT_BE_REPRESENTED_EXACTLY", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_CANNOT_BE_REPRESENTED_EXACTLY}, | |
| #else | |
| {"PARAM_CANNOT_BE_REPRESENTED_EXACTLY", 15, 123}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_NOT_INTEGER_TYPE | |
| {"PARAM_NOT_INTEGER_TYPE", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_NOT_INTEGER_TYPE}, | |
| #else | |
| {"PARAM_NOT_INTEGER_TYPE", 15, 124}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_OF_INCOMPATIBLE_TYPE | |
| {"PARAM_OF_INCOMPATIBLE_TYPE", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_OF_INCOMPATIBLE_TYPE}, | |
| #else | |
| {"PARAM_OF_INCOMPATIBLE_TYPE", 15, 129}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_UNSIGNED_INTEGER_NEGATIVE_VALUE_UNSUPPORTED | |
| {"PARAM_UNSIGNED_INTEGER_NEGATIVE_VALUE_UNSUPPORTED", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_UNSIGNED_INTEGER_NEGATIVE_VALUE_UNSUPPORTED}, | |
| #else | |
| {"PARAM_UNSIGNED_INTEGER_NEGATIVE_VALUE_UNSUPPORTED", 15, 125}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_UNSUPPORTED_FLOATING_POINT_FORMAT | |
| {"PARAM_UNSUPPORTED_FLOATING_POINT_FORMAT", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_UNSUPPORTED_FLOATING_POINT_FORMAT}, | |
| #else | |
| {"PARAM_UNSUPPORTED_FLOATING_POINT_FORMAT", 15, 130}, | |
| #endif | |
| #ifdef CRYPTO_R_PARAM_VALUE_TOO_LARGE_FOR_DESTINATION | |
| {"PARAM_VALUE_TOO_LARGE_FOR_DESTINATION", ERR_LIB_CRYPTO, CRYPTO_R_PARAM_VALUE_TOO_LARGE_FOR_DESTINATION}, | |
| #else | |
| {"PARAM_VALUE_TOO_LARGE_FOR_DESTINATION", 15, 126}, | |
| #endif | |
| #ifdef CRYPTO_R_PROVIDER_ALREADY_EXISTS | |
| {"PROVIDER_ALREADY_EXISTS", ERR_LIB_CRYPTO, CRYPTO_R_PROVIDER_ALREADY_EXISTS}, | |
| #else | |
| {"PROVIDER_ALREADY_EXISTS", 15, 104}, | |
| #endif | |
| #ifdef CRYPTO_R_PROVIDER_SECTION_ERROR | |
| {"PROVIDER_SECTION_ERROR", ERR_LIB_CRYPTO, CRYPTO_R_PROVIDER_SECTION_ERROR}, | |
| #else | |
| {"PROVIDER_SECTION_ERROR", 15, 105}, | |
| #endif | |
| #ifdef CRYPTO_R_RANDOM_SECTION_ERROR | |
| {"RANDOM_SECTION_ERROR", ERR_LIB_CRYPTO, CRYPTO_R_RANDOM_SECTION_ERROR}, | |
| #else | |
| {"RANDOM_SECTION_ERROR", 15, 119}, | |
| #endif | |
| #ifdef CRYPTO_R_SECURE_MALLOC_FAILURE | |
| {"SECURE_MALLOC_FAILURE", ERR_LIB_CRYPTO, CRYPTO_R_SECURE_MALLOC_FAILURE}, | |
| #else | |
| {"SECURE_MALLOC_FAILURE", 15, 111}, | |
| #endif | |
| #ifdef CRYPTO_R_STRING_TOO_LONG | |
| {"STRING_TOO_LONG", ERR_LIB_CRYPTO, CRYPTO_R_STRING_TOO_LONG}, | |
| #else | |
| {"STRING_TOO_LONG", 15, 112}, | |
| #endif | |
| #ifdef CRYPTO_R_TOO_MANY_BYTES | |
| {"TOO_MANY_BYTES", ERR_LIB_CRYPTO, CRYPTO_R_TOO_MANY_BYTES}, | |
| #else | |
| {"TOO_MANY_BYTES", 15, 113}, | |
| #endif | |
| #ifdef CRYPTO_R_TOO_MANY_NAMES | |
| {"TOO_MANY_NAMES", ERR_LIB_CRYPTO, CRYPTO_R_TOO_MANY_NAMES}, | |
| #else | |
| {"TOO_MANY_NAMES", 15, 132}, | |
| #endif | |
| #ifdef CRYPTO_R_TOO_MANY_RECORDS | |
| {"TOO_MANY_RECORDS", ERR_LIB_CRYPTO, CRYPTO_R_TOO_MANY_RECORDS}, | |
| #else | |
| {"TOO_MANY_RECORDS", 15, 114}, | |
| #endif | |
| #ifdef CRYPTO_R_TOO_SMALL_BUFFER | |
| {"TOO_SMALL_BUFFER", ERR_LIB_CRYPTO, CRYPTO_R_TOO_SMALL_BUFFER}, | |
| #else | |
| {"TOO_SMALL_BUFFER", 15, 116}, | |
| #endif | |
| #ifdef CRYPTO_R_UNKNOWN_NAME_IN_RANDOM_SECTION | |
| {"UNKNOWN_NAME_IN_RANDOM_SECTION", ERR_LIB_CRYPTO, CRYPTO_R_UNKNOWN_NAME_IN_RANDOM_SECTION}, | |
| #else | |
| {"UNKNOWN_NAME_IN_RANDOM_SECTION", 15, 120}, | |
| #endif | |
| #ifdef CRYPTO_R_ZERO_LENGTH_NUMBER | |
| {"ZERO_LENGTH_NUMBER", ERR_LIB_CRYPTO, CRYPTO_R_ZERO_LENGTH_NUMBER}, | |
| #else | |
| {"ZERO_LENGTH_NUMBER", 15, 115}, | |
| #endif | |
| #ifdef CT_R_BASE64_DECODE_ERROR | |
| {"BASE64_DECODE_ERROR", ERR_LIB_CT, CT_R_BASE64_DECODE_ERROR}, | |
| #else | |
| {"BASE64_DECODE_ERROR", 50, 108}, | |
| #endif | |
| #ifdef CT_R_INVALID_LOG_ID_LENGTH | |
| {"INVALID_LOG_ID_LENGTH", ERR_LIB_CT, CT_R_INVALID_LOG_ID_LENGTH}, | |
| #else | |
| {"INVALID_LOG_ID_LENGTH", 50, 100}, | |
| #endif | |
| #ifdef CT_R_LOG_CONF_INVALID | |
| {"LOG_CONF_INVALID", ERR_LIB_CT, CT_R_LOG_CONF_INVALID}, | |
| #else | |
| {"LOG_CONF_INVALID", 50, 109}, | |
| #endif | |
| #ifdef CT_R_LOG_CONF_INVALID_KEY | |
| {"LOG_CONF_INVALID_KEY", ERR_LIB_CT, CT_R_LOG_CONF_INVALID_KEY}, | |
| #else | |
| {"LOG_CONF_INVALID_KEY", 50, 110}, | |
| #endif | |
| #ifdef CT_R_LOG_CONF_MISSING_DESCRIPTION | |
| {"LOG_CONF_MISSING_DESCRIPTION", ERR_LIB_CT, CT_R_LOG_CONF_MISSING_DESCRIPTION}, | |
| #else | |
| {"LOG_CONF_MISSING_DESCRIPTION", 50, 111}, | |
| #endif | |
| #ifdef CT_R_LOG_CONF_MISSING_KEY | |
| {"LOG_CONF_MISSING_KEY", ERR_LIB_CT, CT_R_LOG_CONF_MISSING_KEY}, | |
| #else | |
| {"LOG_CONF_MISSING_KEY", 50, 112}, | |
| #endif | |
| #ifdef CT_R_LOG_KEY_INVALID | |
| {"LOG_KEY_INVALID", ERR_LIB_CT, CT_R_LOG_KEY_INVALID}, | |
| #else | |
| {"LOG_KEY_INVALID", 50, 113}, | |
| #endif | |
| #ifdef CT_R_SCT_FUTURE_TIMESTAMP | |
| {"SCT_FUTURE_TIMESTAMP", ERR_LIB_CT, CT_R_SCT_FUTURE_TIMESTAMP}, | |
| #else | |
| {"SCT_FUTURE_TIMESTAMP", 50, 116}, | |
| #endif | |
| #ifdef CT_R_SCT_INVALID | |
| {"SCT_INVALID", ERR_LIB_CT, CT_R_SCT_INVALID}, | |
| #else | |
| {"SCT_INVALID", 50, 104}, | |
| #endif | |
| #ifdef CT_R_SCT_INVALID_SIGNATURE | |
| {"SCT_INVALID_SIGNATURE", ERR_LIB_CT, CT_R_SCT_INVALID_SIGNATURE}, | |
| #else | |
| {"SCT_INVALID_SIGNATURE", 50, 107}, | |
| #endif | |
| #ifdef CT_R_SCT_LIST_INVALID | |
| {"SCT_LIST_INVALID", ERR_LIB_CT, CT_R_SCT_LIST_INVALID}, | |
| #else | |
| {"SCT_LIST_INVALID", 50, 105}, | |
| #endif | |
| #ifdef CT_R_SCT_LOG_ID_MISMATCH | |
| {"SCT_LOG_ID_MISMATCH", ERR_LIB_CT, CT_R_SCT_LOG_ID_MISMATCH}, | |
| #else | |
| {"SCT_LOG_ID_MISMATCH", 50, 114}, | |
| #endif | |
| #ifdef CT_R_SCT_NOT_SET | |
| {"SCT_NOT_SET", ERR_LIB_CT, CT_R_SCT_NOT_SET}, | |
| #else | |
| {"SCT_NOT_SET", 50, 106}, | |
| #endif | |
| #ifdef CT_R_SCT_UNSUPPORTED_VERSION | |
| {"SCT_UNSUPPORTED_VERSION", ERR_LIB_CT, CT_R_SCT_UNSUPPORTED_VERSION}, | |
| #else | |
| {"SCT_UNSUPPORTED_VERSION", 50, 115}, | |
| #endif | |
| #ifdef CT_R_UNRECOGNIZED_SIGNATURE_NID | |
| {"UNRECOGNIZED_SIGNATURE_NID", ERR_LIB_CT, CT_R_UNRECOGNIZED_SIGNATURE_NID}, | |
| #else | |
| {"UNRECOGNIZED_SIGNATURE_NID", 50, 101}, | |
| #endif | |
| #ifdef CT_R_UNSUPPORTED_ENTRY_TYPE | |
| {"UNSUPPORTED_ENTRY_TYPE", ERR_LIB_CT, CT_R_UNSUPPORTED_ENTRY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_ENTRY_TYPE", 50, 102}, | |
| #endif | |
| #ifdef CT_R_UNSUPPORTED_VERSION | |
| {"UNSUPPORTED_VERSION", ERR_LIB_CT, CT_R_UNSUPPORTED_VERSION}, | |
| #else | |
| {"UNSUPPORTED_VERSION", 50, 103}, | |
| #endif | |
| #ifdef DH_R_BAD_FFC_PARAMETERS | |
| {"BAD_FFC_PARAMETERS", ERR_LIB_DH, DH_R_BAD_FFC_PARAMETERS}, | |
| #else | |
| {"BAD_FFC_PARAMETERS", 5, 127}, | |
| #endif | |
| #ifdef DH_R_BAD_GENERATOR | |
| {"BAD_GENERATOR", ERR_LIB_DH, DH_R_BAD_GENERATOR}, | |
| #else | |
| {"BAD_GENERATOR", 5, 101}, | |
| #endif | |
| #ifdef DH_R_BN_DECODE_ERROR | |
| {"BN_DECODE_ERROR", ERR_LIB_DH, DH_R_BN_DECODE_ERROR}, | |
| #else | |
| {"BN_DECODE_ERROR", 5, 109}, | |
| #endif | |
| #ifdef DH_R_BN_ERROR | |
| {"BN_ERROR", ERR_LIB_DH, DH_R_BN_ERROR}, | |
| #else | |
| {"BN_ERROR", 5, 106}, | |
| #endif | |
| #ifdef DH_R_CHECK_INVALID_J_VALUE | |
| {"CHECK_INVALID_J_VALUE", ERR_LIB_DH, DH_R_CHECK_INVALID_J_VALUE}, | |
| #else | |
| {"CHECK_INVALID_J_VALUE", 5, 115}, | |
| #endif | |
| #ifdef DH_R_CHECK_INVALID_Q_VALUE | |
| {"CHECK_INVALID_Q_VALUE", ERR_LIB_DH, DH_R_CHECK_INVALID_Q_VALUE}, | |
| #else | |
| {"CHECK_INVALID_Q_VALUE", 5, 116}, | |
| #endif | |
| #ifdef DH_R_CHECK_PUBKEY_INVALID | |
| {"CHECK_PUBKEY_INVALID", ERR_LIB_DH, DH_R_CHECK_PUBKEY_INVALID}, | |
| #else | |
| {"CHECK_PUBKEY_INVALID", 5, 122}, | |
| #endif | |
| #ifdef DH_R_CHECK_PUBKEY_TOO_LARGE | |
| {"CHECK_PUBKEY_TOO_LARGE", ERR_LIB_DH, DH_R_CHECK_PUBKEY_TOO_LARGE}, | |
| #else | |
| {"CHECK_PUBKEY_TOO_LARGE", 5, 123}, | |
| #endif | |
| #ifdef DH_R_CHECK_PUBKEY_TOO_SMALL | |
| {"CHECK_PUBKEY_TOO_SMALL", ERR_LIB_DH, DH_R_CHECK_PUBKEY_TOO_SMALL}, | |
| #else | |
| {"CHECK_PUBKEY_TOO_SMALL", 5, 124}, | |
| #endif | |
| #ifdef DH_R_CHECK_P_NOT_PRIME | |
| {"CHECK_P_NOT_PRIME", ERR_LIB_DH, DH_R_CHECK_P_NOT_PRIME}, | |
| #else | |
| {"CHECK_P_NOT_PRIME", 5, 117}, | |
| #endif | |
| #ifdef DH_R_CHECK_P_NOT_SAFE_PRIME | |
| {"CHECK_P_NOT_SAFE_PRIME", ERR_LIB_DH, DH_R_CHECK_P_NOT_SAFE_PRIME}, | |
| #else | |
| {"CHECK_P_NOT_SAFE_PRIME", 5, 118}, | |
| #endif | |
| #ifdef DH_R_CHECK_Q_NOT_PRIME | |
| {"CHECK_Q_NOT_PRIME", ERR_LIB_DH, DH_R_CHECK_Q_NOT_PRIME}, | |
| #else | |
| {"CHECK_Q_NOT_PRIME", 5, 119}, | |
| #endif | |
| #ifdef DH_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_DH, DH_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 5, 104}, | |
| #endif | |
| #ifdef DH_R_INVALID_PARAMETER_NAME | |
| {"INVALID_PARAMETER_NAME", ERR_LIB_DH, DH_R_INVALID_PARAMETER_NAME}, | |
| #else | |
| {"INVALID_PARAMETER_NAME", 5, 110}, | |
| #endif | |
| #ifdef DH_R_INVALID_PARAMETER_NID | |
| {"INVALID_PARAMETER_NID", ERR_LIB_DH, DH_R_INVALID_PARAMETER_NID}, | |
| #else | |
| {"INVALID_PARAMETER_NID", 5, 114}, | |
| #endif | |
| #ifdef DH_R_INVALID_PUBKEY | |
| {"INVALID_PUBKEY", ERR_LIB_DH, DH_R_INVALID_PUBKEY}, | |
| #else | |
| {"INVALID_PUBKEY", 5, 102}, | |
| #endif | |
| #ifdef DH_R_INVALID_SECRET | |
| {"INVALID_SECRET", ERR_LIB_DH, DH_R_INVALID_SECRET}, | |
| #else | |
| {"INVALID_SECRET", 5, 128}, | |
| #endif | |
| #ifdef DH_R_INVALID_SIZE | |
| {"INVALID_SIZE", ERR_LIB_DH, DH_R_INVALID_SIZE}, | |
| #else | |
| {"INVALID_SIZE", 5, 129}, | |
| #endif | |
| #ifdef DH_R_KDF_PARAMETER_ERROR | |
| {"KDF_PARAMETER_ERROR", ERR_LIB_DH, DH_R_KDF_PARAMETER_ERROR}, | |
| #else | |
| {"KDF_PARAMETER_ERROR", 5, 112}, | |
| #endif | |
| #ifdef DH_R_KEYS_NOT_SET | |
| {"KEYS_NOT_SET", ERR_LIB_DH, DH_R_KEYS_NOT_SET}, | |
| #else | |
| {"KEYS_NOT_SET", 5, 108}, | |
| #endif | |
| #ifdef DH_R_MISSING_PUBKEY | |
| {"MISSING_PUBKEY", ERR_LIB_DH, DH_R_MISSING_PUBKEY}, | |
| #else | |
| {"MISSING_PUBKEY", 5, 125}, | |
| #endif | |
| #ifdef DH_R_MODULUS_TOO_LARGE | |
| {"MODULUS_TOO_LARGE", ERR_LIB_DH, DH_R_MODULUS_TOO_LARGE}, | |
| #else | |
| {"MODULUS_TOO_LARGE", 5, 103}, | |
| #endif | |
| #ifdef DH_R_MODULUS_TOO_SMALL | |
| {"MODULUS_TOO_SMALL", ERR_LIB_DH, DH_R_MODULUS_TOO_SMALL}, | |
| #else | |
| {"MODULUS_TOO_SMALL", 5, 126}, | |
| #endif | |
| #ifdef DH_R_NOT_SUITABLE_GENERATOR | |
| {"NOT_SUITABLE_GENERATOR", ERR_LIB_DH, DH_R_NOT_SUITABLE_GENERATOR}, | |
| #else | |
| {"NOT_SUITABLE_GENERATOR", 5, 120}, | |
| #endif | |
| #ifdef DH_R_NO_PARAMETERS_SET | |
| {"NO_PARAMETERS_SET", ERR_LIB_DH, DH_R_NO_PARAMETERS_SET}, | |
| #else | |
| {"NO_PARAMETERS_SET", 5, 107}, | |
| #endif | |
| #ifdef DH_R_NO_PRIVATE_VALUE | |
| {"NO_PRIVATE_VALUE", ERR_LIB_DH, DH_R_NO_PRIVATE_VALUE}, | |
| #else | |
| {"NO_PRIVATE_VALUE", 5, 100}, | |
| #endif | |
| #ifdef DH_R_PARAMETER_ENCODING_ERROR | |
| {"PARAMETER_ENCODING_ERROR", ERR_LIB_DH, DH_R_PARAMETER_ENCODING_ERROR}, | |
| #else | |
| {"PARAMETER_ENCODING_ERROR", 5, 105}, | |
| #endif | |
| #ifdef DH_R_PEER_KEY_ERROR | |
| {"PEER_KEY_ERROR", ERR_LIB_DH, DH_R_PEER_KEY_ERROR}, | |
| #else | |
| {"PEER_KEY_ERROR", 5, 111}, | |
| #endif | |
| #ifdef DH_R_Q_TOO_LARGE | |
| {"Q_TOO_LARGE", ERR_LIB_DH, DH_R_Q_TOO_LARGE}, | |
| #else | |
| {"Q_TOO_LARGE", 5, 130}, | |
| #endif | |
| #ifdef DH_R_SHARED_INFO_ERROR | |
| {"SHARED_INFO_ERROR", ERR_LIB_DH, DH_R_SHARED_INFO_ERROR}, | |
| #else | |
| {"SHARED_INFO_ERROR", 5, 113}, | |
| #endif | |
| #ifdef DH_R_UNABLE_TO_CHECK_GENERATOR | |
| {"UNABLE_TO_CHECK_GENERATOR", ERR_LIB_DH, DH_R_UNABLE_TO_CHECK_GENERATOR}, | |
| #else | |
| {"UNABLE_TO_CHECK_GENERATOR", 5, 121}, | |
| #endif | |
| #ifdef DSA_R_BAD_FFC_PARAMETERS | |
| {"BAD_FFC_PARAMETERS", ERR_LIB_DSA, DSA_R_BAD_FFC_PARAMETERS}, | |
| #else | |
| {"BAD_FFC_PARAMETERS", 10, 114}, | |
| #endif | |
| #ifdef DSA_R_BAD_Q_VALUE | |
| {"BAD_Q_VALUE", ERR_LIB_DSA, DSA_R_BAD_Q_VALUE}, | |
| #else | |
| {"BAD_Q_VALUE", 10, 102}, | |
| #endif | |
| #ifdef DSA_R_BN_DECODE_ERROR | |
| {"BN_DECODE_ERROR", ERR_LIB_DSA, DSA_R_BN_DECODE_ERROR}, | |
| #else | |
| {"BN_DECODE_ERROR", 10, 108}, | |
| #endif | |
| #ifdef DSA_R_BN_ERROR | |
| {"BN_ERROR", ERR_LIB_DSA, DSA_R_BN_ERROR}, | |
| #else | |
| {"BN_ERROR", 10, 109}, | |
| #endif | |
| #ifdef DSA_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_DSA, DSA_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 10, 104}, | |
| #endif | |
| #ifdef DSA_R_INVALID_DIGEST_TYPE | |
| {"INVALID_DIGEST_TYPE", ERR_LIB_DSA, DSA_R_INVALID_DIGEST_TYPE}, | |
| #else | |
| {"INVALID_DIGEST_TYPE", 10, 106}, | |
| #endif | |
| #ifdef DSA_R_INVALID_PARAMETERS | |
| {"INVALID_PARAMETERS", ERR_LIB_DSA, DSA_R_INVALID_PARAMETERS}, | |
| #else | |
| {"INVALID_PARAMETERS", 10, 112}, | |
| #endif | |
| #ifdef DSA_R_MISSING_PARAMETERS | |
| {"MISSING_PARAMETERS", ERR_LIB_DSA, DSA_R_MISSING_PARAMETERS}, | |
| #else | |
| {"MISSING_PARAMETERS", 10, 101}, | |
| #endif | |
| #ifdef DSA_R_MISSING_PRIVATE_KEY | |
| {"MISSING_PRIVATE_KEY", ERR_LIB_DSA, DSA_R_MISSING_PRIVATE_KEY}, | |
| #else | |
| {"MISSING_PRIVATE_KEY", 10, 111}, | |
| #endif | |
| #ifdef DSA_R_MODULUS_TOO_LARGE | |
| {"MODULUS_TOO_LARGE", ERR_LIB_DSA, DSA_R_MODULUS_TOO_LARGE}, | |
| #else | |
| {"MODULUS_TOO_LARGE", 10, 103}, | |
| #endif | |
| #ifdef DSA_R_NO_PARAMETERS_SET | |
| {"NO_PARAMETERS_SET", ERR_LIB_DSA, DSA_R_NO_PARAMETERS_SET}, | |
| #else | |
| {"NO_PARAMETERS_SET", 10, 107}, | |
| #endif | |
| #ifdef DSA_R_PARAMETER_ENCODING_ERROR | |
| {"PARAMETER_ENCODING_ERROR", ERR_LIB_DSA, DSA_R_PARAMETER_ENCODING_ERROR}, | |
| #else | |
| {"PARAMETER_ENCODING_ERROR", 10, 105}, | |
| #endif | |
| #ifdef DSA_R_P_NOT_PRIME | |
| {"P_NOT_PRIME", ERR_LIB_DSA, DSA_R_P_NOT_PRIME}, | |
| #else | |
| {"P_NOT_PRIME", 10, 115}, | |
| #endif | |
| #ifdef DSA_R_Q_NOT_PRIME | |
| {"Q_NOT_PRIME", ERR_LIB_DSA, DSA_R_Q_NOT_PRIME}, | |
| #else | |
| {"Q_NOT_PRIME", 10, 113}, | |
| #endif | |
| #ifdef DSA_R_SEED_LEN_SMALL | |
| {"SEED_LEN_SMALL", ERR_LIB_DSA, DSA_R_SEED_LEN_SMALL}, | |
| #else | |
| {"SEED_LEN_SMALL", 10, 110}, | |
| #endif | |
| #ifdef DSA_R_TOO_MANY_RETRIES | |
| {"TOO_MANY_RETRIES", ERR_LIB_DSA, DSA_R_TOO_MANY_RETRIES}, | |
| #else | |
| {"TOO_MANY_RETRIES", 10, 116}, | |
| #endif | |
| #ifdef DSO_R_CTRL_FAILED | |
| {"CTRL_FAILED", ERR_LIB_DSO, DSO_R_CTRL_FAILED}, | |
| #else | |
| {"CTRL_FAILED", 37, 100}, | |
| #endif | |
| #ifdef DSO_R_DSO_ALREADY_LOADED | |
| {"DSO_ALREADY_LOADED", ERR_LIB_DSO, DSO_R_DSO_ALREADY_LOADED}, | |
| #else | |
| {"DSO_ALREADY_LOADED", 37, 110}, | |
| #endif | |
| #ifdef DSO_R_EMPTY_FILE_STRUCTURE | |
| {"EMPTY_FILE_STRUCTURE", ERR_LIB_DSO, DSO_R_EMPTY_FILE_STRUCTURE}, | |
| #else | |
| {"EMPTY_FILE_STRUCTURE", 37, 113}, | |
| #endif | |
| #ifdef DSO_R_FAILURE | |
| {"FAILURE", ERR_LIB_DSO, DSO_R_FAILURE}, | |
| #else | |
| {"FAILURE", 37, 114}, | |
| #endif | |
| #ifdef DSO_R_FILENAME_TOO_BIG | |
| {"FILENAME_TOO_BIG", ERR_LIB_DSO, DSO_R_FILENAME_TOO_BIG}, | |
| #else | |
| {"FILENAME_TOO_BIG", 37, 101}, | |
| #endif | |
| #ifdef DSO_R_FINISH_FAILED | |
| {"FINISH_FAILED", ERR_LIB_DSO, DSO_R_FINISH_FAILED}, | |
| #else | |
| {"FINISH_FAILED", 37, 102}, | |
| #endif | |
| #ifdef DSO_R_INCORRECT_FILE_SYNTAX | |
| {"INCORRECT_FILE_SYNTAX", ERR_LIB_DSO, DSO_R_INCORRECT_FILE_SYNTAX}, | |
| #else | |
| {"INCORRECT_FILE_SYNTAX", 37, 115}, | |
| #endif | |
| #ifdef DSO_R_LOAD_FAILED | |
| {"LOAD_FAILED", ERR_LIB_DSO, DSO_R_LOAD_FAILED}, | |
| #else | |
| {"LOAD_FAILED", 37, 103}, | |
| #endif | |
| #ifdef DSO_R_NAME_TRANSLATION_FAILED | |
| {"NAME_TRANSLATION_FAILED", ERR_LIB_DSO, DSO_R_NAME_TRANSLATION_FAILED}, | |
| #else | |
| {"NAME_TRANSLATION_FAILED", 37, 109}, | |
| #endif | |
| #ifdef DSO_R_NO_FILENAME | |
| {"NO_FILENAME", ERR_LIB_DSO, DSO_R_NO_FILENAME}, | |
| #else | |
| {"NO_FILENAME", 37, 111}, | |
| #endif | |
| #ifdef DSO_R_NULL_HANDLE | |
| {"NULL_HANDLE", ERR_LIB_DSO, DSO_R_NULL_HANDLE}, | |
| #else | |
| {"NULL_HANDLE", 37, 104}, | |
| #endif | |
| #ifdef DSO_R_SET_FILENAME_FAILED | |
| {"SET_FILENAME_FAILED", ERR_LIB_DSO, DSO_R_SET_FILENAME_FAILED}, | |
| #else | |
| {"SET_FILENAME_FAILED", 37, 112}, | |
| #endif | |
| #ifdef DSO_R_STACK_ERROR | |
| {"STACK_ERROR", ERR_LIB_DSO, DSO_R_STACK_ERROR}, | |
| #else | |
| {"STACK_ERROR", 37, 105}, | |
| #endif | |
| #ifdef DSO_R_SYM_FAILURE | |
| {"SYM_FAILURE", ERR_LIB_DSO, DSO_R_SYM_FAILURE}, | |
| #else | |
| {"SYM_FAILURE", 37, 106}, | |
| #endif | |
| #ifdef DSO_R_UNLOAD_FAILED | |
| {"UNLOAD_FAILED", ERR_LIB_DSO, DSO_R_UNLOAD_FAILED}, | |
| #else | |
| {"UNLOAD_FAILED", 37, 107}, | |
| #endif | |
| #ifdef DSO_R_UNSUPPORTED | |
| {"UNSUPPORTED", ERR_LIB_DSO, DSO_R_UNSUPPORTED}, | |
| #else | |
| {"UNSUPPORTED", 37, 108}, | |
| #endif | |
| #ifdef EC_R_ASN1_ERROR | |
| {"ASN1_ERROR", ERR_LIB_EC, EC_R_ASN1_ERROR}, | |
| #else | |
| {"ASN1_ERROR", 16, 115}, | |
| #endif | |
| #ifdef EC_R_BAD_SIGNATURE | |
| {"BAD_SIGNATURE", ERR_LIB_EC, EC_R_BAD_SIGNATURE}, | |
| #else | |
| {"BAD_SIGNATURE", 16, 156}, | |
| #endif | |
| #ifdef EC_R_BIGNUM_OUT_OF_RANGE | |
| {"BIGNUM_OUT_OF_RANGE", ERR_LIB_EC, EC_R_BIGNUM_OUT_OF_RANGE}, | |
| #else | |
| {"BIGNUM_OUT_OF_RANGE", 16, 144}, | |
| #endif | |
| #ifdef EC_R_BUFFER_TOO_SMALL | |
| {"BUFFER_TOO_SMALL", ERR_LIB_EC, EC_R_BUFFER_TOO_SMALL}, | |
| #else | |
| {"BUFFER_TOO_SMALL", 16, 100}, | |
| #endif | |
| #ifdef EC_R_CANNOT_INVERT | |
| {"CANNOT_INVERT", ERR_LIB_EC, EC_R_CANNOT_INVERT}, | |
| #else | |
| {"CANNOT_INVERT", 16, 165}, | |
| #endif | |
| #ifdef EC_R_COORDINATES_OUT_OF_RANGE | |
| {"COORDINATES_OUT_OF_RANGE", ERR_LIB_EC, EC_R_COORDINATES_OUT_OF_RANGE}, | |
| #else | |
| {"COORDINATES_OUT_OF_RANGE", 16, 146}, | |
| #endif | |
| #ifdef EC_R_CURVE_DOES_NOT_SUPPORT_ECDH | |
| {"CURVE_DOES_NOT_SUPPORT_ECDH", ERR_LIB_EC, EC_R_CURVE_DOES_NOT_SUPPORT_ECDH}, | |
| #else | |
| {"CURVE_DOES_NOT_SUPPORT_ECDH", 16, 160}, | |
| #endif | |
| #ifdef EC_R_CURVE_DOES_NOT_SUPPORT_ECDSA | |
| {"CURVE_DOES_NOT_SUPPORT_ECDSA", ERR_LIB_EC, EC_R_CURVE_DOES_NOT_SUPPORT_ECDSA}, | |
| #else | |
| {"CURVE_DOES_NOT_SUPPORT_ECDSA", 16, 170}, | |
| #endif | |
| #ifdef EC_R_CURVE_DOES_NOT_SUPPORT_SIGNING | |
| {"CURVE_DOES_NOT_SUPPORT_SIGNING", ERR_LIB_EC, EC_R_CURVE_DOES_NOT_SUPPORT_SIGNING}, | |
| #else | |
| {"CURVE_DOES_NOT_SUPPORT_SIGNING", 16, 159}, | |
| #endif | |
| #ifdef EC_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_EC, EC_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 16, 142}, | |
| #endif | |
| #ifdef EC_R_DISCRIMINANT_IS_ZERO | |
| {"DISCRIMINANT_IS_ZERO", ERR_LIB_EC, EC_R_DISCRIMINANT_IS_ZERO}, | |
| #else | |
| {"DISCRIMINANT_IS_ZERO", 16, 118}, | |
| #endif | |
| #ifdef EC_R_EC_GROUP_NEW_BY_NAME_FAILURE | |
| {"EC_GROUP_NEW_BY_NAME_FAILURE", ERR_LIB_EC, EC_R_EC_GROUP_NEW_BY_NAME_FAILURE}, | |
| #else | |
| {"EC_GROUP_NEW_BY_NAME_FAILURE", 16, 119}, | |
| #endif | |
| #ifdef EC_R_EXPLICIT_PARAMS_NOT_SUPPORTED | |
| {"EXPLICIT_PARAMS_NOT_SUPPORTED", ERR_LIB_EC, EC_R_EXPLICIT_PARAMS_NOT_SUPPORTED}, | |
| #else | |
| {"EXPLICIT_PARAMS_NOT_SUPPORTED", 16, 127}, | |
| #endif | |
| #ifdef EC_R_FAILED_MAKING_PUBLIC_KEY | |
| {"FAILED_MAKING_PUBLIC_KEY", ERR_LIB_EC, EC_R_FAILED_MAKING_PUBLIC_KEY}, | |
| #else | |
| {"FAILED_MAKING_PUBLIC_KEY", 16, 166}, | |
| #endif | |
| #ifdef EC_R_FIELD_TOO_LARGE | |
| {"FIELD_TOO_LARGE", ERR_LIB_EC, EC_R_FIELD_TOO_LARGE}, | |
| #else | |
| {"FIELD_TOO_LARGE", 16, 143}, | |
| #endif | |
| #ifdef EC_R_GF2M_NOT_SUPPORTED | |
| {"GF2M_NOT_SUPPORTED", ERR_LIB_EC, EC_R_GF2M_NOT_SUPPORTED}, | |
| #else | |
| {"GF2M_NOT_SUPPORTED", 16, 147}, | |
| #endif | |
| #ifdef EC_R_GROUP2PKPARAMETERS_FAILURE | |
| {"GROUP2PKPARAMETERS_FAILURE", ERR_LIB_EC, EC_R_GROUP2PKPARAMETERS_FAILURE}, | |
| #else | |
| {"GROUP2PKPARAMETERS_FAILURE", 16, 120}, | |
| #endif | |
| #ifdef EC_R_I2D_ECPKPARAMETERS_FAILURE | |
| {"I2D_ECPKPARAMETERS_FAILURE", ERR_LIB_EC, EC_R_I2D_ECPKPARAMETERS_FAILURE}, | |
| #else | |
| {"I2D_ECPKPARAMETERS_FAILURE", 16, 121}, | |
| #endif | |
| #ifdef EC_R_INCOMPATIBLE_OBJECTS | |
| {"INCOMPATIBLE_OBJECTS", ERR_LIB_EC, EC_R_INCOMPATIBLE_OBJECTS}, | |
| #else | |
| {"INCOMPATIBLE_OBJECTS", 16, 101}, | |
| #endif | |
| #ifdef EC_R_INVALID_A | |
| {"INVALID_A", ERR_LIB_EC, EC_R_INVALID_A}, | |
| #else | |
| {"INVALID_A", 16, 168}, | |
| #endif | |
| #ifdef EC_R_INVALID_ARGUMENT | |
| {"INVALID_ARGUMENT", ERR_LIB_EC, EC_R_INVALID_ARGUMENT}, | |
| #else | |
| {"INVALID_ARGUMENT", 16, 112}, | |
| #endif | |
| #ifdef EC_R_INVALID_B | |
| {"INVALID_B", ERR_LIB_EC, EC_R_INVALID_B}, | |
| #else | |
| {"INVALID_B", 16, 169}, | |
| #endif | |
| #ifdef EC_R_INVALID_COFACTOR | |
| {"INVALID_COFACTOR", ERR_LIB_EC, EC_R_INVALID_COFACTOR}, | |
| #else | |
| {"INVALID_COFACTOR", 16, 171}, | |
| #endif | |
| #ifdef EC_R_INVALID_COMPRESSED_POINT | |
| {"INVALID_COMPRESSED_POINT", ERR_LIB_EC, EC_R_INVALID_COMPRESSED_POINT}, | |
| #else | |
| {"INVALID_COMPRESSED_POINT", 16, 110}, | |
| #endif | |
| #ifdef EC_R_INVALID_COMPRESSION_BIT | |
| {"INVALID_COMPRESSION_BIT", ERR_LIB_EC, EC_R_INVALID_COMPRESSION_BIT}, | |
| #else | |
| {"INVALID_COMPRESSION_BIT", 16, 109}, | |
| #endif | |
| #ifdef EC_R_INVALID_CURVE | |
| {"INVALID_CURVE", ERR_LIB_EC, EC_R_INVALID_CURVE}, | |
| #else | |
| {"INVALID_CURVE", 16, 141}, | |
| #endif | |
| #ifdef EC_R_INVALID_DIGEST | |
| {"INVALID_DIGEST", ERR_LIB_EC, EC_R_INVALID_DIGEST}, | |
| #else | |
| {"INVALID_DIGEST", 16, 151}, | |
| #endif | |
| #ifdef EC_R_INVALID_DIGEST_TYPE | |
| {"INVALID_DIGEST_TYPE", ERR_LIB_EC, EC_R_INVALID_DIGEST_TYPE}, | |
| #else | |
| {"INVALID_DIGEST_TYPE", 16, 138}, | |
| #endif | |
| #ifdef EC_R_INVALID_ENCODING | |
| {"INVALID_ENCODING", ERR_LIB_EC, EC_R_INVALID_ENCODING}, | |
| #else | |
| {"INVALID_ENCODING", 16, 102}, | |
| #endif | |
| #ifdef EC_R_INVALID_FIELD | |
| {"INVALID_FIELD", ERR_LIB_EC, EC_R_INVALID_FIELD}, | |
| #else | |
| {"INVALID_FIELD", 16, 103}, | |
| #endif | |
| #ifdef EC_R_INVALID_FORM | |
| {"INVALID_FORM", ERR_LIB_EC, EC_R_INVALID_FORM}, | |
| #else | |
| {"INVALID_FORM", 16, 104}, | |
| #endif | |
| #ifdef EC_R_INVALID_GENERATOR | |
| {"INVALID_GENERATOR", ERR_LIB_EC, EC_R_INVALID_GENERATOR}, | |
| #else | |
| {"INVALID_GENERATOR", 16, 173}, | |
| #endif | |
| #ifdef EC_R_INVALID_GROUP_ORDER | |
| {"INVALID_GROUP_ORDER", ERR_LIB_EC, EC_R_INVALID_GROUP_ORDER}, | |
| #else | |
| {"INVALID_GROUP_ORDER", 16, 122}, | |
| #endif | |
| #ifdef EC_R_INVALID_KEY | |
| {"INVALID_KEY", ERR_LIB_EC, EC_R_INVALID_KEY}, | |
| #else | |
| {"INVALID_KEY", 16, 116}, | |
| #endif | |
| #ifdef EC_R_INVALID_LENGTH | |
| {"INVALID_LENGTH", ERR_LIB_EC, EC_R_INVALID_LENGTH}, | |
| #else | |
| {"INVALID_LENGTH", 16, 117}, | |
| #endif | |
| #ifdef EC_R_INVALID_NAMED_GROUP_CONVERSION | |
| {"INVALID_NAMED_GROUP_CONVERSION", ERR_LIB_EC, EC_R_INVALID_NAMED_GROUP_CONVERSION}, | |
| #else | |
| {"INVALID_NAMED_GROUP_CONVERSION", 16, 174}, | |
| #endif | |
| #ifdef EC_R_INVALID_OUTPUT_LENGTH | |
| {"INVALID_OUTPUT_LENGTH", ERR_LIB_EC, EC_R_INVALID_OUTPUT_LENGTH}, | |
| #else | |
| {"INVALID_OUTPUT_LENGTH", 16, 161}, | |
| #endif | |
| #ifdef EC_R_INVALID_P | |
| {"INVALID_P", ERR_LIB_EC, EC_R_INVALID_P}, | |
| #else | |
| {"INVALID_P", 16, 172}, | |
| #endif | |
| #ifdef EC_R_INVALID_PEER_KEY | |
| {"INVALID_PEER_KEY", ERR_LIB_EC, EC_R_INVALID_PEER_KEY}, | |
| #else | |
| {"INVALID_PEER_KEY", 16, 133}, | |
| #endif | |
| #ifdef EC_R_INVALID_PENTANOMIAL_BASIS | |
| {"INVALID_PENTANOMIAL_BASIS", ERR_LIB_EC, EC_R_INVALID_PENTANOMIAL_BASIS}, | |
| #else | |
| {"INVALID_PENTANOMIAL_BASIS", 16, 132}, | |
| #endif | |
| #ifdef EC_R_INVALID_PRIVATE_KEY | |
| {"INVALID_PRIVATE_KEY", ERR_LIB_EC, EC_R_INVALID_PRIVATE_KEY}, | |
| #else | |
| {"INVALID_PRIVATE_KEY", 16, 123}, | |
| #endif | |
| #ifdef EC_R_INVALID_SEED | |
| {"INVALID_SEED", ERR_LIB_EC, EC_R_INVALID_SEED}, | |
| #else | |
| {"INVALID_SEED", 16, 175}, | |
| #endif | |
| #ifdef EC_R_INVALID_TRINOMIAL_BASIS | |
| {"INVALID_TRINOMIAL_BASIS", ERR_LIB_EC, EC_R_INVALID_TRINOMIAL_BASIS}, | |
| #else | |
| {"INVALID_TRINOMIAL_BASIS", 16, 137}, | |
| #endif | |
| #ifdef EC_R_KDF_PARAMETER_ERROR | |
| {"KDF_PARAMETER_ERROR", ERR_LIB_EC, EC_R_KDF_PARAMETER_ERROR}, | |
| #else | |
| {"KDF_PARAMETER_ERROR", 16, 148}, | |
| #endif | |
| #ifdef EC_R_KEYS_NOT_SET | |
| {"KEYS_NOT_SET", ERR_LIB_EC, EC_R_KEYS_NOT_SET}, | |
| #else | |
| {"KEYS_NOT_SET", 16, 140}, | |
| #endif | |
| #ifdef EC_R_LADDER_POST_FAILURE | |
| {"LADDER_POST_FAILURE", ERR_LIB_EC, EC_R_LADDER_POST_FAILURE}, | |
| #else | |
| {"LADDER_POST_FAILURE", 16, 136}, | |
| #endif | |
| #ifdef EC_R_LADDER_PRE_FAILURE | |
| {"LADDER_PRE_FAILURE", ERR_LIB_EC, EC_R_LADDER_PRE_FAILURE}, | |
| #else | |
| {"LADDER_PRE_FAILURE", 16, 153}, | |
| #endif | |
| #ifdef EC_R_LADDER_STEP_FAILURE | |
| {"LADDER_STEP_FAILURE", ERR_LIB_EC, EC_R_LADDER_STEP_FAILURE}, | |
| #else | |
| {"LADDER_STEP_FAILURE", 16, 162}, | |
| #endif | |
| #ifdef EC_R_MISSING_OID | |
| {"MISSING_OID", ERR_LIB_EC, EC_R_MISSING_OID}, | |
| #else | |
| {"MISSING_OID", 16, 167}, | |
| #endif | |
| #ifdef EC_R_MISSING_PARAMETERS | |
| {"MISSING_PARAMETERS", ERR_LIB_EC, EC_R_MISSING_PARAMETERS}, | |
| #else | |
| {"MISSING_PARAMETERS", 16, 124}, | |
| #endif | |
| #ifdef EC_R_MISSING_PRIVATE_KEY | |
| {"MISSING_PRIVATE_KEY", ERR_LIB_EC, EC_R_MISSING_PRIVATE_KEY}, | |
| #else | |
| {"MISSING_PRIVATE_KEY", 16, 125}, | |
| #endif | |
| #ifdef EC_R_NEED_NEW_SETUP_VALUES | |
| {"NEED_NEW_SETUP_VALUES", ERR_LIB_EC, EC_R_NEED_NEW_SETUP_VALUES}, | |
| #else | |
| {"NEED_NEW_SETUP_VALUES", 16, 157}, | |
| #endif | |
| #ifdef EC_R_NOT_A_NIST_PRIME | |
| {"NOT_A_NIST_PRIME", ERR_LIB_EC, EC_R_NOT_A_NIST_PRIME}, | |
| #else | |
| {"NOT_A_NIST_PRIME", 16, 135}, | |
| #endif | |
| #ifdef EC_R_NOT_IMPLEMENTED | |
| {"NOT_IMPLEMENTED", ERR_LIB_EC, EC_R_NOT_IMPLEMENTED}, | |
| #else | |
| {"NOT_IMPLEMENTED", 16, 126}, | |
| #endif | |
| #ifdef EC_R_NOT_INITIALIZED | |
| {"NOT_INITIALIZED", ERR_LIB_EC, EC_R_NOT_INITIALIZED}, | |
| #else | |
| {"NOT_INITIALIZED", 16, 111}, | |
| #endif | |
| #ifdef EC_R_NO_PARAMETERS_SET | |
| {"NO_PARAMETERS_SET", ERR_LIB_EC, EC_R_NO_PARAMETERS_SET}, | |
| #else | |
| {"NO_PARAMETERS_SET", 16, 139}, | |
| #endif | |
| #ifdef EC_R_NO_PRIVATE_VALUE | |
| {"NO_PRIVATE_VALUE", ERR_LIB_EC, EC_R_NO_PRIVATE_VALUE}, | |
| #else | |
| {"NO_PRIVATE_VALUE", 16, 154}, | |
| #endif | |
| #ifdef EC_R_OPERATION_NOT_SUPPORTED | |
| {"OPERATION_NOT_SUPPORTED", ERR_LIB_EC, EC_R_OPERATION_NOT_SUPPORTED}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED", 16, 152}, | |
| #endif | |
| #ifdef EC_R_PASSED_NULL_PARAMETER | |
| {"PASSED_NULL_PARAMETER", ERR_LIB_EC, EC_R_PASSED_NULL_PARAMETER}, | |
| #else | |
| {"PASSED_NULL_PARAMETER", 16, 134}, | |
| #endif | |
| #ifdef EC_R_PEER_KEY_ERROR | |
| {"PEER_KEY_ERROR", ERR_LIB_EC, EC_R_PEER_KEY_ERROR}, | |
| #else | |
| {"PEER_KEY_ERROR", 16, 149}, | |
| #endif | |
| #ifdef EC_R_POINT_ARITHMETIC_FAILURE | |
| {"POINT_ARITHMETIC_FAILURE", ERR_LIB_EC, EC_R_POINT_ARITHMETIC_FAILURE}, | |
| #else | |
| {"POINT_ARITHMETIC_FAILURE", 16, 155}, | |
| #endif | |
| #ifdef EC_R_POINT_AT_INFINITY | |
| {"POINT_AT_INFINITY", ERR_LIB_EC, EC_R_POINT_AT_INFINITY}, | |
| #else | |
| {"POINT_AT_INFINITY", 16, 106}, | |
| #endif | |
| #ifdef EC_R_POINT_COORDINATES_BLIND_FAILURE | |
| {"POINT_COORDINATES_BLIND_FAILURE", ERR_LIB_EC, EC_R_POINT_COORDINATES_BLIND_FAILURE}, | |
| #else | |
| {"POINT_COORDINATES_BLIND_FAILURE", 16, 163}, | |
| #endif | |
| #ifdef EC_R_POINT_IS_NOT_ON_CURVE | |
| {"POINT_IS_NOT_ON_CURVE", ERR_LIB_EC, EC_R_POINT_IS_NOT_ON_CURVE}, | |
| #else | |
| {"POINT_IS_NOT_ON_CURVE", 16, 107}, | |
| #endif | |
| #ifdef EC_R_RANDOM_NUMBER_GENERATION_FAILED | |
| {"RANDOM_NUMBER_GENERATION_FAILED", ERR_LIB_EC, EC_R_RANDOM_NUMBER_GENERATION_FAILED}, | |
| #else | |
| {"RANDOM_NUMBER_GENERATION_FAILED", 16, 158}, | |
| #endif | |
| #ifdef EC_R_SHARED_INFO_ERROR | |
| {"SHARED_INFO_ERROR", ERR_LIB_EC, EC_R_SHARED_INFO_ERROR}, | |
| #else | |
| {"SHARED_INFO_ERROR", 16, 150}, | |
| #endif | |
| #ifdef EC_R_SLOT_FULL | |
| {"SLOT_FULL", ERR_LIB_EC, EC_R_SLOT_FULL}, | |
| #else | |
| {"SLOT_FULL", 16, 108}, | |
| #endif | |
| #ifdef EC_R_TOO_MANY_RETRIES | |
| {"TOO_MANY_RETRIES", ERR_LIB_EC, EC_R_TOO_MANY_RETRIES}, | |
| #else | |
| {"TOO_MANY_RETRIES", 16, 176}, | |
| #endif | |
| #ifdef EC_R_UNDEFINED_GENERATOR | |
| {"UNDEFINED_GENERATOR", ERR_LIB_EC, EC_R_UNDEFINED_GENERATOR}, | |
| #else | |
| {"UNDEFINED_GENERATOR", 16, 113}, | |
| #endif | |
| #ifdef EC_R_UNDEFINED_ORDER | |
| {"UNDEFINED_ORDER", ERR_LIB_EC, EC_R_UNDEFINED_ORDER}, | |
| #else | |
| {"UNDEFINED_ORDER", 16, 128}, | |
| #endif | |
| #ifdef EC_R_UNKNOWN_COFACTOR | |
| {"UNKNOWN_COFACTOR", ERR_LIB_EC, EC_R_UNKNOWN_COFACTOR}, | |
| #else | |
| {"UNKNOWN_COFACTOR", 16, 164}, | |
| #endif | |
| #ifdef EC_R_UNKNOWN_GROUP | |
| {"UNKNOWN_GROUP", ERR_LIB_EC, EC_R_UNKNOWN_GROUP}, | |
| #else | |
| {"UNKNOWN_GROUP", 16, 129}, | |
| #endif | |
| #ifdef EC_R_UNKNOWN_ORDER | |
| {"UNKNOWN_ORDER", ERR_LIB_EC, EC_R_UNKNOWN_ORDER}, | |
| #else | |
| {"UNKNOWN_ORDER", 16, 114}, | |
| #endif | |
| #ifdef EC_R_UNSUPPORTED_FIELD | |
| {"UNSUPPORTED_FIELD", ERR_LIB_EC, EC_R_UNSUPPORTED_FIELD}, | |
| #else | |
| {"UNSUPPORTED_FIELD", 16, 131}, | |
| #endif | |
| #ifdef EC_R_WRONG_CURVE_PARAMETERS | |
| {"WRONG_CURVE_PARAMETERS", ERR_LIB_EC, EC_R_WRONG_CURVE_PARAMETERS}, | |
| #else | |
| {"WRONG_CURVE_PARAMETERS", 16, 145}, | |
| #endif | |
| #ifdef EC_R_WRONG_ORDER | |
| {"WRONG_ORDER", ERR_LIB_EC, EC_R_WRONG_ORDER}, | |
| #else | |
| {"WRONG_ORDER", 16, 130}, | |
| #endif | |
| #ifdef ENGINE_R_ALREADY_LOADED | |
| {"ALREADY_LOADED", ERR_LIB_ENGINE, ENGINE_R_ALREADY_LOADED}, | |
| #else | |
| {"ALREADY_LOADED", 38, 100}, | |
| #endif | |
| #ifdef ENGINE_R_ARGUMENT_IS_NOT_A_NUMBER | |
| {"ARGUMENT_IS_NOT_A_NUMBER", ERR_LIB_ENGINE, ENGINE_R_ARGUMENT_IS_NOT_A_NUMBER}, | |
| #else | |
| {"ARGUMENT_IS_NOT_A_NUMBER", 38, 133}, | |
| #endif | |
| #ifdef ENGINE_R_CMD_NOT_EXECUTABLE | |
| {"CMD_NOT_EXECUTABLE", ERR_LIB_ENGINE, ENGINE_R_CMD_NOT_EXECUTABLE}, | |
| #else | |
| {"CMD_NOT_EXECUTABLE", 38, 134}, | |
| #endif | |
| #ifdef ENGINE_R_COMMAND_TAKES_INPUT | |
| {"COMMAND_TAKES_INPUT", ERR_LIB_ENGINE, ENGINE_R_COMMAND_TAKES_INPUT}, | |
| #else | |
| {"COMMAND_TAKES_INPUT", 38, 135}, | |
| #endif | |
| #ifdef ENGINE_R_COMMAND_TAKES_NO_INPUT | |
| {"COMMAND_TAKES_NO_INPUT", ERR_LIB_ENGINE, ENGINE_R_COMMAND_TAKES_NO_INPUT}, | |
| #else | |
| {"COMMAND_TAKES_NO_INPUT", 38, 136}, | |
| #endif | |
| #ifdef ENGINE_R_CONFLICTING_ENGINE_ID | |
| {"CONFLICTING_ENGINE_ID", ERR_LIB_ENGINE, ENGINE_R_CONFLICTING_ENGINE_ID}, | |
| #else | |
| {"CONFLICTING_ENGINE_ID", 38, 103}, | |
| #endif | |
| #ifdef ENGINE_R_CTRL_COMMAND_NOT_IMPLEMENTED | |
| {"CTRL_COMMAND_NOT_IMPLEMENTED", ERR_LIB_ENGINE, ENGINE_R_CTRL_COMMAND_NOT_IMPLEMENTED}, | |
| #else | |
| {"CTRL_COMMAND_NOT_IMPLEMENTED", 38, 119}, | |
| #endif | |
| #ifdef ENGINE_R_DSO_FAILURE | |
| {"DSO_FAILURE", ERR_LIB_ENGINE, ENGINE_R_DSO_FAILURE}, | |
| #else | |
| {"DSO_FAILURE", 38, 104}, | |
| #endif | |
| #ifdef ENGINE_R_DSO_NOT_FOUND | |
| {"DSO_NOT_FOUND", ERR_LIB_ENGINE, ENGINE_R_DSO_NOT_FOUND}, | |
| #else | |
| {"DSO_NOT_FOUND", 38, 132}, | |
| #endif | |
| #ifdef ENGINE_R_ENGINES_SECTION_ERROR | |
| {"ENGINES_SECTION_ERROR", ERR_LIB_ENGINE, ENGINE_R_ENGINES_SECTION_ERROR}, | |
| #else | |
| {"ENGINES_SECTION_ERROR", 38, 148}, | |
| #endif | |
| #ifdef ENGINE_R_ENGINE_CONFIGURATION_ERROR | |
| {"ENGINE_CONFIGURATION_ERROR", ERR_LIB_ENGINE, ENGINE_R_ENGINE_CONFIGURATION_ERROR}, | |
| #else | |
| {"ENGINE_CONFIGURATION_ERROR", 38, 102}, | |
| #endif | |
| #ifdef ENGINE_R_ENGINE_IS_NOT_IN_LIST | |
| {"ENGINE_IS_NOT_IN_LIST", ERR_LIB_ENGINE, ENGINE_R_ENGINE_IS_NOT_IN_LIST}, | |
| #else | |
| {"ENGINE_IS_NOT_IN_LIST", 38, 105}, | |
| #endif | |
| #ifdef ENGINE_R_ENGINE_SECTION_ERROR | |
| {"ENGINE_SECTION_ERROR", ERR_LIB_ENGINE, ENGINE_R_ENGINE_SECTION_ERROR}, | |
| #else | |
| {"ENGINE_SECTION_ERROR", 38, 149}, | |
| #endif | |
| #ifdef ENGINE_R_FAILED_LOADING_PRIVATE_KEY | |
| {"FAILED_LOADING_PRIVATE_KEY", ERR_LIB_ENGINE, ENGINE_R_FAILED_LOADING_PRIVATE_KEY}, | |
| #else | |
| {"FAILED_LOADING_PRIVATE_KEY", 38, 128}, | |
| #endif | |
| #ifdef ENGINE_R_FAILED_LOADING_PUBLIC_KEY | |
| {"FAILED_LOADING_PUBLIC_KEY", ERR_LIB_ENGINE, ENGINE_R_FAILED_LOADING_PUBLIC_KEY}, | |
| #else | |
| {"FAILED_LOADING_PUBLIC_KEY", 38, 129}, | |
| #endif | |
| #ifdef ENGINE_R_FINISH_FAILED | |
| {"FINISH_FAILED", ERR_LIB_ENGINE, ENGINE_R_FINISH_FAILED}, | |
| #else | |
| {"FINISH_FAILED", 38, 106}, | |
| #endif | |
| #ifdef ENGINE_R_ID_OR_NAME_MISSING | |
| {"ID_OR_NAME_MISSING", ERR_LIB_ENGINE, ENGINE_R_ID_OR_NAME_MISSING}, | |
| #else | |
| {"ID_OR_NAME_MISSING", 38, 108}, | |
| #endif | |
| #ifdef ENGINE_R_INIT_FAILED | |
| {"INIT_FAILED", ERR_LIB_ENGINE, ENGINE_R_INIT_FAILED}, | |
| #else | |
| {"INIT_FAILED", 38, 109}, | |
| #endif | |
| #ifdef ENGINE_R_INTERNAL_LIST_ERROR | |
| {"INTERNAL_LIST_ERROR", ERR_LIB_ENGINE, ENGINE_R_INTERNAL_LIST_ERROR}, | |
| #else | |
| {"INTERNAL_LIST_ERROR", 38, 110}, | |
| #endif | |
| #ifdef ENGINE_R_INVALID_ARGUMENT | |
| {"INVALID_ARGUMENT", ERR_LIB_ENGINE, ENGINE_R_INVALID_ARGUMENT}, | |
| #else | |
| {"INVALID_ARGUMENT", 38, 143}, | |
| #endif | |
| #ifdef ENGINE_R_INVALID_CMD_NAME | |
| {"INVALID_CMD_NAME", ERR_LIB_ENGINE, ENGINE_R_INVALID_CMD_NAME}, | |
| #else | |
| {"INVALID_CMD_NAME", 38, 137}, | |
| #endif | |
| #ifdef ENGINE_R_INVALID_CMD_NUMBER | |
| {"INVALID_CMD_NUMBER", ERR_LIB_ENGINE, ENGINE_R_INVALID_CMD_NUMBER}, | |
| #else | |
| {"INVALID_CMD_NUMBER", 38, 138}, | |
| #endif | |
| #ifdef ENGINE_R_INVALID_INIT_VALUE | |
| {"INVALID_INIT_VALUE", ERR_LIB_ENGINE, ENGINE_R_INVALID_INIT_VALUE}, | |
| #else | |
| {"INVALID_INIT_VALUE", 38, 151}, | |
| #endif | |
| #ifdef ENGINE_R_INVALID_STRING | |
| {"INVALID_STRING", ERR_LIB_ENGINE, ENGINE_R_INVALID_STRING}, | |
| #else | |
| {"INVALID_STRING", 38, 150}, | |
| #endif | |
| #ifdef ENGINE_R_NOT_INITIALISED | |
| {"NOT_INITIALISED", ERR_LIB_ENGINE, ENGINE_R_NOT_INITIALISED}, | |
| #else | |
| {"NOT_INITIALISED", 38, 117}, | |
| #endif | |
| #ifdef ENGINE_R_NOT_LOADED | |
| {"NOT_LOADED", ERR_LIB_ENGINE, ENGINE_R_NOT_LOADED}, | |
| #else | |
| {"NOT_LOADED", 38, 112}, | |
| #endif | |
| #ifdef ENGINE_R_NO_CONTROL_FUNCTION | |
| {"NO_CONTROL_FUNCTION", ERR_LIB_ENGINE, ENGINE_R_NO_CONTROL_FUNCTION}, | |
| #else | |
| {"NO_CONTROL_FUNCTION", 38, 120}, | |
| #endif | |
| #ifdef ENGINE_R_NO_INDEX | |
| {"NO_INDEX", ERR_LIB_ENGINE, ENGINE_R_NO_INDEX}, | |
| #else | |
| {"NO_INDEX", 38, 144}, | |
| #endif | |
| #ifdef ENGINE_R_NO_LOAD_FUNCTION | |
| {"NO_LOAD_FUNCTION", ERR_LIB_ENGINE, ENGINE_R_NO_LOAD_FUNCTION}, | |
| #else | |
| {"NO_LOAD_FUNCTION", 38, 125}, | |
| #endif | |
| #ifdef ENGINE_R_NO_REFERENCE | |
| {"NO_REFERENCE", ERR_LIB_ENGINE, ENGINE_R_NO_REFERENCE}, | |
| #else | |
| {"NO_REFERENCE", 38, 130}, | |
| #endif | |
| #ifdef ENGINE_R_NO_SUCH_ENGINE | |
| {"NO_SUCH_ENGINE", ERR_LIB_ENGINE, ENGINE_R_NO_SUCH_ENGINE}, | |
| #else | |
| {"NO_SUCH_ENGINE", 38, 116}, | |
| #endif | |
| #ifdef ENGINE_R_UNIMPLEMENTED_CIPHER | |
| {"UNIMPLEMENTED_CIPHER", ERR_LIB_ENGINE, ENGINE_R_UNIMPLEMENTED_CIPHER}, | |
| #else | |
| {"UNIMPLEMENTED_CIPHER", 38, 146}, | |
| #endif | |
| #ifdef ENGINE_R_UNIMPLEMENTED_DIGEST | |
| {"UNIMPLEMENTED_DIGEST", ERR_LIB_ENGINE, ENGINE_R_UNIMPLEMENTED_DIGEST}, | |
| #else | |
| {"UNIMPLEMENTED_DIGEST", 38, 147}, | |
| #endif | |
| #ifdef ENGINE_R_UNIMPLEMENTED_PUBLIC_KEY_METHOD | |
| {"UNIMPLEMENTED_PUBLIC_KEY_METHOD", ERR_LIB_ENGINE, ENGINE_R_UNIMPLEMENTED_PUBLIC_KEY_METHOD}, | |
| #else | |
| {"UNIMPLEMENTED_PUBLIC_KEY_METHOD", 38, 101}, | |
| #endif | |
| #ifdef ENGINE_R_VERSION_INCOMPATIBILITY | |
| {"VERSION_INCOMPATIBILITY", ERR_LIB_ENGINE, ENGINE_R_VERSION_INCOMPATIBILITY}, | |
| #else | |
| {"VERSION_INCOMPATIBILITY", 38, 145}, | |
| #endif | |
| #ifdef ESS_R_EMPTY_ESS_CERT_ID_LIST | |
| {"EMPTY_ESS_CERT_ID_LIST", ERR_LIB_ESS, ESS_R_EMPTY_ESS_CERT_ID_LIST}, | |
| #else | |
| {"EMPTY_ESS_CERT_ID_LIST", 54, 107}, | |
| #endif | |
| #ifdef ESS_R_ESS_CERT_DIGEST_ERROR | |
| {"ESS_CERT_DIGEST_ERROR", ERR_LIB_ESS, ESS_R_ESS_CERT_DIGEST_ERROR}, | |
| #else | |
| {"ESS_CERT_DIGEST_ERROR", 54, 103}, | |
| #endif | |
| #ifdef ESS_R_ESS_CERT_ID_NOT_FOUND | |
| {"ESS_CERT_ID_NOT_FOUND", ERR_LIB_ESS, ESS_R_ESS_CERT_ID_NOT_FOUND}, | |
| #else | |
| {"ESS_CERT_ID_NOT_FOUND", 54, 104}, | |
| #endif | |
| #ifdef ESS_R_ESS_CERT_ID_WRONG_ORDER | |
| {"ESS_CERT_ID_WRONG_ORDER", ERR_LIB_ESS, ESS_R_ESS_CERT_ID_WRONG_ORDER}, | |
| #else | |
| {"ESS_CERT_ID_WRONG_ORDER", 54, 105}, | |
| #endif | |
| #ifdef ESS_R_ESS_DIGEST_ALG_UNKNOWN | |
| {"ESS_DIGEST_ALG_UNKNOWN", ERR_LIB_ESS, ESS_R_ESS_DIGEST_ALG_UNKNOWN}, | |
| #else | |
| {"ESS_DIGEST_ALG_UNKNOWN", 54, 106}, | |
| #endif | |
| #ifdef ESS_R_ESS_SIGNING_CERTIFICATE_ERROR | |
| {"ESS_SIGNING_CERTIFICATE_ERROR", ERR_LIB_ESS, ESS_R_ESS_SIGNING_CERTIFICATE_ERROR}, | |
| #else | |
| {"ESS_SIGNING_CERTIFICATE_ERROR", 54, 102}, | |
| #endif | |
| #ifdef ESS_R_ESS_SIGNING_CERT_ADD_ERROR | |
| {"ESS_SIGNING_CERT_ADD_ERROR", ERR_LIB_ESS, ESS_R_ESS_SIGNING_CERT_ADD_ERROR}, | |
| #else | |
| {"ESS_SIGNING_CERT_ADD_ERROR", 54, 100}, | |
| #endif | |
| #ifdef ESS_R_ESS_SIGNING_CERT_V2_ADD_ERROR | |
| {"ESS_SIGNING_CERT_V2_ADD_ERROR", ERR_LIB_ESS, ESS_R_ESS_SIGNING_CERT_V2_ADD_ERROR}, | |
| #else | |
| {"ESS_SIGNING_CERT_V2_ADD_ERROR", 54, 101}, | |
| #endif | |
| #ifdef ESS_R_MISSING_SIGNING_CERTIFICATE_ATTRIBUTE | |
| {"MISSING_SIGNING_CERTIFICATE_ATTRIBUTE", ERR_LIB_ESS, ESS_R_MISSING_SIGNING_CERTIFICATE_ATTRIBUTE}, | |
| #else | |
| {"MISSING_SIGNING_CERTIFICATE_ATTRIBUTE", 54, 108}, | |
| #endif | |
| #ifdef EVP_R_AES_KEY_SETUP_FAILED | |
| {"AES_KEY_SETUP_FAILED", ERR_LIB_EVP, EVP_R_AES_KEY_SETUP_FAILED}, | |
| #else | |
| {"AES_KEY_SETUP_FAILED", 6, 143}, | |
| #endif | |
| #ifdef EVP_R_ARIA_KEY_SETUP_FAILED | |
| {"ARIA_KEY_SETUP_FAILED", ERR_LIB_EVP, EVP_R_ARIA_KEY_SETUP_FAILED}, | |
| #else | |
| {"ARIA_KEY_SETUP_FAILED", 6, 176}, | |
| #endif | |
| #ifdef EVP_R_BAD_ALGORITHM_NAME | |
| {"BAD_ALGORITHM_NAME", ERR_LIB_EVP, EVP_R_BAD_ALGORITHM_NAME}, | |
| #else | |
| {"BAD_ALGORITHM_NAME", 6, 200}, | |
| #endif | |
| #ifdef EVP_R_BAD_DECRYPT | |
| {"BAD_DECRYPT", ERR_LIB_EVP, EVP_R_BAD_DECRYPT}, | |
| #else | |
| {"BAD_DECRYPT", 6, 100}, | |
| #endif | |
| #ifdef EVP_R_BAD_KEY_LENGTH | |
| {"BAD_KEY_LENGTH", ERR_LIB_EVP, EVP_R_BAD_KEY_LENGTH}, | |
| #else | |
| {"BAD_KEY_LENGTH", 6, 195}, | |
| #endif | |
| #ifdef EVP_R_BUFFER_TOO_SMALL | |
| {"BUFFER_TOO_SMALL", ERR_LIB_EVP, EVP_R_BUFFER_TOO_SMALL}, | |
| #else | |
| {"BUFFER_TOO_SMALL", 6, 155}, | |
| #endif | |
| #ifdef EVP_R_CACHE_CONSTANTS_FAILED | |
| {"CACHE_CONSTANTS_FAILED", ERR_LIB_EVP, EVP_R_CACHE_CONSTANTS_FAILED}, | |
| #else | |
| {"CACHE_CONSTANTS_FAILED", 6, 225}, | |
| #endif | |
| #ifdef EVP_R_CAMELLIA_KEY_SETUP_FAILED | |
| {"CAMELLIA_KEY_SETUP_FAILED", ERR_LIB_EVP, EVP_R_CAMELLIA_KEY_SETUP_FAILED}, | |
| #else | |
| {"CAMELLIA_KEY_SETUP_FAILED", 6, 157}, | |
| #endif | |
| #ifdef EVP_R_CANNOT_GET_PARAMETERS | |
| {"CANNOT_GET_PARAMETERS", ERR_LIB_EVP, EVP_R_CANNOT_GET_PARAMETERS}, | |
| #else | |
| {"CANNOT_GET_PARAMETERS", 6, 197}, | |
| #endif | |
| #ifdef EVP_R_CANNOT_SET_PARAMETERS | |
| {"CANNOT_SET_PARAMETERS", ERR_LIB_EVP, EVP_R_CANNOT_SET_PARAMETERS}, | |
| #else | |
| {"CANNOT_SET_PARAMETERS", 6, 198}, | |
| #endif | |
| #ifdef EVP_R_CIPHER_NOT_GCM_MODE | |
| {"CIPHER_NOT_GCM_MODE", ERR_LIB_EVP, EVP_R_CIPHER_NOT_GCM_MODE}, | |
| #else | |
| {"CIPHER_NOT_GCM_MODE", 6, 184}, | |
| #endif | |
| #ifdef EVP_R_CIPHER_PARAMETER_ERROR | |
| {"CIPHER_PARAMETER_ERROR", ERR_LIB_EVP, EVP_R_CIPHER_PARAMETER_ERROR}, | |
| #else | |
| {"CIPHER_PARAMETER_ERROR", 6, 122}, | |
| #endif | |
| #ifdef EVP_R_COMMAND_NOT_SUPPORTED | |
| {"COMMAND_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_COMMAND_NOT_SUPPORTED}, | |
| #else | |
| {"COMMAND_NOT_SUPPORTED", 6, 147}, | |
| #endif | |
| #ifdef EVP_R_CONFLICTING_ALGORITHM_NAME | |
| {"CONFLICTING_ALGORITHM_NAME", ERR_LIB_EVP, EVP_R_CONFLICTING_ALGORITHM_NAME}, | |
| #else | |
| {"CONFLICTING_ALGORITHM_NAME", 6, 201}, | |
| #endif | |
| #ifdef EVP_R_COPY_ERROR | |
| {"COPY_ERROR", ERR_LIB_EVP, EVP_R_COPY_ERROR}, | |
| #else | |
| {"COPY_ERROR", 6, 173}, | |
| #endif | |
| #ifdef EVP_R_CTRL_NOT_IMPLEMENTED | |
| {"CTRL_NOT_IMPLEMENTED", ERR_LIB_EVP, EVP_R_CTRL_NOT_IMPLEMENTED}, | |
| #else | |
| {"CTRL_NOT_IMPLEMENTED", 6, 132}, | |
| #endif | |
| #ifdef EVP_R_CTRL_OPERATION_NOT_IMPLEMENTED | |
| {"CTRL_OPERATION_NOT_IMPLEMENTED", ERR_LIB_EVP, EVP_R_CTRL_OPERATION_NOT_IMPLEMENTED}, | |
| #else | |
| {"CTRL_OPERATION_NOT_IMPLEMENTED", 6, 133}, | |
| #endif | |
| #ifdef EVP_R_DATA_NOT_MULTIPLE_OF_BLOCK_LENGTH | |
| {"DATA_NOT_MULTIPLE_OF_BLOCK_LENGTH", ERR_LIB_EVP, EVP_R_DATA_NOT_MULTIPLE_OF_BLOCK_LENGTH}, | |
| #else | |
| {"DATA_NOT_MULTIPLE_OF_BLOCK_LENGTH", 6, 138}, | |
| #endif | |
| #ifdef EVP_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_EVP, EVP_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 6, 114}, | |
| #endif | |
| #ifdef EVP_R_DEFAULT_QUERY_PARSE_ERROR | |
| {"DEFAULT_QUERY_PARSE_ERROR", ERR_LIB_EVP, EVP_R_DEFAULT_QUERY_PARSE_ERROR}, | |
| #else | |
| {"DEFAULT_QUERY_PARSE_ERROR", 6, 210}, | |
| #endif | |
| #ifdef EVP_R_DIFFERENT_KEY_TYPES | |
| {"DIFFERENT_KEY_TYPES", ERR_LIB_EVP, EVP_R_DIFFERENT_KEY_TYPES}, | |
| #else | |
| {"DIFFERENT_KEY_TYPES", 6, 101}, | |
| #endif | |
| #ifdef EVP_R_DIFFERENT_PARAMETERS | |
| {"DIFFERENT_PARAMETERS", ERR_LIB_EVP, EVP_R_DIFFERENT_PARAMETERS}, | |
| #else | |
| {"DIFFERENT_PARAMETERS", 6, 153}, | |
| #endif | |
| #ifdef EVP_R_ERROR_LOADING_SECTION | |
| {"ERROR_LOADING_SECTION", ERR_LIB_EVP, EVP_R_ERROR_LOADING_SECTION}, | |
| #else | |
| {"ERROR_LOADING_SECTION", 6, 165}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_AN_HMAC_KEY | |
| {"EXPECTING_AN_HMAC_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_AN_HMAC_KEY}, | |
| #else | |
| {"EXPECTING_AN_HMAC_KEY", 6, 174}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_AN_RSA_KEY | |
| {"EXPECTING_AN_RSA_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_AN_RSA_KEY}, | |
| #else | |
| {"EXPECTING_AN_RSA_KEY", 6, 127}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_DH_KEY | |
| {"EXPECTING_A_DH_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_DH_KEY}, | |
| #else | |
| {"EXPECTING_A_DH_KEY", 6, 128}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_DSA_KEY | |
| {"EXPECTING_A_DSA_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_DSA_KEY}, | |
| #else | |
| {"EXPECTING_A_DSA_KEY", 6, 129}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_ECX_KEY | |
| {"EXPECTING_A_ECX_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_ECX_KEY}, | |
| #else | |
| {"EXPECTING_A_ECX_KEY", 6, 219}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_EC_KEY | |
| {"EXPECTING_A_EC_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_EC_KEY}, | |
| #else | |
| {"EXPECTING_A_EC_KEY", 6, 142}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_POLY1305_KEY | |
| {"EXPECTING_A_POLY1305_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_POLY1305_KEY}, | |
| #else | |
| {"EXPECTING_A_POLY1305_KEY", 6, 164}, | |
| #endif | |
| #ifdef EVP_R_EXPECTING_A_SIPHASH_KEY | |
| {"EXPECTING_A_SIPHASH_KEY", ERR_LIB_EVP, EVP_R_EXPECTING_A_SIPHASH_KEY}, | |
| #else | |
| {"EXPECTING_A_SIPHASH_KEY", 6, 175}, | |
| #endif | |
| #ifdef EVP_R_FINAL_ERROR | |
| {"FINAL_ERROR", ERR_LIB_EVP, EVP_R_FINAL_ERROR}, | |
| #else | |
| {"FINAL_ERROR", 6, 188}, | |
| #endif | |
| #ifdef EVP_R_GENERATE_ERROR | |
| {"GENERATE_ERROR", ERR_LIB_EVP, EVP_R_GENERATE_ERROR}, | |
| #else | |
| {"GENERATE_ERROR", 6, 214}, | |
| #endif | |
| #ifdef EVP_R_GETTING_ALGORITHMIDENTIFIER_NOT_SUPPORTED | |
| {"GETTING_ALGORITHMIDENTIFIER_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_GETTING_ALGORITHMIDENTIFIER_NOT_SUPPORTED}, | |
| #else | |
| {"GETTING_ALGORITHMIDENTIFIER_NOT_SUPPORTED", 6, 229}, | |
| #endif | |
| #ifdef EVP_R_GET_RAW_KEY_FAILED | |
| {"GET_RAW_KEY_FAILED", ERR_LIB_EVP, EVP_R_GET_RAW_KEY_FAILED}, | |
| #else | |
| {"GET_RAW_KEY_FAILED", 6, 182}, | |
| #endif | |
| #ifdef EVP_R_ILLEGAL_SCRYPT_PARAMETERS | |
| {"ILLEGAL_SCRYPT_PARAMETERS", ERR_LIB_EVP, EVP_R_ILLEGAL_SCRYPT_PARAMETERS}, | |
| #else | |
| {"ILLEGAL_SCRYPT_PARAMETERS", 6, 171}, | |
| #endif | |
| #ifdef EVP_R_INACCESSIBLE_DOMAIN_PARAMETERS | |
| {"INACCESSIBLE_DOMAIN_PARAMETERS", ERR_LIB_EVP, EVP_R_INACCESSIBLE_DOMAIN_PARAMETERS}, | |
| #else | |
| {"INACCESSIBLE_DOMAIN_PARAMETERS", 6, 204}, | |
| #endif | |
| #ifdef EVP_R_INACCESSIBLE_KEY | |
| {"INACCESSIBLE_KEY", ERR_LIB_EVP, EVP_R_INACCESSIBLE_KEY}, | |
| #else | |
| {"INACCESSIBLE_KEY", 6, 203}, | |
| #endif | |
| #ifdef EVP_R_INITIALIZATION_ERROR | |
| {"INITIALIZATION_ERROR", ERR_LIB_EVP, EVP_R_INITIALIZATION_ERROR}, | |
| #else | |
| {"INITIALIZATION_ERROR", 6, 134}, | |
| #endif | |
| #ifdef EVP_R_INPUT_NOT_INITIALIZED | |
| {"INPUT_NOT_INITIALIZED", ERR_LIB_EVP, EVP_R_INPUT_NOT_INITIALIZED}, | |
| #else | |
| {"INPUT_NOT_INITIALIZED", 6, 111}, | |
| #endif | |
| #ifdef EVP_R_INVALID_CUSTOM_LENGTH | |
| {"INVALID_CUSTOM_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_CUSTOM_LENGTH}, | |
| #else | |
| {"INVALID_CUSTOM_LENGTH", 6, 185}, | |
| #endif | |
| #ifdef EVP_R_INVALID_DIGEST | |
| {"INVALID_DIGEST", ERR_LIB_EVP, EVP_R_INVALID_DIGEST}, | |
| #else | |
| {"INVALID_DIGEST", 6, 152}, | |
| #endif | |
| #ifdef EVP_R_INVALID_IV_LENGTH | |
| {"INVALID_IV_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_IV_LENGTH}, | |
| #else | |
| {"INVALID_IV_LENGTH", 6, 194}, | |
| #endif | |
| #ifdef EVP_R_INVALID_KEY | |
| {"INVALID_KEY", ERR_LIB_EVP, EVP_R_INVALID_KEY}, | |
| #else | |
| {"INVALID_KEY", 6, 163}, | |
| #endif | |
| #ifdef EVP_R_INVALID_KEY_LENGTH | |
| {"INVALID_KEY_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_KEY_LENGTH}, | |
| #else | |
| {"INVALID_KEY_LENGTH", 6, 130}, | |
| #endif | |
| #ifdef EVP_R_INVALID_LENGTH | |
| {"INVALID_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_LENGTH}, | |
| #else | |
| {"INVALID_LENGTH", 6, 221}, | |
| #endif | |
| #ifdef EVP_R_INVALID_NULL_ALGORITHM | |
| {"INVALID_NULL_ALGORITHM", ERR_LIB_EVP, EVP_R_INVALID_NULL_ALGORITHM}, | |
| #else | |
| {"INVALID_NULL_ALGORITHM", 6, 218}, | |
| #endif | |
| #ifdef EVP_R_INVALID_OPERATION | |
| {"INVALID_OPERATION", ERR_LIB_EVP, EVP_R_INVALID_OPERATION}, | |
| #else | |
| {"INVALID_OPERATION", 6, 148}, | |
| #endif | |
| #ifdef EVP_R_INVALID_PROVIDER_FUNCTIONS | |
| {"INVALID_PROVIDER_FUNCTIONS", ERR_LIB_EVP, EVP_R_INVALID_PROVIDER_FUNCTIONS}, | |
| #else | |
| {"INVALID_PROVIDER_FUNCTIONS", 6, 193}, | |
| #endif | |
| #ifdef EVP_R_INVALID_SALT_LENGTH | |
| {"INVALID_SALT_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_SALT_LENGTH}, | |
| #else | |
| {"INVALID_SALT_LENGTH", 6, 186}, | |
| #endif | |
| #ifdef EVP_R_INVALID_SECRET_LENGTH | |
| {"INVALID_SECRET_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_SECRET_LENGTH}, | |
| #else | |
| {"INVALID_SECRET_LENGTH", 6, 223}, | |
| #endif | |
| #ifdef EVP_R_INVALID_SEED_LENGTH | |
| {"INVALID_SEED_LENGTH", ERR_LIB_EVP, EVP_R_INVALID_SEED_LENGTH}, | |
| #else | |
| {"INVALID_SEED_LENGTH", 6, 220}, | |
| #endif | |
| #ifdef EVP_R_INVALID_VALUE | |
| {"INVALID_VALUE", ERR_LIB_EVP, EVP_R_INVALID_VALUE}, | |
| #else | |
| {"INVALID_VALUE", 6, 222}, | |
| #endif | |
| #ifdef EVP_R_KEYMGMT_EXPORT_FAILURE | |
| {"KEYMGMT_EXPORT_FAILURE", ERR_LIB_EVP, EVP_R_KEYMGMT_EXPORT_FAILURE}, | |
| #else | |
| {"KEYMGMT_EXPORT_FAILURE", 6, 205}, | |
| #endif | |
| #ifdef EVP_R_KEY_SETUP_FAILED | |
| {"KEY_SETUP_FAILED", ERR_LIB_EVP, EVP_R_KEY_SETUP_FAILED}, | |
| #else | |
| {"KEY_SETUP_FAILED", 6, 180}, | |
| #endif | |
| #ifdef EVP_R_LOCKING_NOT_SUPPORTED | |
| {"LOCKING_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_LOCKING_NOT_SUPPORTED}, | |
| #else | |
| {"LOCKING_NOT_SUPPORTED", 6, 213}, | |
| #endif | |
| #ifdef EVP_R_MEMORY_LIMIT_EXCEEDED | |
| {"MEMORY_LIMIT_EXCEEDED", ERR_LIB_EVP, EVP_R_MEMORY_LIMIT_EXCEEDED}, | |
| #else | |
| {"MEMORY_LIMIT_EXCEEDED", 6, 172}, | |
| #endif | |
| #ifdef EVP_R_MESSAGE_DIGEST_IS_NULL | |
| {"MESSAGE_DIGEST_IS_NULL", ERR_LIB_EVP, EVP_R_MESSAGE_DIGEST_IS_NULL}, | |
| #else | |
| {"MESSAGE_DIGEST_IS_NULL", 6, 159}, | |
| #endif | |
| #ifdef EVP_R_METHOD_NOT_SUPPORTED | |
| {"METHOD_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_METHOD_NOT_SUPPORTED}, | |
| #else | |
| {"METHOD_NOT_SUPPORTED", 6, 144}, | |
| #endif | |
| #ifdef EVP_R_MISSING_PARAMETERS | |
| {"MISSING_PARAMETERS", ERR_LIB_EVP, EVP_R_MISSING_PARAMETERS}, | |
| #else | |
| {"MISSING_PARAMETERS", 6, 103}, | |
| #endif | |
| #ifdef EVP_R_NOT_ABLE_TO_COPY_CTX | |
| {"NOT_ABLE_TO_COPY_CTX", ERR_LIB_EVP, EVP_R_NOT_ABLE_TO_COPY_CTX}, | |
| #else | |
| {"NOT_ABLE_TO_COPY_CTX", 6, 190}, | |
| #endif | |
| #ifdef EVP_R_NOT_XOF_OR_INVALID_LENGTH | |
| {"NOT_XOF_OR_INVALID_LENGTH", ERR_LIB_EVP, EVP_R_NOT_XOF_OR_INVALID_LENGTH}, | |
| #else | |
| {"NOT_XOF_OR_INVALID_LENGTH", 6, 178}, | |
| #endif | |
| #ifdef EVP_R_NO_CIPHER_SET | |
| {"NO_CIPHER_SET", ERR_LIB_EVP, EVP_R_NO_CIPHER_SET}, | |
| #else | |
| {"NO_CIPHER_SET", 6, 131}, | |
| #endif | |
| #ifdef EVP_R_NO_DEFAULT_DIGEST | |
| {"NO_DEFAULT_DIGEST", ERR_LIB_EVP, EVP_R_NO_DEFAULT_DIGEST}, | |
| #else | |
| {"NO_DEFAULT_DIGEST", 6, 158}, | |
| #endif | |
| #ifdef EVP_R_NO_DIGEST_SET | |
| {"NO_DIGEST_SET", ERR_LIB_EVP, EVP_R_NO_DIGEST_SET}, | |
| #else | |
| {"NO_DIGEST_SET", 6, 139}, | |
| #endif | |
| #ifdef EVP_R_NO_IMPORT_FUNCTION | |
| {"NO_IMPORT_FUNCTION", ERR_LIB_EVP, EVP_R_NO_IMPORT_FUNCTION}, | |
| #else | |
| {"NO_IMPORT_FUNCTION", 6, 206}, | |
| #endif | |
| #ifdef EVP_R_NO_KEYMGMT_AVAILABLE | |
| {"NO_KEYMGMT_AVAILABLE", ERR_LIB_EVP, EVP_R_NO_KEYMGMT_AVAILABLE}, | |
| #else | |
| {"NO_KEYMGMT_AVAILABLE", 6, 199}, | |
| #endif | |
| #ifdef EVP_R_NO_KEYMGMT_PRESENT | |
| {"NO_KEYMGMT_PRESENT", ERR_LIB_EVP, EVP_R_NO_KEYMGMT_PRESENT}, | |
| #else | |
| {"NO_KEYMGMT_PRESENT", 6, 196}, | |
| #endif | |
| #ifdef EVP_R_NO_KEY_SET | |
| {"NO_KEY_SET", ERR_LIB_EVP, EVP_R_NO_KEY_SET}, | |
| #else | |
| {"NO_KEY_SET", 6, 154}, | |
| #endif | |
| #ifdef EVP_R_NO_OPERATION_SET | |
| {"NO_OPERATION_SET", ERR_LIB_EVP, EVP_R_NO_OPERATION_SET}, | |
| #else | |
| {"NO_OPERATION_SET", 6, 149}, | |
| #endif | |
| #ifdef EVP_R_NULL_MAC_PKEY_CTX | |
| {"NULL_MAC_PKEY_CTX", ERR_LIB_EVP, EVP_R_NULL_MAC_PKEY_CTX}, | |
| #else | |
| {"NULL_MAC_PKEY_CTX", 6, 208}, | |
| #endif | |
| #ifdef EVP_R_ONLY_ONESHOT_SUPPORTED | |
| {"ONLY_ONESHOT_SUPPORTED", ERR_LIB_EVP, EVP_R_ONLY_ONESHOT_SUPPORTED}, | |
| #else | |
| {"ONLY_ONESHOT_SUPPORTED", 6, 177}, | |
| #endif | |
| #ifdef EVP_R_OPERATION_NOT_INITIALIZED | |
| {"OPERATION_NOT_INITIALIZED", ERR_LIB_EVP, EVP_R_OPERATION_NOT_INITIALIZED}, | |
| #else | |
| {"OPERATION_NOT_INITIALIZED", 6, 151}, | |
| #endif | |
| #ifdef EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", ERR_LIB_EVP, EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", 6, 150}, | |
| #endif | |
| #ifdef EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_SIGNATURE_TYPE | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_SIGNATURE_TYPE", ERR_LIB_EVP, EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_SIGNATURE_TYPE}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_SIGNATURE_TYPE", 6, 226}, | |
| #endif | |
| #ifdef EVP_R_OUTPUT_WOULD_OVERFLOW | |
| {"OUTPUT_WOULD_OVERFLOW", ERR_LIB_EVP, EVP_R_OUTPUT_WOULD_OVERFLOW}, | |
| #else | |
| {"OUTPUT_WOULD_OVERFLOW", 6, 202}, | |
| #endif | |
| #ifdef EVP_R_PARAMETER_TOO_LARGE | |
| {"PARAMETER_TOO_LARGE", ERR_LIB_EVP, EVP_R_PARAMETER_TOO_LARGE}, | |
| #else | |
| {"PARAMETER_TOO_LARGE", 6, 187}, | |
| #endif | |
| #ifdef EVP_R_PARTIALLY_OVERLAPPING | |
| {"PARTIALLY_OVERLAPPING", ERR_LIB_EVP, EVP_R_PARTIALLY_OVERLAPPING}, | |
| #else | |
| {"PARTIALLY_OVERLAPPING", 6, 162}, | |
| #endif | |
| #ifdef EVP_R_PBKDF2_ERROR | |
| {"PBKDF2_ERROR", ERR_LIB_EVP, EVP_R_PBKDF2_ERROR}, | |
| #else | |
| {"PBKDF2_ERROR", 6, 181}, | |
| #endif | |
| #ifdef EVP_R_PIPELINE_NOT_SUPPORTED | |
| {"PIPELINE_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_PIPELINE_NOT_SUPPORTED}, | |
| #else | |
| {"PIPELINE_NOT_SUPPORTED", 6, 230}, | |
| #endif | |
| #ifdef EVP_R_PKEY_APPLICATION_ASN1_METHOD_ALREADY_REGISTERED | |
| {"PKEY_APPLICATION_ASN1_METHOD_ALREADY_REGISTERED", ERR_LIB_EVP, EVP_R_PKEY_APPLICATION_ASN1_METHOD_ALREADY_REGISTERED}, | |
| #else | |
| {"PKEY_APPLICATION_ASN1_METHOD_ALREADY_REGISTERED", 6, 179}, | |
| #endif | |
| #ifdef EVP_R_PRIVATE_KEY_DECODE_ERROR | |
| {"PRIVATE_KEY_DECODE_ERROR", ERR_LIB_EVP, EVP_R_PRIVATE_KEY_DECODE_ERROR}, | |
| #else | |
| {"PRIVATE_KEY_DECODE_ERROR", 6, 145}, | |
| #endif | |
| #ifdef EVP_R_PRIVATE_KEY_ENCODE_ERROR | |
| {"PRIVATE_KEY_ENCODE_ERROR", ERR_LIB_EVP, EVP_R_PRIVATE_KEY_ENCODE_ERROR}, | |
| #else | |
| {"PRIVATE_KEY_ENCODE_ERROR", 6, 146}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_ASYM_CIPHER_FAILURE | |
| {"PROVIDER_ASYM_CIPHER_FAILURE", ERR_LIB_EVP, EVP_R_PROVIDER_ASYM_CIPHER_FAILURE}, | |
| #else | |
| {"PROVIDER_ASYM_CIPHER_FAILURE", 6, 232}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_ASYM_CIPHER_NOT_SUPPORTED | |
| {"PROVIDER_ASYM_CIPHER_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_PROVIDER_ASYM_CIPHER_NOT_SUPPORTED}, | |
| #else | |
| {"PROVIDER_ASYM_CIPHER_NOT_SUPPORTED", 6, 235}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_KEYMGMT_FAILURE | |
| {"PROVIDER_KEYMGMT_FAILURE", ERR_LIB_EVP, EVP_R_PROVIDER_KEYMGMT_FAILURE}, | |
| #else | |
| {"PROVIDER_KEYMGMT_FAILURE", 6, 233}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_KEYMGMT_NOT_SUPPORTED | |
| {"PROVIDER_KEYMGMT_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_PROVIDER_KEYMGMT_NOT_SUPPORTED}, | |
| #else | |
| {"PROVIDER_KEYMGMT_NOT_SUPPORTED", 6, 236}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_SIGNATURE_FAILURE | |
| {"PROVIDER_SIGNATURE_FAILURE", ERR_LIB_EVP, EVP_R_PROVIDER_SIGNATURE_FAILURE}, | |
| #else | |
| {"PROVIDER_SIGNATURE_FAILURE", 6, 234}, | |
| #endif | |
| #ifdef EVP_R_PROVIDER_SIGNATURE_NOT_SUPPORTED | |
| {"PROVIDER_SIGNATURE_NOT_SUPPORTED", ERR_LIB_EVP, EVP_R_PROVIDER_SIGNATURE_NOT_SUPPORTED}, | |
| #else | |
| {"PROVIDER_SIGNATURE_NOT_SUPPORTED", 6, 237}, | |
| #endif | |
| #ifdef EVP_R_PUBLIC_KEY_NOT_RSA | |
| {"PUBLIC_KEY_NOT_RSA", ERR_LIB_EVP, EVP_R_PUBLIC_KEY_NOT_RSA}, | |
| #else | |
| {"PUBLIC_KEY_NOT_RSA", 6, 106}, | |
| #endif | |
| #ifdef EVP_R_SETTING_XOF_FAILED | |
| {"SETTING_XOF_FAILED", ERR_LIB_EVP, EVP_R_SETTING_XOF_FAILED}, | |
| #else | |
| {"SETTING_XOF_FAILED", 6, 227}, | |
| #endif | |
| #ifdef EVP_R_SET_DEFAULT_PROPERTY_FAILURE | |
| {"SET_DEFAULT_PROPERTY_FAILURE", ERR_LIB_EVP, EVP_R_SET_DEFAULT_PROPERTY_FAILURE}, | |
| #else | |
| {"SET_DEFAULT_PROPERTY_FAILURE", 6, 209}, | |
| #endif | |
| #ifdef EVP_R_SIGNATURE_TYPE_AND_KEY_TYPE_INCOMPATIBLE | |
| {"SIGNATURE_TYPE_AND_KEY_TYPE_INCOMPATIBLE", ERR_LIB_EVP, EVP_R_SIGNATURE_TYPE_AND_KEY_TYPE_INCOMPATIBLE}, | |
| #else | |
| {"SIGNATURE_TYPE_AND_KEY_TYPE_INCOMPATIBLE", 6, 228}, | |
| #endif | |
| #ifdef EVP_R_TOO_MANY_PIPES | |
| {"TOO_MANY_PIPES", ERR_LIB_EVP, EVP_R_TOO_MANY_PIPES}, | |
| #else | |
| {"TOO_MANY_PIPES", 6, 231}, | |
| #endif | |
| #ifdef EVP_R_TOO_MANY_RECORDS | |
| {"TOO_MANY_RECORDS", ERR_LIB_EVP, EVP_R_TOO_MANY_RECORDS}, | |
| #else | |
| {"TOO_MANY_RECORDS", 6, 183}, | |
| #endif | |
| #ifdef EVP_R_UNABLE_TO_ENABLE_LOCKING | |
| {"UNABLE_TO_ENABLE_LOCKING", ERR_LIB_EVP, EVP_R_UNABLE_TO_ENABLE_LOCKING}, | |
| #else | |
| {"UNABLE_TO_ENABLE_LOCKING", 6, 212}, | |
| #endif | |
| #ifdef EVP_R_UNABLE_TO_GET_MAXIMUM_REQUEST_SIZE | |
| {"UNABLE_TO_GET_MAXIMUM_REQUEST_SIZE", ERR_LIB_EVP, EVP_R_UNABLE_TO_GET_MAXIMUM_REQUEST_SIZE}, | |
| #else | |
| {"UNABLE_TO_GET_MAXIMUM_REQUEST_SIZE", 6, 215}, | |
| #endif | |
| #ifdef EVP_R_UNABLE_TO_GET_RANDOM_STRENGTH | |
| {"UNABLE_TO_GET_RANDOM_STRENGTH", ERR_LIB_EVP, EVP_R_UNABLE_TO_GET_RANDOM_STRENGTH}, | |
| #else | |
| {"UNABLE_TO_GET_RANDOM_STRENGTH", 6, 216}, | |
| #endif | |
| #ifdef EVP_R_UNABLE_TO_LOCK_CONTEXT | |
| {"UNABLE_TO_LOCK_CONTEXT", ERR_LIB_EVP, EVP_R_UNABLE_TO_LOCK_CONTEXT}, | |
| #else | |
| {"UNABLE_TO_LOCK_CONTEXT", 6, 211}, | |
| #endif | |
| #ifdef EVP_R_UNABLE_TO_SET_CALLBACKS | |
| {"UNABLE_TO_SET_CALLBACKS", ERR_LIB_EVP, EVP_R_UNABLE_TO_SET_CALLBACKS}, | |
| #else | |
| {"UNABLE_TO_SET_CALLBACKS", 6, 217}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_BITS | |
| {"UNKNOWN_BITS", ERR_LIB_EVP, EVP_R_UNKNOWN_BITS}, | |
| #else | |
| {"UNKNOWN_BITS", 6, 166}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_CIPHER | |
| {"UNKNOWN_CIPHER", ERR_LIB_EVP, EVP_R_UNKNOWN_CIPHER}, | |
| #else | |
| {"UNKNOWN_CIPHER", 6, 160}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_DIGEST | |
| {"UNKNOWN_DIGEST", ERR_LIB_EVP, EVP_R_UNKNOWN_DIGEST}, | |
| #else | |
| {"UNKNOWN_DIGEST", 6, 161}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_KEY_TYPE | |
| {"UNKNOWN_KEY_TYPE", ERR_LIB_EVP, EVP_R_UNKNOWN_KEY_TYPE}, | |
| #else | |
| {"UNKNOWN_KEY_TYPE", 6, 207}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_MAX_SIZE | |
| {"UNKNOWN_MAX_SIZE", ERR_LIB_EVP, EVP_R_UNKNOWN_MAX_SIZE}, | |
| #else | |
| {"UNKNOWN_MAX_SIZE", 6, 167}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_OPTION | |
| {"UNKNOWN_OPTION", ERR_LIB_EVP, EVP_R_UNKNOWN_OPTION}, | |
| #else | |
| {"UNKNOWN_OPTION", 6, 169}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_PBE_ALGORITHM | |
| {"UNKNOWN_PBE_ALGORITHM", ERR_LIB_EVP, EVP_R_UNKNOWN_PBE_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_PBE_ALGORITHM", 6, 121}, | |
| #endif | |
| #ifdef EVP_R_UNKNOWN_SECURITY_BITS | |
| {"UNKNOWN_SECURITY_BITS", ERR_LIB_EVP, EVP_R_UNKNOWN_SECURITY_BITS}, | |
| #else | |
| {"UNKNOWN_SECURITY_BITS", 6, 168}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_ALGORITHM | |
| {"UNSUPPORTED_ALGORITHM", ERR_LIB_EVP, EVP_R_UNSUPPORTED_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_ALGORITHM", 6, 156}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_CIPHER | |
| {"UNSUPPORTED_CIPHER", ERR_LIB_EVP, EVP_R_UNSUPPORTED_CIPHER}, | |
| #else | |
| {"UNSUPPORTED_CIPHER", 6, 107}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_KEYLENGTH | |
| {"UNSUPPORTED_KEYLENGTH", ERR_LIB_EVP, EVP_R_UNSUPPORTED_KEYLENGTH}, | |
| #else | |
| {"UNSUPPORTED_KEYLENGTH", 6, 123}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_KEY_DERIVATION_FUNCTION | |
| {"UNSUPPORTED_KEY_DERIVATION_FUNCTION", ERR_LIB_EVP, EVP_R_UNSUPPORTED_KEY_DERIVATION_FUNCTION}, | |
| #else | |
| {"UNSUPPORTED_KEY_DERIVATION_FUNCTION", 6, 124}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_KEY_SIZE | |
| {"UNSUPPORTED_KEY_SIZE", ERR_LIB_EVP, EVP_R_UNSUPPORTED_KEY_SIZE}, | |
| #else | |
| {"UNSUPPORTED_KEY_SIZE", 6, 108}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_KEY_TYPE | |
| {"UNSUPPORTED_KEY_TYPE", ERR_LIB_EVP, EVP_R_UNSUPPORTED_KEY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_KEY_TYPE", 6, 224}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_NUMBER_OF_ROUNDS | |
| {"UNSUPPORTED_NUMBER_OF_ROUNDS", ERR_LIB_EVP, EVP_R_UNSUPPORTED_NUMBER_OF_ROUNDS}, | |
| #else | |
| {"UNSUPPORTED_NUMBER_OF_ROUNDS", 6, 135}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_PRF | |
| {"UNSUPPORTED_PRF", ERR_LIB_EVP, EVP_R_UNSUPPORTED_PRF}, | |
| #else | |
| {"UNSUPPORTED_PRF", 6, 125}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_PRIVATE_KEY_ALGORITHM | |
| {"UNSUPPORTED_PRIVATE_KEY_ALGORITHM", ERR_LIB_EVP, EVP_R_UNSUPPORTED_PRIVATE_KEY_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_PRIVATE_KEY_ALGORITHM", 6, 118}, | |
| #endif | |
| #ifdef EVP_R_UNSUPPORTED_SALT_TYPE | |
| {"UNSUPPORTED_SALT_TYPE", ERR_LIB_EVP, EVP_R_UNSUPPORTED_SALT_TYPE}, | |
| #else | |
| {"UNSUPPORTED_SALT_TYPE", 6, 126}, | |
| #endif | |
| #ifdef EVP_R_UPDATE_ERROR | |
| {"UPDATE_ERROR", ERR_LIB_EVP, EVP_R_UPDATE_ERROR}, | |
| #else | |
| {"UPDATE_ERROR", 6, 189}, | |
| #endif | |
| #ifdef EVP_R_WRAP_MODE_NOT_ALLOWED | |
| {"WRAP_MODE_NOT_ALLOWED", ERR_LIB_EVP, EVP_R_WRAP_MODE_NOT_ALLOWED}, | |
| #else | |
| {"WRAP_MODE_NOT_ALLOWED", 6, 170}, | |
| #endif | |
| #ifdef EVP_R_WRONG_FINAL_BLOCK_LENGTH | |
| {"WRONG_FINAL_BLOCK_LENGTH", ERR_LIB_EVP, EVP_R_WRONG_FINAL_BLOCK_LENGTH}, | |
| #else | |
| {"WRONG_FINAL_BLOCK_LENGTH", 6, 109}, | |
| #endif | |
| #ifdef EVP_R_XTS_DATA_UNIT_IS_TOO_LARGE | |
| {"XTS_DATA_UNIT_IS_TOO_LARGE", ERR_LIB_EVP, EVP_R_XTS_DATA_UNIT_IS_TOO_LARGE}, | |
| #else | |
| {"XTS_DATA_UNIT_IS_TOO_LARGE", 6, 191}, | |
| #endif | |
| #ifdef EVP_R_XTS_DUPLICATED_KEYS | |
| {"XTS_DUPLICATED_KEYS", ERR_LIB_EVP, EVP_R_XTS_DUPLICATED_KEYS}, | |
| #else | |
| {"XTS_DUPLICATED_KEYS", 6, 192}, | |
| #endif | |
| #ifdef HTTP_R_ASN1_LEN_EXCEEDS_MAX_RESP_LEN | |
| {"ASN1_LEN_EXCEEDS_MAX_RESP_LEN", ERR_LIB_HTTP, HTTP_R_ASN1_LEN_EXCEEDS_MAX_RESP_LEN}, | |
| #else | |
| {"ASN1_LEN_EXCEEDS_MAX_RESP_LEN", 61, 108}, | |
| #endif | |
| #ifdef HTTP_R_CONNECT_FAILURE | |
| {"CONNECT_FAILURE", ERR_LIB_HTTP, HTTP_R_CONNECT_FAILURE}, | |
| #else | |
| {"CONNECT_FAILURE", 61, 100}, | |
| #endif | |
| #ifdef HTTP_R_ERROR_PARSING_ASN1_LENGTH | |
| {"ERROR_PARSING_ASN1_LENGTH", ERR_LIB_HTTP, HTTP_R_ERROR_PARSING_ASN1_LENGTH}, | |
| #else | |
| {"ERROR_PARSING_ASN1_LENGTH", 61, 109}, | |
| #endif | |
| #ifdef HTTP_R_ERROR_PARSING_CONTENT_LENGTH | |
| {"ERROR_PARSING_CONTENT_LENGTH", ERR_LIB_HTTP, HTTP_R_ERROR_PARSING_CONTENT_LENGTH}, | |
| #else | |
| {"ERROR_PARSING_CONTENT_LENGTH", 61, 119}, | |
| #endif | |
| #ifdef HTTP_R_ERROR_PARSING_URL | |
| {"ERROR_PARSING_URL", ERR_LIB_HTTP, HTTP_R_ERROR_PARSING_URL}, | |
| #else | |
| {"ERROR_PARSING_URL", 61, 101}, | |
| #endif | |
| #ifdef HTTP_R_ERROR_RECEIVING | |
| {"ERROR_RECEIVING", ERR_LIB_HTTP, HTTP_R_ERROR_RECEIVING}, | |
| #else | |
| {"ERROR_RECEIVING", 61, 103}, | |
| #endif | |
| #ifdef HTTP_R_ERROR_SENDING | |
| {"ERROR_SENDING", ERR_LIB_HTTP, HTTP_R_ERROR_SENDING}, | |
| #else | |
| {"ERROR_SENDING", 61, 102}, | |
| #endif | |
| #ifdef HTTP_R_FAILED_READING_DATA | |
| {"FAILED_READING_DATA", ERR_LIB_HTTP, HTTP_R_FAILED_READING_DATA}, | |
| #else | |
| {"FAILED_READING_DATA", 61, 128}, | |
| #endif | |
| #ifdef HTTP_R_HEADER_PARSE_ERROR | |
| {"HEADER_PARSE_ERROR", ERR_LIB_HTTP, HTTP_R_HEADER_PARSE_ERROR}, | |
| #else | |
| {"HEADER_PARSE_ERROR", 61, 126}, | |
| #endif | |
| #ifdef HTTP_R_INCONSISTENT_CONTENT_LENGTH | |
| {"INCONSISTENT_CONTENT_LENGTH", ERR_LIB_HTTP, HTTP_R_INCONSISTENT_CONTENT_LENGTH}, | |
| #else | |
| {"INCONSISTENT_CONTENT_LENGTH", 61, 120}, | |
| #endif | |
| #ifdef HTTP_R_INVALID_PORT_NUMBER | |
| {"INVALID_PORT_NUMBER", ERR_LIB_HTTP, HTTP_R_INVALID_PORT_NUMBER}, | |
| #else | |
| {"INVALID_PORT_NUMBER", 61, 123}, | |
| #endif | |
| #ifdef HTTP_R_INVALID_URL_PATH | |
| {"INVALID_URL_PATH", ERR_LIB_HTTP, HTTP_R_INVALID_URL_PATH}, | |
| #else | |
| {"INVALID_URL_PATH", 61, 125}, | |
| #endif | |
| #ifdef HTTP_R_INVALID_URL_SCHEME | |
| {"INVALID_URL_SCHEME", ERR_LIB_HTTP, HTTP_R_INVALID_URL_SCHEME}, | |
| #else | |
| {"INVALID_URL_SCHEME", 61, 124}, | |
| #endif | |
| #ifdef HTTP_R_MAX_RESP_LEN_EXCEEDED | |
| {"MAX_RESP_LEN_EXCEEDED", ERR_LIB_HTTP, HTTP_R_MAX_RESP_LEN_EXCEEDED}, | |
| #else | |
| {"MAX_RESP_LEN_EXCEEDED", 61, 117}, | |
| #endif | |
| #ifdef HTTP_R_MISSING_ASN1_ENCODING | |
| {"MISSING_ASN1_ENCODING", ERR_LIB_HTTP, HTTP_R_MISSING_ASN1_ENCODING}, | |
| #else | |
| {"MISSING_ASN1_ENCODING", 61, 110}, | |
| #endif | |
| #ifdef HTTP_R_MISSING_CONTENT_TYPE | |
| {"MISSING_CONTENT_TYPE", ERR_LIB_HTTP, HTTP_R_MISSING_CONTENT_TYPE}, | |
| #else | |
| {"MISSING_CONTENT_TYPE", 61, 121}, | |
| #endif | |
| #ifdef HTTP_R_MISSING_REDIRECT_LOCATION | |
| {"MISSING_REDIRECT_LOCATION", ERR_LIB_HTTP, HTTP_R_MISSING_REDIRECT_LOCATION}, | |
| #else | |
| {"MISSING_REDIRECT_LOCATION", 61, 111}, | |
| #endif | |
| #ifdef HTTP_R_RECEIVED_ERROR | |
| {"RECEIVED_ERROR", ERR_LIB_HTTP, HTTP_R_RECEIVED_ERROR}, | |
| #else | |
| {"RECEIVED_ERROR", 61, 105}, | |
| #endif | |
| #ifdef HTTP_R_RECEIVED_WRONG_HTTP_VERSION | |
| {"RECEIVED_WRONG_HTTP_VERSION", ERR_LIB_HTTP, HTTP_R_RECEIVED_WRONG_HTTP_VERSION}, | |
| #else | |
| {"RECEIVED_WRONG_HTTP_VERSION", 61, 106}, | |
| #endif | |
| #ifdef HTTP_R_REDIRECTION_FROM_HTTPS_TO_HTTP | |
| {"REDIRECTION_FROM_HTTPS_TO_HTTP", ERR_LIB_HTTP, HTTP_R_REDIRECTION_FROM_HTTPS_TO_HTTP}, | |
| #else | |
| {"REDIRECTION_FROM_HTTPS_TO_HTTP", 61, 112}, | |
| #endif | |
| #ifdef HTTP_R_REDIRECTION_NOT_ENABLED | |
| {"REDIRECTION_NOT_ENABLED", ERR_LIB_HTTP, HTTP_R_REDIRECTION_NOT_ENABLED}, | |
| #else | |
| {"REDIRECTION_NOT_ENABLED", 61, 116}, | |
| #endif | |
| #ifdef HTTP_R_RESPONSE_LINE_TOO_LONG | |
| {"RESPONSE_LINE_TOO_LONG", ERR_LIB_HTTP, HTTP_R_RESPONSE_LINE_TOO_LONG}, | |
| #else | |
| {"RESPONSE_LINE_TOO_LONG", 61, 113}, | |
| #endif | |
| #ifdef HTTP_R_RESPONSE_PARSE_ERROR | |
| {"RESPONSE_PARSE_ERROR", ERR_LIB_HTTP, HTTP_R_RESPONSE_PARSE_ERROR}, | |
| #else | |
| {"RESPONSE_PARSE_ERROR", 61, 104}, | |
| #endif | |
| #ifdef HTTP_R_RESPONSE_TOO_MANY_HDRLINES | |
| {"RESPONSE_TOO_MANY_HDRLINES", ERR_LIB_HTTP, HTTP_R_RESPONSE_TOO_MANY_HDRLINES}, | |
| #else | |
| {"RESPONSE_TOO_MANY_HDRLINES", 61, 130}, | |
| #endif | |
| #ifdef HTTP_R_RETRY_TIMEOUT | |
| {"RETRY_TIMEOUT", ERR_LIB_HTTP, HTTP_R_RETRY_TIMEOUT}, | |
| #else | |
| {"RETRY_TIMEOUT", 61, 129}, | |
| #endif | |
| #ifdef HTTP_R_SERVER_CANCELED_CONNECTION | |
| {"SERVER_CANCELED_CONNECTION", ERR_LIB_HTTP, HTTP_R_SERVER_CANCELED_CONNECTION}, | |
| #else | |
| {"SERVER_CANCELED_CONNECTION", 61, 127}, | |
| #endif | |
| #ifdef HTTP_R_SOCK_NOT_SUPPORTED | |
| {"SOCK_NOT_SUPPORTED", ERR_LIB_HTTP, HTTP_R_SOCK_NOT_SUPPORTED}, | |
| #else | |
| {"SOCK_NOT_SUPPORTED", 61, 122}, | |
| #endif | |
| #ifdef HTTP_R_STATUS_CODE_UNSUPPORTED | |
| {"STATUS_CODE_UNSUPPORTED", ERR_LIB_HTTP, HTTP_R_STATUS_CODE_UNSUPPORTED}, | |
| #else | |
| {"STATUS_CODE_UNSUPPORTED", 61, 114}, | |
| #endif | |
| #ifdef HTTP_R_TLS_NOT_ENABLED | |
| {"TLS_NOT_ENABLED", ERR_LIB_HTTP, HTTP_R_TLS_NOT_ENABLED}, | |
| #else | |
| {"TLS_NOT_ENABLED", 61, 107}, | |
| #endif | |
| #ifdef HTTP_R_TOO_MANY_REDIRECTIONS | |
| {"TOO_MANY_REDIRECTIONS", ERR_LIB_HTTP, HTTP_R_TOO_MANY_REDIRECTIONS}, | |
| #else | |
| {"TOO_MANY_REDIRECTIONS", 61, 115}, | |
| #endif | |
| #ifdef HTTP_R_UNEXPECTED_CONTENT_TYPE | |
| {"UNEXPECTED_CONTENT_TYPE", ERR_LIB_HTTP, HTTP_R_UNEXPECTED_CONTENT_TYPE}, | |
| #else | |
| {"UNEXPECTED_CONTENT_TYPE", 61, 118}, | |
| #endif | |
| #ifdef OBJ_R_OID_EXISTS | |
| {"OID_EXISTS", ERR_LIB_OBJ, OBJ_R_OID_EXISTS}, | |
| #else | |
| {"OID_EXISTS", 8, 102}, | |
| #endif | |
| #ifdef OBJ_R_UNKNOWN_NID | |
| {"UNKNOWN_NID", ERR_LIB_OBJ, OBJ_R_UNKNOWN_NID}, | |
| #else | |
| {"UNKNOWN_NID", 8, 101}, | |
| #endif | |
| #ifdef OBJ_R_UNKNOWN_OBJECT_NAME | |
| {"UNKNOWN_OBJECT_NAME", ERR_LIB_OBJ, OBJ_R_UNKNOWN_OBJECT_NAME}, | |
| #else | |
| {"UNKNOWN_OBJECT_NAME", 8, 103}, | |
| #endif | |
| #ifdef OCSP_R_CERTIFICATE_VERIFY_ERROR | |
| {"CERTIFICATE_VERIFY_ERROR", ERR_LIB_OCSP, OCSP_R_CERTIFICATE_VERIFY_ERROR}, | |
| #else | |
| {"CERTIFICATE_VERIFY_ERROR", 39, 101}, | |
| #endif | |
| #ifdef OCSP_R_DIGEST_ERR | |
| {"DIGEST_ERR", ERR_LIB_OCSP, OCSP_R_DIGEST_ERR}, | |
| #else | |
| {"DIGEST_ERR", 39, 102}, | |
| #endif | |
| #ifdef OCSP_R_DIGEST_NAME_ERR | |
| {"DIGEST_NAME_ERR", ERR_LIB_OCSP, OCSP_R_DIGEST_NAME_ERR}, | |
| #else | |
| {"DIGEST_NAME_ERR", 39, 106}, | |
| #endif | |
| #ifdef OCSP_R_DIGEST_SIZE_ERR | |
| {"DIGEST_SIZE_ERR", ERR_LIB_OCSP, OCSP_R_DIGEST_SIZE_ERR}, | |
| #else | |
| {"DIGEST_SIZE_ERR", 39, 107}, | |
| #endif | |
| #ifdef OCSP_R_ERROR_IN_NEXTUPDATE_FIELD | |
| {"ERROR_IN_NEXTUPDATE_FIELD", ERR_LIB_OCSP, OCSP_R_ERROR_IN_NEXTUPDATE_FIELD}, | |
| #else | |
| {"ERROR_IN_NEXTUPDATE_FIELD", 39, 122}, | |
| #endif | |
| #ifdef OCSP_R_ERROR_IN_THISUPDATE_FIELD | |
| {"ERROR_IN_THISUPDATE_FIELD", ERR_LIB_OCSP, OCSP_R_ERROR_IN_THISUPDATE_FIELD}, | |
| #else | |
| {"ERROR_IN_THISUPDATE_FIELD", 39, 123}, | |
| #endif | |
| #ifdef OCSP_R_MISSING_OCSPSIGNING_USAGE | |
| {"MISSING_OCSPSIGNING_USAGE", ERR_LIB_OCSP, OCSP_R_MISSING_OCSPSIGNING_USAGE}, | |
| #else | |
| {"MISSING_OCSPSIGNING_USAGE", 39, 103}, | |
| #endif | |
| #ifdef OCSP_R_NEXTUPDATE_BEFORE_THISUPDATE | |
| {"NEXTUPDATE_BEFORE_THISUPDATE", ERR_LIB_OCSP, OCSP_R_NEXTUPDATE_BEFORE_THISUPDATE}, | |
| #else | |
| {"NEXTUPDATE_BEFORE_THISUPDATE", 39, 124}, | |
| #endif | |
| #ifdef OCSP_R_NOT_BASIC_RESPONSE | |
| {"NOT_BASIC_RESPONSE", ERR_LIB_OCSP, OCSP_R_NOT_BASIC_RESPONSE}, | |
| #else | |
| {"NOT_BASIC_RESPONSE", 39, 104}, | |
| #endif | |
| #ifdef OCSP_R_NO_CERTIFICATES_IN_CHAIN | |
| {"NO_CERTIFICATES_IN_CHAIN", ERR_LIB_OCSP, OCSP_R_NO_CERTIFICATES_IN_CHAIN}, | |
| #else | |
| {"NO_CERTIFICATES_IN_CHAIN", 39, 105}, | |
| #endif | |
| #ifdef OCSP_R_NO_RESPONSE_DATA | |
| {"NO_RESPONSE_DATA", ERR_LIB_OCSP, OCSP_R_NO_RESPONSE_DATA}, | |
| #else | |
| {"NO_RESPONSE_DATA", 39, 108}, | |
| #endif | |
| #ifdef OCSP_R_NO_REVOKED_TIME | |
| {"NO_REVOKED_TIME", ERR_LIB_OCSP, OCSP_R_NO_REVOKED_TIME}, | |
| #else | |
| {"NO_REVOKED_TIME", 39, 109}, | |
| #endif | |
| #ifdef OCSP_R_NO_SIGNER_KEY | |
| {"NO_SIGNER_KEY", ERR_LIB_OCSP, OCSP_R_NO_SIGNER_KEY}, | |
| #else | |
| {"NO_SIGNER_KEY", 39, 130}, | |
| #endif | |
| #ifdef OCSP_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", ERR_LIB_OCSP, OCSP_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE}, | |
| #else | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", 39, 110}, | |
| #endif | |
| #ifdef OCSP_R_REQUEST_NOT_SIGNED | |
| {"REQUEST_NOT_SIGNED", ERR_LIB_OCSP, OCSP_R_REQUEST_NOT_SIGNED}, | |
| #else | |
| {"REQUEST_NOT_SIGNED", 39, 128}, | |
| #endif | |
| #ifdef OCSP_R_RESPONSE_CONTAINS_NO_REVOCATION_DATA | |
| {"RESPONSE_CONTAINS_NO_REVOCATION_DATA", ERR_LIB_OCSP, OCSP_R_RESPONSE_CONTAINS_NO_REVOCATION_DATA}, | |
| #else | |
| {"RESPONSE_CONTAINS_NO_REVOCATION_DATA", 39, 111}, | |
| #endif | |
| #ifdef OCSP_R_ROOT_CA_NOT_TRUSTED | |
| {"ROOT_CA_NOT_TRUSTED", ERR_LIB_OCSP, OCSP_R_ROOT_CA_NOT_TRUSTED}, | |
| #else | |
| {"ROOT_CA_NOT_TRUSTED", 39, 112}, | |
| #endif | |
| #ifdef OCSP_R_SIGNATURE_FAILURE | |
| {"SIGNATURE_FAILURE", ERR_LIB_OCSP, OCSP_R_SIGNATURE_FAILURE}, | |
| #else | |
| {"SIGNATURE_FAILURE", 39, 117}, | |
| #endif | |
| #ifdef OCSP_R_SIGNER_CERTIFICATE_NOT_FOUND | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", ERR_LIB_OCSP, OCSP_R_SIGNER_CERTIFICATE_NOT_FOUND}, | |
| #else | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", 39, 118}, | |
| #endif | |
| #ifdef OCSP_R_STATUS_EXPIRED | |
| {"STATUS_EXPIRED", ERR_LIB_OCSP, OCSP_R_STATUS_EXPIRED}, | |
| #else | |
| {"STATUS_EXPIRED", 39, 125}, | |
| #endif | |
| #ifdef OCSP_R_STATUS_NOT_YET_VALID | |
| {"STATUS_NOT_YET_VALID", ERR_LIB_OCSP, OCSP_R_STATUS_NOT_YET_VALID}, | |
| #else | |
| {"STATUS_NOT_YET_VALID", 39, 126}, | |
| #endif | |
| #ifdef OCSP_R_STATUS_TOO_OLD | |
| {"STATUS_TOO_OLD", ERR_LIB_OCSP, OCSP_R_STATUS_TOO_OLD}, | |
| #else | |
| {"STATUS_TOO_OLD", 39, 127}, | |
| #endif | |
| #ifdef OCSP_R_UNKNOWN_MESSAGE_DIGEST | |
| {"UNKNOWN_MESSAGE_DIGEST", ERR_LIB_OCSP, OCSP_R_UNKNOWN_MESSAGE_DIGEST}, | |
| #else | |
| {"UNKNOWN_MESSAGE_DIGEST", 39, 119}, | |
| #endif | |
| #ifdef OCSP_R_UNKNOWN_NID | |
| {"UNKNOWN_NID", ERR_LIB_OCSP, OCSP_R_UNKNOWN_NID}, | |
| #else | |
| {"UNKNOWN_NID", 39, 120}, | |
| #endif | |
| #ifdef OCSP_R_UNSUPPORTED_REQUESTORNAME_TYPE | |
| {"UNSUPPORTED_REQUESTORNAME_TYPE", ERR_LIB_OCSP, OCSP_R_UNSUPPORTED_REQUESTORNAME_TYPE}, | |
| #else | |
| {"UNSUPPORTED_REQUESTORNAME_TYPE", 39, 129}, | |
| #endif | |
| #ifdef OSSL_DECODER_R_COULD_NOT_DECODE_OBJECT | |
| {"COULD_NOT_DECODE_OBJECT", ERR_LIB_OSSL_DECODER, OSSL_DECODER_R_COULD_NOT_DECODE_OBJECT}, | |
| #else | |
| {"COULD_NOT_DECODE_OBJECT", 60, 101}, | |
| #endif | |
| #ifdef OSSL_DECODER_R_DECODER_NOT_FOUND | |
| {"DECODER_NOT_FOUND", ERR_LIB_OSSL_DECODER, OSSL_DECODER_R_DECODER_NOT_FOUND}, | |
| #else | |
| {"DECODER_NOT_FOUND", 60, 102}, | |
| #endif | |
| #ifdef OSSL_DECODER_R_MISSING_GET_PARAMS | |
| {"MISSING_GET_PARAMS", ERR_LIB_OSSL_DECODER, OSSL_DECODER_R_MISSING_GET_PARAMS}, | |
| #else | |
| {"MISSING_GET_PARAMS", 60, 100}, | |
| #endif | |
| #ifdef OSSL_ENCODER_R_ENCODER_NOT_FOUND | |
| {"ENCODER_NOT_FOUND", ERR_LIB_OSSL_ENCODER, OSSL_ENCODER_R_ENCODER_NOT_FOUND}, | |
| #else | |
| {"ENCODER_NOT_FOUND", 59, 101}, | |
| #endif | |
| #ifdef OSSL_ENCODER_R_INCORRECT_PROPERTY_QUERY | |
| {"INCORRECT_PROPERTY_QUERY", ERR_LIB_OSSL_ENCODER, OSSL_ENCODER_R_INCORRECT_PROPERTY_QUERY}, | |
| #else | |
| {"INCORRECT_PROPERTY_QUERY", 59, 100}, | |
| #endif | |
| #ifdef OSSL_ENCODER_R_MISSING_GET_PARAMS | |
| {"MISSING_GET_PARAMS", ERR_LIB_OSSL_ENCODER, OSSL_ENCODER_R_MISSING_GET_PARAMS}, | |
| #else | |
| {"MISSING_GET_PARAMS", 59, 102}, | |
| #endif | |
| #ifdef OSSL_STORE_R_AMBIGUOUS_CONTENT_TYPE | |
| {"AMBIGUOUS_CONTENT_TYPE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_AMBIGUOUS_CONTENT_TYPE}, | |
| #else | |
| {"AMBIGUOUS_CONTENT_TYPE", 44, 107}, | |
| #endif | |
| #ifdef OSSL_STORE_R_BAD_PASSWORD_READ | |
| {"BAD_PASSWORD_READ", ERR_LIB_OSSL_STORE, OSSL_STORE_R_BAD_PASSWORD_READ}, | |
| #else | |
| {"BAD_PASSWORD_READ", 44, 115}, | |
| #endif | |
| #ifdef OSSL_STORE_R_ERROR_VERIFYING_PKCS12_MAC | |
| {"ERROR_VERIFYING_PKCS12_MAC", ERR_LIB_OSSL_STORE, OSSL_STORE_R_ERROR_VERIFYING_PKCS12_MAC}, | |
| #else | |
| {"ERROR_VERIFYING_PKCS12_MAC", 44, 113}, | |
| #endif | |
| #ifdef OSSL_STORE_R_FINGERPRINT_SIZE_DOES_NOT_MATCH_DIGEST | |
| {"FINGERPRINT_SIZE_DOES_NOT_MATCH_DIGEST", ERR_LIB_OSSL_STORE, OSSL_STORE_R_FINGERPRINT_SIZE_DOES_NOT_MATCH_DIGEST}, | |
| #else | |
| {"FINGERPRINT_SIZE_DOES_NOT_MATCH_DIGEST", 44, 121}, | |
| #endif | |
| #ifdef OSSL_STORE_R_INVALID_SCHEME | |
| {"INVALID_SCHEME", ERR_LIB_OSSL_STORE, OSSL_STORE_R_INVALID_SCHEME}, | |
| #else | |
| {"INVALID_SCHEME", 44, 106}, | |
| #endif | |
| #ifdef OSSL_STORE_R_IS_NOT_A | |
| {"IS_NOT_A", ERR_LIB_OSSL_STORE, OSSL_STORE_R_IS_NOT_A}, | |
| #else | |
| {"IS_NOT_A", 44, 112}, | |
| #endif | |
| #ifdef OSSL_STORE_R_LOADER_INCOMPLETE | |
| {"LOADER_INCOMPLETE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_LOADER_INCOMPLETE}, | |
| #else | |
| {"LOADER_INCOMPLETE", 44, 116}, | |
| #endif | |
| #ifdef OSSL_STORE_R_LOADING_STARTED | |
| {"LOADING_STARTED", ERR_LIB_OSSL_STORE, OSSL_STORE_R_LOADING_STARTED}, | |
| #else | |
| {"LOADING_STARTED", 44, 117}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_A_CERTIFICATE | |
| {"NOT_A_CERTIFICATE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_A_CERTIFICATE}, | |
| #else | |
| {"NOT_A_CERTIFICATE", 44, 100}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_A_CRL | |
| {"NOT_A_CRL", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_A_CRL}, | |
| #else | |
| {"NOT_A_CRL", 44, 101}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_A_NAME | |
| {"NOT_A_NAME", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_A_NAME}, | |
| #else | |
| {"NOT_A_NAME", 44, 103}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_A_PRIVATE_KEY | |
| {"NOT_A_PRIVATE_KEY", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_A_PRIVATE_KEY}, | |
| #else | |
| {"NOT_A_PRIVATE_KEY", 44, 102}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_A_PUBLIC_KEY | |
| {"NOT_A_PUBLIC_KEY", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_A_PUBLIC_KEY}, | |
| #else | |
| {"NOT_A_PUBLIC_KEY", 44, 122}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NOT_PARAMETERS | |
| {"NOT_PARAMETERS", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NOT_PARAMETERS}, | |
| #else | |
| {"NOT_PARAMETERS", 44, 104}, | |
| #endif | |
| #ifdef OSSL_STORE_R_NO_LOADERS_FOUND | |
| {"NO_LOADERS_FOUND", ERR_LIB_OSSL_STORE, OSSL_STORE_R_NO_LOADERS_FOUND}, | |
| #else | |
| {"NO_LOADERS_FOUND", 44, 123}, | |
| #endif | |
| #ifdef OSSL_STORE_R_PASSPHRASE_CALLBACK_ERROR | |
| {"PASSPHRASE_CALLBACK_ERROR", ERR_LIB_OSSL_STORE, OSSL_STORE_R_PASSPHRASE_CALLBACK_ERROR}, | |
| #else | |
| {"PASSPHRASE_CALLBACK_ERROR", 44, 114}, | |
| #endif | |
| #ifdef OSSL_STORE_R_PATH_MUST_BE_ABSOLUTE | |
| {"PATH_MUST_BE_ABSOLUTE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_PATH_MUST_BE_ABSOLUTE}, | |
| #else | |
| {"PATH_MUST_BE_ABSOLUTE", 44, 108}, | |
| #endif | |
| #ifdef OSSL_STORE_R_SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES | |
| {"SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES", ERR_LIB_OSSL_STORE, OSSL_STORE_R_SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES}, | |
| #else | |
| {"SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES", 44, 119}, | |
| #endif | |
| #ifdef OSSL_STORE_R_UI_PROCESS_INTERRUPTED_OR_CANCELLED | |
| {"UI_PROCESS_INTERRUPTED_OR_CANCELLED", ERR_LIB_OSSL_STORE, OSSL_STORE_R_UI_PROCESS_INTERRUPTED_OR_CANCELLED}, | |
| #else | |
| {"UI_PROCESS_INTERRUPTED_OR_CANCELLED", 44, 109}, | |
| #endif | |
| #ifdef OSSL_STORE_R_UNREGISTERED_SCHEME | |
| {"UNREGISTERED_SCHEME", ERR_LIB_OSSL_STORE, OSSL_STORE_R_UNREGISTERED_SCHEME}, | |
| #else | |
| {"UNREGISTERED_SCHEME", 44, 105}, | |
| #endif | |
| #ifdef OSSL_STORE_R_UNSUPPORTED_CONTENT_TYPE | |
| {"UNSUPPORTED_CONTENT_TYPE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_UNSUPPORTED_CONTENT_TYPE}, | |
| #else | |
| {"UNSUPPORTED_CONTENT_TYPE", 44, 110}, | |
| #endif | |
| #ifdef OSSL_STORE_R_UNSUPPORTED_OPERATION | |
| {"UNSUPPORTED_OPERATION", ERR_LIB_OSSL_STORE, OSSL_STORE_R_UNSUPPORTED_OPERATION}, | |
| #else | |
| {"UNSUPPORTED_OPERATION", 44, 118}, | |
| #endif | |
| #ifdef OSSL_STORE_R_UNSUPPORTED_SEARCH_TYPE | |
| {"UNSUPPORTED_SEARCH_TYPE", ERR_LIB_OSSL_STORE, OSSL_STORE_R_UNSUPPORTED_SEARCH_TYPE}, | |
| #else | |
| {"UNSUPPORTED_SEARCH_TYPE", 44, 120}, | |
| #endif | |
| #ifdef OSSL_STORE_R_URI_AUTHORITY_UNSUPPORTED | |
| {"URI_AUTHORITY_UNSUPPORTED", ERR_LIB_OSSL_STORE, OSSL_STORE_R_URI_AUTHORITY_UNSUPPORTED}, | |
| #else | |
| {"URI_AUTHORITY_UNSUPPORTED", 44, 111}, | |
| #endif | |
| #ifdef PEM_R_BAD_BASE64_DECODE | |
| {"BAD_BASE64_DECODE", ERR_LIB_PEM, PEM_R_BAD_BASE64_DECODE}, | |
| #else | |
| {"BAD_BASE64_DECODE", 9, 100}, | |
| #endif | |
| #ifdef PEM_R_BAD_DECRYPT | |
| {"BAD_DECRYPT", ERR_LIB_PEM, PEM_R_BAD_DECRYPT}, | |
| #else | |
| {"BAD_DECRYPT", 9, 101}, | |
| #endif | |
| #ifdef PEM_R_BAD_END_LINE | |
| {"BAD_END_LINE", ERR_LIB_PEM, PEM_R_BAD_END_LINE}, | |
| #else | |
| {"BAD_END_LINE", 9, 102}, | |
| #endif | |
| #ifdef PEM_R_BAD_IV_CHARS | |
| {"BAD_IV_CHARS", ERR_LIB_PEM, PEM_R_BAD_IV_CHARS}, | |
| #else | |
| {"BAD_IV_CHARS", 9, 103}, | |
| #endif | |
| #ifdef PEM_R_BAD_MAGIC_NUMBER | |
| {"BAD_MAGIC_NUMBER", ERR_LIB_PEM, PEM_R_BAD_MAGIC_NUMBER}, | |
| #else | |
| {"BAD_MAGIC_NUMBER", 9, 116}, | |
| #endif | |
| #ifdef PEM_R_BAD_PASSWORD_READ | |
| {"BAD_PASSWORD_READ", ERR_LIB_PEM, PEM_R_BAD_PASSWORD_READ}, | |
| #else | |
| {"BAD_PASSWORD_READ", 9, 104}, | |
| #endif | |
| #ifdef PEM_R_BAD_VERSION_NUMBER | |
| {"BAD_VERSION_NUMBER", ERR_LIB_PEM, PEM_R_BAD_VERSION_NUMBER}, | |
| #else | |
| {"BAD_VERSION_NUMBER", 9, 117}, | |
| #endif | |
| #ifdef PEM_R_BIO_WRITE_FAILURE | |
| {"BIO_WRITE_FAILURE", ERR_LIB_PEM, PEM_R_BIO_WRITE_FAILURE}, | |
| #else | |
| {"BIO_WRITE_FAILURE", 9, 118}, | |
| #endif | |
| #ifdef PEM_R_CIPHER_IS_NULL | |
| {"CIPHER_IS_NULL", ERR_LIB_PEM, PEM_R_CIPHER_IS_NULL}, | |
| #else | |
| {"CIPHER_IS_NULL", 9, 127}, | |
| #endif | |
| #ifdef PEM_R_ERROR_CONVERTING_PRIVATE_KEY | |
| {"ERROR_CONVERTING_PRIVATE_KEY", ERR_LIB_PEM, PEM_R_ERROR_CONVERTING_PRIVATE_KEY}, | |
| #else | |
| {"ERROR_CONVERTING_PRIVATE_KEY", 9, 115}, | |
| #endif | |
| #ifdef PEM_R_EXPECTING_DSS_KEY_BLOB | |
| {"EXPECTING_DSS_KEY_BLOB", ERR_LIB_PEM, PEM_R_EXPECTING_DSS_KEY_BLOB}, | |
| #else | |
| {"EXPECTING_DSS_KEY_BLOB", 9, 131}, | |
| #endif | |
| #ifdef PEM_R_EXPECTING_PRIVATE_KEY_BLOB | |
| {"EXPECTING_PRIVATE_KEY_BLOB", ERR_LIB_PEM, PEM_R_EXPECTING_PRIVATE_KEY_BLOB}, | |
| #else | |
| {"EXPECTING_PRIVATE_KEY_BLOB", 9, 119}, | |
| #endif | |
| #ifdef PEM_R_EXPECTING_PUBLIC_KEY_BLOB | |
| {"EXPECTING_PUBLIC_KEY_BLOB", ERR_LIB_PEM, PEM_R_EXPECTING_PUBLIC_KEY_BLOB}, | |
| #else | |
| {"EXPECTING_PUBLIC_KEY_BLOB", 9, 120}, | |
| #endif | |
| #ifdef PEM_R_EXPECTING_RSA_KEY_BLOB | |
| {"EXPECTING_RSA_KEY_BLOB", ERR_LIB_PEM, PEM_R_EXPECTING_RSA_KEY_BLOB}, | |
| #else | |
| {"EXPECTING_RSA_KEY_BLOB", 9, 132}, | |
| #endif | |
| #ifdef PEM_R_HEADER_TOO_LONG | |
| {"HEADER_TOO_LONG", ERR_LIB_PEM, PEM_R_HEADER_TOO_LONG}, | |
| #else | |
| {"HEADER_TOO_LONG", 9, 128}, | |
| #endif | |
| #ifdef PEM_R_INCONSISTENT_HEADER | |
| {"INCONSISTENT_HEADER", ERR_LIB_PEM, PEM_R_INCONSISTENT_HEADER}, | |
| #else | |
| {"INCONSISTENT_HEADER", 9, 121}, | |
| #endif | |
| #ifdef PEM_R_KEYBLOB_HEADER_PARSE_ERROR | |
| {"KEYBLOB_HEADER_PARSE_ERROR", ERR_LIB_PEM, PEM_R_KEYBLOB_HEADER_PARSE_ERROR}, | |
| #else | |
| {"KEYBLOB_HEADER_PARSE_ERROR", 9, 122}, | |
| #endif | |
| #ifdef PEM_R_KEYBLOB_TOO_SHORT | |
| {"KEYBLOB_TOO_SHORT", ERR_LIB_PEM, PEM_R_KEYBLOB_TOO_SHORT}, | |
| #else | |
| {"KEYBLOB_TOO_SHORT", 9, 123}, | |
| #endif | |
| #ifdef PEM_R_MISSING_DEK_IV | |
| {"MISSING_DEK_IV", ERR_LIB_PEM, PEM_R_MISSING_DEK_IV}, | |
| #else | |
| {"MISSING_DEK_IV", 9, 129}, | |
| #endif | |
| #ifdef PEM_R_NOT_DEK_INFO | |
| {"NOT_DEK_INFO", ERR_LIB_PEM, PEM_R_NOT_DEK_INFO}, | |
| #else | |
| {"NOT_DEK_INFO", 9, 105}, | |
| #endif | |
| #ifdef PEM_R_NOT_ENCRYPTED | |
| {"NOT_ENCRYPTED", ERR_LIB_PEM, PEM_R_NOT_ENCRYPTED}, | |
| #else | |
| {"NOT_ENCRYPTED", 9, 106}, | |
| #endif | |
| #ifdef PEM_R_NOT_PROC_TYPE | |
| {"NOT_PROC_TYPE", ERR_LIB_PEM, PEM_R_NOT_PROC_TYPE}, | |
| #else | |
| {"NOT_PROC_TYPE", 9, 107}, | |
| #endif | |
| #ifdef PEM_R_NO_START_LINE | |
| {"NO_START_LINE", ERR_LIB_PEM, PEM_R_NO_START_LINE}, | |
| #else | |
| {"NO_START_LINE", 9, 108}, | |
| #endif | |
| #ifdef PEM_R_PROBLEMS_GETTING_PASSWORD | |
| {"PROBLEMS_GETTING_PASSWORD", ERR_LIB_PEM, PEM_R_PROBLEMS_GETTING_PASSWORD}, | |
| #else | |
| {"PROBLEMS_GETTING_PASSWORD", 9, 109}, | |
| #endif | |
| #ifdef PEM_R_PVK_DATA_TOO_SHORT | |
| {"PVK_DATA_TOO_SHORT", ERR_LIB_PEM, PEM_R_PVK_DATA_TOO_SHORT}, | |
| #else | |
| {"PVK_DATA_TOO_SHORT", 9, 124}, | |
| #endif | |
| #ifdef PEM_R_PVK_TOO_SHORT | |
| {"PVK_TOO_SHORT", ERR_LIB_PEM, PEM_R_PVK_TOO_SHORT}, | |
| #else | |
| {"PVK_TOO_SHORT", 9, 125}, | |
| #endif | |
| #ifdef PEM_R_READ_KEY | |
| {"READ_KEY", ERR_LIB_PEM, PEM_R_READ_KEY}, | |
| #else | |
| {"READ_KEY", 9, 111}, | |
| #endif | |
| #ifdef PEM_R_SHORT_HEADER | |
| {"SHORT_HEADER", ERR_LIB_PEM, PEM_R_SHORT_HEADER}, | |
| #else | |
| {"SHORT_HEADER", 9, 112}, | |
| #endif | |
| #ifdef PEM_R_UNEXPECTED_DEK_IV | |
| {"UNEXPECTED_DEK_IV", ERR_LIB_PEM, PEM_R_UNEXPECTED_DEK_IV}, | |
| #else | |
| {"UNEXPECTED_DEK_IV", 9, 130}, | |
| #endif | |
| #ifdef PEM_R_UNSUPPORTED_CIPHER | |
| {"UNSUPPORTED_CIPHER", ERR_LIB_PEM, PEM_R_UNSUPPORTED_CIPHER}, | |
| #else | |
| {"UNSUPPORTED_CIPHER", 9, 113}, | |
| #endif | |
| #ifdef PEM_R_UNSUPPORTED_ENCRYPTION | |
| {"UNSUPPORTED_ENCRYPTION", ERR_LIB_PEM, PEM_R_UNSUPPORTED_ENCRYPTION}, | |
| #else | |
| {"UNSUPPORTED_ENCRYPTION", 9, 114}, | |
| #endif | |
| #ifdef PEM_R_UNSUPPORTED_KEY_COMPONENTS | |
| {"UNSUPPORTED_KEY_COMPONENTS", ERR_LIB_PEM, PEM_R_UNSUPPORTED_KEY_COMPONENTS}, | |
| #else | |
| {"UNSUPPORTED_KEY_COMPONENTS", 9, 126}, | |
| #endif | |
| #ifdef PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE | |
| {"UNSUPPORTED_PUBLIC_KEY_TYPE", ERR_LIB_PEM, PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_PUBLIC_KEY_TYPE", 9, 110}, | |
| #endif | |
| #ifdef PEM_R_UNSUPPORTED_PVK_KEY_TYPE | |
| {"UNSUPPORTED_PVK_KEY_TYPE", ERR_LIB_PEM, PEM_R_UNSUPPORTED_PVK_KEY_TYPE}, | |
| #else | |
| {"UNSUPPORTED_PVK_KEY_TYPE", 9, 133}, | |
| #endif | |
| #ifdef PKCS12_R_CALLBACK_FAILED | |
| {"CALLBACK_FAILED", ERR_LIB_PKCS12, PKCS12_R_CALLBACK_FAILED}, | |
| #else | |
| {"CALLBACK_FAILED", 35, 115}, | |
| #endif | |
| #ifdef PKCS12_R_CANT_PACK_STRUCTURE | |
| {"CANT_PACK_STRUCTURE", ERR_LIB_PKCS12, PKCS12_R_CANT_PACK_STRUCTURE}, | |
| #else | |
| {"CANT_PACK_STRUCTURE", 35, 100}, | |
| #endif | |
| #ifdef PKCS12_R_CONTENT_TYPE_NOT_DATA | |
| {"CONTENT_TYPE_NOT_DATA", ERR_LIB_PKCS12, PKCS12_R_CONTENT_TYPE_NOT_DATA}, | |
| #else | |
| {"CONTENT_TYPE_NOT_DATA", 35, 121}, | |
| #endif | |
| #ifdef PKCS12_R_DECODE_ERROR | |
| {"DECODE_ERROR", ERR_LIB_PKCS12, PKCS12_R_DECODE_ERROR}, | |
| #else | |
| {"DECODE_ERROR", 35, 101}, | |
| #endif | |
| #ifdef PKCS12_R_ENCODE_ERROR | |
| {"ENCODE_ERROR", ERR_LIB_PKCS12, PKCS12_R_ENCODE_ERROR}, | |
| #else | |
| {"ENCODE_ERROR", 35, 102}, | |
| #endif | |
| #ifdef PKCS12_R_ENCRYPT_ERROR | |
| {"ENCRYPT_ERROR", ERR_LIB_PKCS12, PKCS12_R_ENCRYPT_ERROR}, | |
| #else | |
| {"ENCRYPT_ERROR", 35, 103}, | |
| #endif | |
| #ifdef PKCS12_R_ERROR_SETTING_ENCRYPTED_DATA_TYPE | |
| {"ERROR_SETTING_ENCRYPTED_DATA_TYPE", ERR_LIB_PKCS12, PKCS12_R_ERROR_SETTING_ENCRYPTED_DATA_TYPE}, | |
| #else | |
| {"ERROR_SETTING_ENCRYPTED_DATA_TYPE", 35, 120}, | |
| #endif | |
| #ifdef PKCS12_R_INVALID_NULL_ARGUMENT | |
| {"INVALID_NULL_ARGUMENT", ERR_LIB_PKCS12, PKCS12_R_INVALID_NULL_ARGUMENT}, | |
| #else | |
| {"INVALID_NULL_ARGUMENT", 35, 104}, | |
| #endif | |
| #ifdef PKCS12_R_INVALID_NULL_PKCS12_POINTER | |
| {"INVALID_NULL_PKCS12_POINTER", ERR_LIB_PKCS12, PKCS12_R_INVALID_NULL_PKCS12_POINTER}, | |
| #else | |
| {"INVALID_NULL_PKCS12_POINTER", 35, 105}, | |
| #endif | |
| #ifdef PKCS12_R_INVALID_TYPE | |
| {"INVALID_TYPE", ERR_LIB_PKCS12, PKCS12_R_INVALID_TYPE}, | |
| #else | |
| {"INVALID_TYPE", 35, 112}, | |
| #endif | |
| #ifdef PKCS12_R_IV_GEN_ERROR | |
| {"IV_GEN_ERROR", ERR_LIB_PKCS12, PKCS12_R_IV_GEN_ERROR}, | |
| #else | |
| {"IV_GEN_ERROR", 35, 106}, | |
| #endif | |
| #ifdef PKCS12_R_KEY_GEN_ERROR | |
| {"KEY_GEN_ERROR", ERR_LIB_PKCS12, PKCS12_R_KEY_GEN_ERROR}, | |
| #else | |
| {"KEY_GEN_ERROR", 35, 107}, | |
| #endif | |
| #ifdef PKCS12_R_MAC_ABSENT | |
| {"MAC_ABSENT", ERR_LIB_PKCS12, PKCS12_R_MAC_ABSENT}, | |
| #else | |
| {"MAC_ABSENT", 35, 108}, | |
| #endif | |
| #ifdef PKCS12_R_MAC_GENERATION_ERROR | |
| {"MAC_GENERATION_ERROR", ERR_LIB_PKCS12, PKCS12_R_MAC_GENERATION_ERROR}, | |
| #else | |
| {"MAC_GENERATION_ERROR", 35, 109}, | |
| #endif | |
| #ifdef PKCS12_R_MAC_SETUP_ERROR | |
| {"MAC_SETUP_ERROR", ERR_LIB_PKCS12, PKCS12_R_MAC_SETUP_ERROR}, | |
| #else | |
| {"MAC_SETUP_ERROR", 35, 110}, | |
| #endif | |
| #ifdef PKCS12_R_MAC_STRING_SET_ERROR | |
| {"MAC_STRING_SET_ERROR", ERR_LIB_PKCS12, PKCS12_R_MAC_STRING_SET_ERROR}, | |
| #else | |
| {"MAC_STRING_SET_ERROR", 35, 111}, | |
| #endif | |
| #ifdef PKCS12_R_MAC_VERIFY_FAILURE | |
| {"MAC_VERIFY_FAILURE", ERR_LIB_PKCS12, PKCS12_R_MAC_VERIFY_FAILURE}, | |
| #else | |
| {"MAC_VERIFY_FAILURE", 35, 113}, | |
| #endif | |
| #ifdef PKCS12_R_PARSE_ERROR | |
| {"PARSE_ERROR", ERR_LIB_PKCS12, PKCS12_R_PARSE_ERROR}, | |
| #else | |
| {"PARSE_ERROR", 35, 114}, | |
| #endif | |
| #ifdef PKCS12_R_PKCS12_CIPHERFINAL_ERROR | |
| {"PKCS12_CIPHERFINAL_ERROR", ERR_LIB_PKCS12, PKCS12_R_PKCS12_CIPHERFINAL_ERROR}, | |
| #else | |
| {"PKCS12_CIPHERFINAL_ERROR", 35, 116}, | |
| #endif | |
| #ifdef PKCS12_R_UNKNOWN_DIGEST_ALGORITHM | |
| {"UNKNOWN_DIGEST_ALGORITHM", ERR_LIB_PKCS12, PKCS12_R_UNKNOWN_DIGEST_ALGORITHM}, | |
| #else | |
| {"UNKNOWN_DIGEST_ALGORITHM", 35, 118}, | |
| #endif | |
| #ifdef PKCS12_R_UNSUPPORTED_PKCS12_MODE | |
| {"UNSUPPORTED_PKCS12_MODE", ERR_LIB_PKCS12, PKCS12_R_UNSUPPORTED_PKCS12_MODE}, | |
| #else | |
| {"UNSUPPORTED_PKCS12_MODE", 35, 119}, | |
| #endif | |
| #ifdef PKCS7_R_CERTIFICATE_VERIFY_ERROR | |
| {"CERTIFICATE_VERIFY_ERROR", ERR_LIB_PKCS7, PKCS7_R_CERTIFICATE_VERIFY_ERROR}, | |
| #else | |
| {"CERTIFICATE_VERIFY_ERROR", 33, 117}, | |
| #endif | |
| #ifdef PKCS7_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER | |
| {"CIPHER_HAS_NO_OBJECT_IDENTIFIER", ERR_LIB_PKCS7, PKCS7_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER}, | |
| #else | |
| {"CIPHER_HAS_NO_OBJECT_IDENTIFIER", 33, 144}, | |
| #endif | |
| #ifdef PKCS7_R_CIPHER_NOT_INITIALIZED | |
| {"CIPHER_NOT_INITIALIZED", ERR_LIB_PKCS7, PKCS7_R_CIPHER_NOT_INITIALIZED}, | |
| #else | |
| {"CIPHER_NOT_INITIALIZED", 33, 116}, | |
| #endif | |
| #ifdef PKCS7_R_CONTENT_AND_DATA_PRESENT | |
| {"CONTENT_AND_DATA_PRESENT", ERR_LIB_PKCS7, PKCS7_R_CONTENT_AND_DATA_PRESENT}, | |
| #else | |
| {"CONTENT_AND_DATA_PRESENT", 33, 118}, | |
| #endif | |
| #ifdef PKCS7_R_CTRL_ERROR | |
| {"CTRL_ERROR", ERR_LIB_PKCS7, PKCS7_R_CTRL_ERROR}, | |
| #else | |
| {"CTRL_ERROR", 33, 152}, | |
| #endif | |
| #ifdef PKCS7_R_DECRYPT_ERROR | |
| {"DECRYPT_ERROR", ERR_LIB_PKCS7, PKCS7_R_DECRYPT_ERROR}, | |
| #else | |
| {"DECRYPT_ERROR", 33, 119}, | |
| #endif | |
| #ifdef PKCS7_R_DIGEST_FAILURE | |
| {"DIGEST_FAILURE", ERR_LIB_PKCS7, PKCS7_R_DIGEST_FAILURE}, | |
| #else | |
| {"DIGEST_FAILURE", 33, 101}, | |
| #endif | |
| #ifdef PKCS7_R_ENCRYPTION_CTRL_FAILURE | |
| {"ENCRYPTION_CTRL_FAILURE", ERR_LIB_PKCS7, PKCS7_R_ENCRYPTION_CTRL_FAILURE}, | |
| #else | |
| {"ENCRYPTION_CTRL_FAILURE", 33, 149}, | |
| #endif | |
| #ifdef PKCS7_R_ENCRYPTION_NOT_SUPPORTED_FOR_THIS_KEY_TYPE | |
| {"ENCRYPTION_NOT_SUPPORTED_FOR_THIS_KEY_TYPE", ERR_LIB_PKCS7, PKCS7_R_ENCRYPTION_NOT_SUPPORTED_FOR_THIS_KEY_TYPE}, | |
| #else | |
| {"ENCRYPTION_NOT_SUPPORTED_FOR_THIS_KEY_TYPE", 33, 150}, | |
| #endif | |
| #ifdef PKCS7_R_ERROR_ADDING_RECIPIENT | |
| {"ERROR_ADDING_RECIPIENT", ERR_LIB_PKCS7, PKCS7_R_ERROR_ADDING_RECIPIENT}, | |
| #else | |
| {"ERROR_ADDING_RECIPIENT", 33, 120}, | |
| #endif | |
| #ifdef PKCS7_R_ERROR_SETTING_CIPHER | |
| {"ERROR_SETTING_CIPHER", ERR_LIB_PKCS7, PKCS7_R_ERROR_SETTING_CIPHER}, | |
| #else | |
| {"ERROR_SETTING_CIPHER", 33, 121}, | |
| #endif | |
| #ifdef PKCS7_R_INVALID_NULL_POINTER | |
| {"INVALID_NULL_POINTER", ERR_LIB_PKCS7, PKCS7_R_INVALID_NULL_POINTER}, | |
| #else | |
| {"INVALID_NULL_POINTER", 33, 143}, | |
| #endif | |
| #ifdef PKCS7_R_INVALID_SIGNED_DATA_TYPE | |
| {"INVALID_SIGNED_DATA_TYPE", ERR_LIB_PKCS7, PKCS7_R_INVALID_SIGNED_DATA_TYPE}, | |
| #else | |
| {"INVALID_SIGNED_DATA_TYPE", 33, 155}, | |
| #endif | |
| #ifdef PKCS7_R_NO_CONTENT | |
| {"NO_CONTENT", ERR_LIB_PKCS7, PKCS7_R_NO_CONTENT}, | |
| #else | |
| {"NO_CONTENT", 33, 122}, | |
| #endif | |
| #ifdef PKCS7_R_NO_DEFAULT_DIGEST | |
| {"NO_DEFAULT_DIGEST", ERR_LIB_PKCS7, PKCS7_R_NO_DEFAULT_DIGEST}, | |
| #else | |
| {"NO_DEFAULT_DIGEST", 33, 151}, | |
| #endif | |
| #ifdef PKCS7_R_NO_MATCHING_DIGEST_TYPE_FOUND | |
| {"NO_MATCHING_DIGEST_TYPE_FOUND", ERR_LIB_PKCS7, PKCS7_R_NO_MATCHING_DIGEST_TYPE_FOUND}, | |
| #else | |
| {"NO_MATCHING_DIGEST_TYPE_FOUND", 33, 154}, | |
| #endif | |
| #ifdef PKCS7_R_NO_RECIPIENT_MATCHES_CERTIFICATE | |
| {"NO_RECIPIENT_MATCHES_CERTIFICATE", ERR_LIB_PKCS7, PKCS7_R_NO_RECIPIENT_MATCHES_CERTIFICATE}, | |
| #else | |
| {"NO_RECIPIENT_MATCHES_CERTIFICATE", 33, 115}, | |
| #endif | |
| #ifdef PKCS7_R_NO_SIGNATURES_ON_DATA | |
| {"NO_SIGNATURES_ON_DATA", ERR_LIB_PKCS7, PKCS7_R_NO_SIGNATURES_ON_DATA}, | |
| #else | |
| {"NO_SIGNATURES_ON_DATA", 33, 123}, | |
| #endif | |
| #ifdef PKCS7_R_NO_SIGNERS | |
| {"NO_SIGNERS", ERR_LIB_PKCS7, PKCS7_R_NO_SIGNERS}, | |
| #else | |
| {"NO_SIGNERS", 33, 142}, | |
| #endif | |
| #ifdef PKCS7_R_OPERATION_NOT_SUPPORTED_ON_THIS_TYPE | |
| {"OPERATION_NOT_SUPPORTED_ON_THIS_TYPE", ERR_LIB_PKCS7, PKCS7_R_OPERATION_NOT_SUPPORTED_ON_THIS_TYPE}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED_ON_THIS_TYPE", 33, 104}, | |
| #endif | |
| #ifdef PKCS7_R_PKCS7_ADD_SIGNATURE_ERROR | |
| {"PKCS7_ADD_SIGNATURE_ERROR", ERR_LIB_PKCS7, PKCS7_R_PKCS7_ADD_SIGNATURE_ERROR}, | |
| #else | |
| {"PKCS7_ADD_SIGNATURE_ERROR", 33, 124}, | |
| #endif | |
| #ifdef PKCS7_R_PKCS7_ADD_SIGNER_ERROR | |
| {"PKCS7_ADD_SIGNER_ERROR", ERR_LIB_PKCS7, PKCS7_R_PKCS7_ADD_SIGNER_ERROR}, | |
| #else | |
| {"PKCS7_ADD_SIGNER_ERROR", 33, 153}, | |
| #endif | |
| #ifdef PKCS7_R_PKCS7_DATASIGN | |
| {"PKCS7_DATASIGN", ERR_LIB_PKCS7, PKCS7_R_PKCS7_DATASIGN}, | |
| #else | |
| {"PKCS7_DATASIGN", 33, 145}, | |
| #endif | |
| #ifdef PKCS7_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", ERR_LIB_PKCS7, PKCS7_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE}, | |
| #else | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", 33, 127}, | |
| #endif | |
| #ifdef PKCS7_R_SIGNATURE_FAILURE | |
| {"SIGNATURE_FAILURE", ERR_LIB_PKCS7, PKCS7_R_SIGNATURE_FAILURE}, | |
| #else | |
| {"SIGNATURE_FAILURE", 33, 105}, | |
| #endif | |
| #ifdef PKCS7_R_SIGNER_CERTIFICATE_NOT_FOUND | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", ERR_LIB_PKCS7, PKCS7_R_SIGNER_CERTIFICATE_NOT_FOUND}, | |
| #else | |
| {"SIGNER_CERTIFICATE_NOT_FOUND", 33, 128}, | |
| #endif | |
| #ifdef PKCS7_R_SIGNING_CTRL_FAILURE | |
| {"SIGNING_CTRL_FAILURE", ERR_LIB_PKCS7, PKCS7_R_SIGNING_CTRL_FAILURE}, | |
| #else | |
| {"SIGNING_CTRL_FAILURE", 33, 147}, | |
| #endif | |
| #ifdef PKCS7_R_SIGNING_NOT_SUPPORTED_FOR_THIS_KEY_TYPE | |
| {"SIGNING_NOT_SUPPORTED_FOR_THIS_KEY_TYPE", ERR_LIB_PKCS7, PKCS7_R_SIGNING_NOT_SUPPORTED_FOR_THIS_KEY_TYPE}, | |
| #else | |
| {"SIGNING_NOT_SUPPORTED_FOR_THIS_KEY_TYPE", 33, 148}, | |
| #endif | |
| #ifdef PKCS7_R_SMIME_TEXT_ERROR | |
| {"SMIME_TEXT_ERROR", ERR_LIB_PKCS7, PKCS7_R_SMIME_TEXT_ERROR}, | |
| #else | |
| {"SMIME_TEXT_ERROR", 33, 129}, | |
| #endif | |
| #ifdef PKCS7_R_UNABLE_TO_FIND_CERTIFICATE | |
| {"UNABLE_TO_FIND_CERTIFICATE", ERR_LIB_PKCS7, PKCS7_R_UNABLE_TO_FIND_CERTIFICATE}, | |
| #else | |
| {"UNABLE_TO_FIND_CERTIFICATE", 33, 106}, | |
| #endif | |
| #ifdef PKCS7_R_UNABLE_TO_FIND_MEM_BIO | |
| {"UNABLE_TO_FIND_MEM_BIO", ERR_LIB_PKCS7, PKCS7_R_UNABLE_TO_FIND_MEM_BIO}, | |
| #else | |
| {"UNABLE_TO_FIND_MEM_BIO", 33, 107}, | |
| #endif | |
| #ifdef PKCS7_R_UNABLE_TO_FIND_MESSAGE_DIGEST | |
| {"UNABLE_TO_FIND_MESSAGE_DIGEST", ERR_LIB_PKCS7, PKCS7_R_UNABLE_TO_FIND_MESSAGE_DIGEST}, | |
| #else | |
| {"UNABLE_TO_FIND_MESSAGE_DIGEST", 33, 108}, | |
| #endif | |
| #ifdef PKCS7_R_UNKNOWN_DIGEST_TYPE | |
| {"UNKNOWN_DIGEST_TYPE", ERR_LIB_PKCS7, PKCS7_R_UNKNOWN_DIGEST_TYPE}, | |
| #else | |
| {"UNKNOWN_DIGEST_TYPE", 33, 109}, | |
| #endif | |
| #ifdef PKCS7_R_UNKNOWN_OPERATION | |
| {"UNKNOWN_OPERATION", ERR_LIB_PKCS7, PKCS7_R_UNKNOWN_OPERATION}, | |
| #else | |
| {"UNKNOWN_OPERATION", 33, 110}, | |
| #endif | |
| #ifdef PKCS7_R_UNSUPPORTED_CIPHER_TYPE | |
| {"UNSUPPORTED_CIPHER_TYPE", ERR_LIB_PKCS7, PKCS7_R_UNSUPPORTED_CIPHER_TYPE}, | |
| #else | |
| {"UNSUPPORTED_CIPHER_TYPE", 33, 111}, | |
| #endif | |
| #ifdef PKCS7_R_UNSUPPORTED_CONTENT_TYPE | |
| {"UNSUPPORTED_CONTENT_TYPE", ERR_LIB_PKCS7, PKCS7_R_UNSUPPORTED_CONTENT_TYPE}, | |
| #else | |
| {"UNSUPPORTED_CONTENT_TYPE", 33, 112}, | |
| #endif | |
| #ifdef PKCS7_R_WRONG_CONTENT_TYPE | |
| {"WRONG_CONTENT_TYPE", ERR_LIB_PKCS7, PKCS7_R_WRONG_CONTENT_TYPE}, | |
| #else | |
| {"WRONG_CONTENT_TYPE", 33, 113}, | |
| #endif | |
| #ifdef PKCS7_R_WRONG_PKCS7_TYPE | |
| {"WRONG_PKCS7_TYPE", ERR_LIB_PKCS7, PKCS7_R_WRONG_PKCS7_TYPE}, | |
| #else | |
| {"WRONG_PKCS7_TYPE", 33, 114}, | |
| #endif | |
| #ifdef PROP_R_NAME_TOO_LONG | |
| {"NAME_TOO_LONG", ERR_LIB_PROP, PROP_R_NAME_TOO_LONG}, | |
| #else | |
| {"NAME_TOO_LONG", 55, 100}, | |
| #endif | |
| #ifdef PROP_R_NOT_AN_ASCII_CHARACTER | |
| {"NOT_AN_ASCII_CHARACTER", ERR_LIB_PROP, PROP_R_NOT_AN_ASCII_CHARACTER}, | |
| #else | |
| {"NOT_AN_ASCII_CHARACTER", 55, 101}, | |
| #endif | |
| #ifdef PROP_R_NOT_AN_HEXADECIMAL_DIGIT | |
| {"NOT_AN_HEXADECIMAL_DIGIT", ERR_LIB_PROP, PROP_R_NOT_AN_HEXADECIMAL_DIGIT}, | |
| #else | |
| {"NOT_AN_HEXADECIMAL_DIGIT", 55, 102}, | |
| #endif | |
| #ifdef PROP_R_NOT_AN_IDENTIFIER | |
| {"NOT_AN_IDENTIFIER", ERR_LIB_PROP, PROP_R_NOT_AN_IDENTIFIER}, | |
| #else | |
| {"NOT_AN_IDENTIFIER", 55, 103}, | |
| #endif | |
| #ifdef PROP_R_NOT_AN_OCTAL_DIGIT | |
| {"NOT_AN_OCTAL_DIGIT", ERR_LIB_PROP, PROP_R_NOT_AN_OCTAL_DIGIT}, | |
| #else | |
| {"NOT_AN_OCTAL_DIGIT", 55, 104}, | |
| #endif | |
| #ifdef PROP_R_NOT_A_DECIMAL_DIGIT | |
| {"NOT_A_DECIMAL_DIGIT", ERR_LIB_PROP, PROP_R_NOT_A_DECIMAL_DIGIT}, | |
| #else | |
| {"NOT_A_DECIMAL_DIGIT", 55, 105}, | |
| #endif | |
| #ifdef PROP_R_NO_MATCHING_STRING_DELIMITER | |
| {"NO_MATCHING_STRING_DELIMITER", ERR_LIB_PROP, PROP_R_NO_MATCHING_STRING_DELIMITER}, | |
| #else | |
| {"NO_MATCHING_STRING_DELIMITER", 55, 106}, | |
| #endif | |
| #ifdef PROP_R_NO_VALUE | |
| {"NO_VALUE", ERR_LIB_PROP, PROP_R_NO_VALUE}, | |
| #else | |
| {"NO_VALUE", 55, 107}, | |
| #endif | |
| #ifdef PROP_R_PARSE_FAILED | |
| {"PARSE_FAILED", ERR_LIB_PROP, PROP_R_PARSE_FAILED}, | |
| #else | |
| {"PARSE_FAILED", 55, 108}, | |
| #endif | |
| #ifdef PROP_R_STRING_TOO_LONG | |
| {"STRING_TOO_LONG", ERR_LIB_PROP, PROP_R_STRING_TOO_LONG}, | |
| #else | |
| {"STRING_TOO_LONG", 55, 109}, | |
| #endif | |
| #ifdef PROP_R_TRAILING_CHARACTERS | |
| {"TRAILING_CHARACTERS", ERR_LIB_PROP, PROP_R_TRAILING_CHARACTERS}, | |
| #else | |
| {"TRAILING_CHARACTERS", 55, 110}, | |
| #endif | |
| #ifdef PROV_R_ADDITIONAL_INPUT_TOO_LONG | |
| {"ADDITIONAL_INPUT_TOO_LONG", ERR_LIB_PROV, PROV_R_ADDITIONAL_INPUT_TOO_LONG}, | |
| #else | |
| {"ADDITIONAL_INPUT_TOO_LONG", 57, 184}, | |
| #endif | |
| #ifdef PROV_R_ALGORITHM_MISMATCH | |
| {"ALGORITHM_MISMATCH", ERR_LIB_PROV, PROV_R_ALGORITHM_MISMATCH}, | |
| #else | |
| {"ALGORITHM_MISMATCH", 57, 173}, | |
| #endif | |
| #ifdef PROV_R_ALREADY_INSTANTIATED | |
| {"ALREADY_INSTANTIATED", ERR_LIB_PROV, PROV_R_ALREADY_INSTANTIATED}, | |
| #else | |
| {"ALREADY_INSTANTIATED", 57, 185}, | |
| #endif | |
| #ifdef PROV_R_BAD_DECRYPT | |
| {"BAD_DECRYPT", ERR_LIB_PROV, PROV_R_BAD_DECRYPT}, | |
| #else | |
| {"BAD_DECRYPT", 57, 100}, | |
| #endif | |
| #ifdef PROV_R_BAD_ENCODING | |
| {"BAD_ENCODING", ERR_LIB_PROV, PROV_R_BAD_ENCODING}, | |
| #else | |
| {"BAD_ENCODING", 57, 141}, | |
| #endif | |
| #ifdef PROV_R_BAD_LENGTH | |
| {"BAD_LENGTH", ERR_LIB_PROV, PROV_R_BAD_LENGTH}, | |
| #else | |
| {"BAD_LENGTH", 57, 142}, | |
| #endif | |
| #ifdef PROV_R_BAD_TLS_CLIENT_VERSION | |
| {"BAD_TLS_CLIENT_VERSION", ERR_LIB_PROV, PROV_R_BAD_TLS_CLIENT_VERSION}, | |
| #else | |
| {"BAD_TLS_CLIENT_VERSION", 57, 161}, | |
| #endif | |
| #ifdef PROV_R_BN_ERROR | |
| {"BN_ERROR", ERR_LIB_PROV, PROV_R_BN_ERROR}, | |
| #else | |
| {"BN_ERROR", 57, 160}, | |
| #endif | |
| #ifdef PROV_R_CIPHER_OPERATION_FAILED | |
| {"CIPHER_OPERATION_FAILED", ERR_LIB_PROV, PROV_R_CIPHER_OPERATION_FAILED}, | |
| #else | |
| {"CIPHER_OPERATION_FAILED", 57, 102}, | |
| #endif | |
| #ifdef PROV_R_COFACTOR_REQUIRED | |
| {"COFACTOR_REQUIRED", ERR_LIB_PROV, PROV_R_COFACTOR_REQUIRED}, | |
| #else | |
| {"COFACTOR_REQUIRED", 57, 236}, | |
| #endif | |
| #ifdef PROV_R_DERIVATION_FUNCTION_INIT_FAILED | |
| {"DERIVATION_FUNCTION_INIT_FAILED", ERR_LIB_PROV, PROV_R_DERIVATION_FUNCTION_INIT_FAILED}, | |
| #else | |
| {"DERIVATION_FUNCTION_INIT_FAILED", 57, 205}, | |
| #endif | |
| #ifdef PROV_R_DIGEST_NOT_ALLOWED | |
| {"DIGEST_NOT_ALLOWED", ERR_LIB_PROV, PROV_R_DIGEST_NOT_ALLOWED}, | |
| #else | |
| {"DIGEST_NOT_ALLOWED", 57, 174}, | |
| #endif | |
| #ifdef PROV_R_EMS_NOT_ENABLED | |
| {"EMS_NOT_ENABLED", ERR_LIB_PROV, PROV_R_EMS_NOT_ENABLED}, | |
| #else | |
| {"EMS_NOT_ENABLED", 57, 233}, | |
| #endif | |
| #ifdef PROV_R_ENTROPY_SOURCE_FAILED_CONTINUOUS_TESTS | |
| {"ENTROPY_SOURCE_FAILED_CONTINUOUS_TESTS", ERR_LIB_PROV, PROV_R_ENTROPY_SOURCE_FAILED_CONTINUOUS_TESTS}, | |
| #else | |
| {"ENTROPY_SOURCE_FAILED_CONTINUOUS_TESTS", 57, 244}, | |
| #endif | |
| #ifdef PROV_R_ENTROPY_SOURCE_STRENGTH_TOO_WEAK | |
| {"ENTROPY_SOURCE_STRENGTH_TOO_WEAK", ERR_LIB_PROV, PROV_R_ENTROPY_SOURCE_STRENGTH_TOO_WEAK}, | |
| #else | |
| {"ENTROPY_SOURCE_STRENGTH_TOO_WEAK", 57, 186}, | |
| #endif | |
| #ifdef PROV_R_ERROR_INSTANTIATING_DRBG | |
| {"ERROR_INSTANTIATING_DRBG", ERR_LIB_PROV, PROV_R_ERROR_INSTANTIATING_DRBG}, | |
| #else | |
| {"ERROR_INSTANTIATING_DRBG", 57, 188}, | |
| #endif | |
| #ifdef PROV_R_ERROR_RETRIEVING_ENTROPY | |
| {"ERROR_RETRIEVING_ENTROPY", ERR_LIB_PROV, PROV_R_ERROR_RETRIEVING_ENTROPY}, | |
| #else | |
| {"ERROR_RETRIEVING_ENTROPY", 57, 189}, | |
| #endif | |
| #ifdef PROV_R_ERROR_RETRIEVING_NONCE | |
| {"ERROR_RETRIEVING_NONCE", ERR_LIB_PROV, PROV_R_ERROR_RETRIEVING_NONCE}, | |
| #else | |
| {"ERROR_RETRIEVING_NONCE", 57, 190}, | |
| #endif | |
| #ifdef PROV_R_FAILED_DURING_DERIVATION | |
| {"FAILED_DURING_DERIVATION", ERR_LIB_PROV, PROV_R_FAILED_DURING_DERIVATION}, | |
| #else | |
| {"FAILED_DURING_DERIVATION", 57, 164}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_CREATE_LOCK | |
| {"FAILED_TO_CREATE_LOCK", ERR_LIB_PROV, PROV_R_FAILED_TO_CREATE_LOCK}, | |
| #else | |
| {"FAILED_TO_CREATE_LOCK", 57, 180}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_DECRYPT | |
| {"FAILED_TO_DECRYPT", ERR_LIB_PROV, PROV_R_FAILED_TO_DECRYPT}, | |
| #else | |
| {"FAILED_TO_DECRYPT", 57, 162}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_GENERATE_KEY | |
| {"FAILED_TO_GENERATE_KEY", ERR_LIB_PROV, PROV_R_FAILED_TO_GENERATE_KEY}, | |
| #else | |
| {"FAILED_TO_GENERATE_KEY", 57, 121}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_GET_PARAMETER | |
| {"FAILED_TO_GET_PARAMETER", ERR_LIB_PROV, PROV_R_FAILED_TO_GET_PARAMETER}, | |
| #else | |
| {"FAILED_TO_GET_PARAMETER", 57, 103}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_SET_PARAMETER | |
| {"FAILED_TO_SET_PARAMETER", ERR_LIB_PROV, PROV_R_FAILED_TO_SET_PARAMETER}, | |
| #else | |
| {"FAILED_TO_SET_PARAMETER", 57, 104}, | |
| #endif | |
| #ifdef PROV_R_FAILED_TO_SIGN | |
| {"FAILED_TO_SIGN", ERR_LIB_PROV, PROV_R_FAILED_TO_SIGN}, | |
| #else | |
| {"FAILED_TO_SIGN", 57, 175}, | |
| #endif | |
| #ifdef PROV_R_FINAL_CALL_OUT_OF_ORDER | |
| {"FINAL_CALL_OUT_OF_ORDER", ERR_LIB_PROV, PROV_R_FINAL_CALL_OUT_OF_ORDER}, | |
| #else | |
| {"FINAL_CALL_OUT_OF_ORDER", 57, 237}, | |
| #endif | |
| #ifdef PROV_R_FIPS_MODULE_CONDITIONAL_ERROR | |
| {"FIPS_MODULE_CONDITIONAL_ERROR", ERR_LIB_PROV, PROV_R_FIPS_MODULE_CONDITIONAL_ERROR}, | |
| #else | |
| {"FIPS_MODULE_CONDITIONAL_ERROR", 57, 227}, | |
| #endif | |
| #ifdef PROV_R_FIPS_MODULE_ENTERING_ERROR_STATE | |
| {"FIPS_MODULE_ENTERING_ERROR_STATE", ERR_LIB_PROV, PROV_R_FIPS_MODULE_ENTERING_ERROR_STATE}, | |
| #else | |
| {"FIPS_MODULE_ENTERING_ERROR_STATE", 57, 224}, | |
| #endif | |
| #ifdef PROV_R_FIPS_MODULE_IMPORT_PCT_ERROR | |
| {"FIPS_MODULE_IMPORT_PCT_ERROR", ERR_LIB_PROV, PROV_R_FIPS_MODULE_IMPORT_PCT_ERROR}, | |
| #else | |
| {"FIPS_MODULE_IMPORT_PCT_ERROR", 57, 253}, | |
| #endif | |
| #ifdef PROV_R_FIPS_MODULE_IN_ERROR_STATE | |
| {"FIPS_MODULE_IN_ERROR_STATE", ERR_LIB_PROV, PROV_R_FIPS_MODULE_IN_ERROR_STATE}, | |
| #else | |
| {"FIPS_MODULE_IN_ERROR_STATE", 57, 225}, | |
| #endif | |
| #ifdef PROV_R_GENERATE_ERROR | |
| {"GENERATE_ERROR", ERR_LIB_PROV, PROV_R_GENERATE_ERROR}, | |
| #else | |
| {"GENERATE_ERROR", 57, 191}, | |
| #endif | |
| #ifdef PROV_R_ILLEGAL_OR_UNSUPPORTED_PADDING_MODE | |
| {"ILLEGAL_OR_UNSUPPORTED_PADDING_MODE", ERR_LIB_PROV, PROV_R_ILLEGAL_OR_UNSUPPORTED_PADDING_MODE}, | |
| #else | |
| {"ILLEGAL_OR_UNSUPPORTED_PADDING_MODE", 57, 165}, | |
| #endif | |
| #ifdef PROV_R_INDICATOR_INTEGRITY_FAILURE | |
| {"INDICATOR_INTEGRITY_FAILURE", ERR_LIB_PROV, PROV_R_INDICATOR_INTEGRITY_FAILURE}, | |
| #else | |
| {"INDICATOR_INTEGRITY_FAILURE", 57, 210}, | |
| #endif | |
| #ifdef PROV_R_INIT_CALL_OUT_OF_ORDER | |
| {"INIT_CALL_OUT_OF_ORDER", ERR_LIB_PROV, PROV_R_INIT_CALL_OUT_OF_ORDER}, | |
| #else | |
| {"INIT_CALL_OUT_OF_ORDER", 57, 238}, | |
| #endif | |
| #ifdef PROV_R_INSUFFICIENT_DRBG_STRENGTH | |
| {"INSUFFICIENT_DRBG_STRENGTH", ERR_LIB_PROV, PROV_R_INSUFFICIENT_DRBG_STRENGTH}, | |
| #else | |
| {"INSUFFICIENT_DRBG_STRENGTH", 57, 181}, | |
| #endif | |
| #ifdef PROV_R_INVALID_AAD | |
| {"INVALID_AAD", ERR_LIB_PROV, PROV_R_INVALID_AAD}, | |
| #else | |
| {"INVALID_AAD", 57, 108}, | |
| #endif | |
| #ifdef PROV_R_INVALID_AEAD | |
| {"INVALID_AEAD", ERR_LIB_PROV, PROV_R_INVALID_AEAD}, | |
| #else | |
| {"INVALID_AEAD", 57, 231}, | |
| #endif | |
| #ifdef PROV_R_INVALID_CONFIG_DATA | |
| {"INVALID_CONFIG_DATA", ERR_LIB_PROV, PROV_R_INVALID_CONFIG_DATA}, | |
| #else | |
| {"INVALID_CONFIG_DATA", 57, 211}, | |
| #endif | |
| #ifdef PROV_R_INVALID_CONSTANT_LENGTH | |
| {"INVALID_CONSTANT_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_CONSTANT_LENGTH}, | |
| #else | |
| {"INVALID_CONSTANT_LENGTH", 57, 157}, | |
| #endif | |
| #ifdef PROV_R_INVALID_CURVE | |
| {"INVALID_CURVE", ERR_LIB_PROV, PROV_R_INVALID_CURVE}, | |
| #else | |
| {"INVALID_CURVE", 57, 176}, | |
| #endif | |
| #ifdef PROV_R_INVALID_CUSTOM_LENGTH | |
| {"INVALID_CUSTOM_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_CUSTOM_LENGTH}, | |
| #else | |
| {"INVALID_CUSTOM_LENGTH", 57, 111}, | |
| #endif | |
| #ifdef PROV_R_INVALID_DATA | |
| {"INVALID_DATA", ERR_LIB_PROV, PROV_R_INVALID_DATA}, | |
| #else | |
| {"INVALID_DATA", 57, 115}, | |
| #endif | |
| #ifdef PROV_R_INVALID_DIGEST | |
| {"INVALID_DIGEST", ERR_LIB_PROV, PROV_R_INVALID_DIGEST}, | |
| #else | |
| {"INVALID_DIGEST", 57, 122}, | |
| #endif | |
| #ifdef PROV_R_INVALID_DIGEST_LENGTH | |
| {"INVALID_DIGEST_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_DIGEST_LENGTH}, | |
| #else | |
| {"INVALID_DIGEST_LENGTH", 57, 166}, | |
| #endif | |
| #ifdef PROV_R_INVALID_DIGEST_SIZE | |
| {"INVALID_DIGEST_SIZE", ERR_LIB_PROV, PROV_R_INVALID_DIGEST_SIZE}, | |
| #else | |
| {"INVALID_DIGEST_SIZE", 57, 218}, | |
| #endif | |
| #ifdef PROV_R_INVALID_EDDSA_INSTANCE_FOR_ATTEMPTED_OPERATION | |
| {"INVALID_EDDSA_INSTANCE_FOR_ATTEMPTED_OPERATION", ERR_LIB_PROV, PROV_R_INVALID_EDDSA_INSTANCE_FOR_ATTEMPTED_OPERATION}, | |
| #else | |
| {"INVALID_EDDSA_INSTANCE_FOR_ATTEMPTED_OPERATION", 57, 243}, | |
| #endif | |
| #ifdef PROV_R_INVALID_INPUT_LENGTH | |
| {"INVALID_INPUT_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_INPUT_LENGTH}, | |
| #else | |
| {"INVALID_INPUT_LENGTH", 57, 230}, | |
| #endif | |
| #ifdef PROV_R_INVALID_ITERATION_COUNT | |
| {"INVALID_ITERATION_COUNT", ERR_LIB_PROV, PROV_R_INVALID_ITERATION_COUNT}, | |
| #else | |
| {"INVALID_ITERATION_COUNT", 57, 123}, | |
| #endif | |
| #ifdef PROV_R_INVALID_IV_LENGTH | |
| {"INVALID_IV_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_IV_LENGTH}, | |
| #else | |
| {"INVALID_IV_LENGTH", 57, 109}, | |
| #endif | |
| #ifdef PROV_R_INVALID_KDF | |
| {"INVALID_KDF", ERR_LIB_PROV, PROV_R_INVALID_KDF}, | |
| #else | |
| {"INVALID_KDF", 57, 232}, | |
| #endif | |
| #ifdef PROV_R_INVALID_KEY | |
| {"INVALID_KEY", ERR_LIB_PROV, PROV_R_INVALID_KEY}, | |
| #else | |
| {"INVALID_KEY", 57, 158}, | |
| #endif | |
| #ifdef PROV_R_INVALID_KEY_LENGTH | |
| {"INVALID_KEY_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_KEY_LENGTH}, | |
| #else | |
| {"INVALID_KEY_LENGTH", 57, 105}, | |
| #endif | |
| #ifdef PROV_R_INVALID_MAC | |
| {"INVALID_MAC", ERR_LIB_PROV, PROV_R_INVALID_MAC}, | |
| #else | |
| {"INVALID_MAC", 57, 151}, | |
| #endif | |
| #ifdef PROV_R_INVALID_MEMORY_SIZE | |
| {"INVALID_MEMORY_SIZE", ERR_LIB_PROV, PROV_R_INVALID_MEMORY_SIZE}, | |
| #else | |
| {"INVALID_MEMORY_SIZE", 57, 235}, | |
| #endif | |
| #ifdef PROV_R_INVALID_MGF1_MD | |
| {"INVALID_MGF1_MD", ERR_LIB_PROV, PROV_R_INVALID_MGF1_MD}, | |
| #else | |
| {"INVALID_MGF1_MD", 57, 167}, | |
| #endif | |
| #ifdef PROV_R_INVALID_MODE | |
| {"INVALID_MODE", ERR_LIB_PROV, PROV_R_INVALID_MODE}, | |
| #else | |
| {"INVALID_MODE", 57, 125}, | |
| #endif | |
| #ifdef PROV_R_INVALID_OUTPUT_LENGTH | |
| {"INVALID_OUTPUT_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_OUTPUT_LENGTH}, | |
| #else | |
| {"INVALID_OUTPUT_LENGTH", 57, 217}, | |
| #endif | |
| #ifdef PROV_R_INVALID_PADDING_MODE | |
| {"INVALID_PADDING_MODE", ERR_LIB_PROV, PROV_R_INVALID_PADDING_MODE}, | |
| #else | |
| {"INVALID_PADDING_MODE", 57, 168}, | |
| #endif | |
| #ifdef PROV_R_INVALID_PREHASHED_DIGEST_LENGTH | |
| {"INVALID_PREHASHED_DIGEST_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_PREHASHED_DIGEST_LENGTH}, | |
| #else | |
| {"INVALID_PREHASHED_DIGEST_LENGTH", 57, 241}, | |
| #endif | |
| #ifdef PROV_R_INVALID_PUBINFO | |
| {"INVALID_PUBINFO", ERR_LIB_PROV, PROV_R_INVALID_PUBINFO}, | |
| #else | |
| {"INVALID_PUBINFO", 57, 198}, | |
| #endif | |
| #ifdef PROV_R_INVALID_SALT_LENGTH | |
| {"INVALID_SALT_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_SALT_LENGTH}, | |
| #else | |
| {"INVALID_SALT_LENGTH", 57, 112}, | |
| #endif | |
| #ifdef PROV_R_INVALID_SEED_LENGTH | |
| {"INVALID_SEED_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_SEED_LENGTH}, | |
| #else | |
| {"INVALID_SEED_LENGTH", 57, 154}, | |
| #endif | |
| #ifdef PROV_R_INVALID_SIGNATURE_SIZE | |
| {"INVALID_SIGNATURE_SIZE", ERR_LIB_PROV, PROV_R_INVALID_SIGNATURE_SIZE}, | |
| #else | |
| {"INVALID_SIGNATURE_SIZE", 57, 179}, | |
| #endif | |
| #ifdef PROV_R_INVALID_STATE | |
| {"INVALID_STATE", ERR_LIB_PROV, PROV_R_INVALID_STATE}, | |
| #else | |
| {"INVALID_STATE", 57, 212}, | |
| #endif | |
| #ifdef PROV_R_INVALID_TAG | |
| {"INVALID_TAG", ERR_LIB_PROV, PROV_R_INVALID_TAG}, | |
| #else | |
| {"INVALID_TAG", 57, 110}, | |
| #endif | |
| #ifdef PROV_R_INVALID_TAG_LENGTH | |
| {"INVALID_TAG_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_TAG_LENGTH}, | |
| #else | |
| {"INVALID_TAG_LENGTH", 57, 118}, | |
| #endif | |
| #ifdef PROV_R_INVALID_THREAD_POOL_SIZE | |
| {"INVALID_THREAD_POOL_SIZE", ERR_LIB_PROV, PROV_R_INVALID_THREAD_POOL_SIZE}, | |
| #else | |
| {"INVALID_THREAD_POOL_SIZE", 57, 234}, | |
| #endif | |
| #ifdef PROV_R_INVALID_UKM_LENGTH | |
| {"INVALID_UKM_LENGTH", ERR_LIB_PROV, PROV_R_INVALID_UKM_LENGTH}, | |
| #else | |
| {"INVALID_UKM_LENGTH", 57, 200}, | |
| #endif | |
| #ifdef PROV_R_INVALID_X931_DIGEST | |
| {"INVALID_X931_DIGEST", ERR_LIB_PROV, PROV_R_INVALID_X931_DIGEST}, | |
| #else | |
| {"INVALID_X931_DIGEST", 57, 170}, | |
| #endif | |
| #ifdef PROV_R_IN_ERROR_STATE | |
| {"IN_ERROR_STATE", ERR_LIB_PROV, PROV_R_IN_ERROR_STATE}, | |
| #else | |
| {"IN_ERROR_STATE", 57, 192}, | |
| #endif | |
| #ifdef PROV_R_KEY_SETUP_FAILED | |
| {"KEY_SETUP_FAILED", ERR_LIB_PROV, PROV_R_KEY_SETUP_FAILED}, | |
| #else | |
| {"KEY_SETUP_FAILED", 57, 101}, | |
| #endif | |
| #ifdef PROV_R_KEY_SIZE_TOO_SMALL | |
| {"KEY_SIZE_TOO_SMALL", ERR_LIB_PROV, PROV_R_KEY_SIZE_TOO_SMALL}, | |
| #else | |
| {"KEY_SIZE_TOO_SMALL", 57, 171}, | |
| #endif | |
| #ifdef PROV_R_LENGTH_TOO_LARGE | |
| {"LENGTH_TOO_LARGE", ERR_LIB_PROV, PROV_R_LENGTH_TOO_LARGE}, | |
| #else | |
| {"LENGTH_TOO_LARGE", 57, 202}, | |
| #endif | |
| #ifdef PROV_R_MISMATCHING_DOMAIN_PARAMETERS | |
| {"MISMATCHING_DOMAIN_PARAMETERS", ERR_LIB_PROV, PROV_R_MISMATCHING_DOMAIN_PARAMETERS}, | |
| #else | |
| {"MISMATCHING_DOMAIN_PARAMETERS", 57, 203}, | |
| #endif | |
| #ifdef PROV_R_MISSING_CEK_ALG | |
| {"MISSING_CEK_ALG", ERR_LIB_PROV, PROV_R_MISSING_CEK_ALG}, | |
| #else | |
| {"MISSING_CEK_ALG", 57, 144}, | |
| #endif | |
| #ifdef PROV_R_MISSING_CIPHER | |
| {"MISSING_CIPHER", ERR_LIB_PROV, PROV_R_MISSING_CIPHER}, | |
| #else | |
| {"MISSING_CIPHER", 57, 155}, | |
| #endif | |
| #ifdef PROV_R_MISSING_CONFIG_DATA | |
| {"MISSING_CONFIG_DATA", ERR_LIB_PROV, PROV_R_MISSING_CONFIG_DATA}, | |
| #else | |
| {"MISSING_CONFIG_DATA", 57, 213}, | |
| #endif | |
| #ifdef PROV_R_MISSING_CONSTANT | |
| {"MISSING_CONSTANT", ERR_LIB_PROV, PROV_R_MISSING_CONSTANT}, | |
| #else | |
| {"MISSING_CONSTANT", 57, 156}, | |
| #endif | |
| #ifdef PROV_R_MISSING_KEY | |
| {"MISSING_KEY", ERR_LIB_PROV, PROV_R_MISSING_KEY}, | |
| #else | |
| {"MISSING_KEY", 57, 128}, | |
| #endif | |
| #ifdef PROV_R_MISSING_MAC | |
| {"MISSING_MAC", ERR_LIB_PROV, PROV_R_MISSING_MAC}, | |
| #else | |
| {"MISSING_MAC", 57, 150}, | |
| #endif | |
| #ifdef PROV_R_MISSING_MESSAGE_DIGEST | |
| {"MISSING_MESSAGE_DIGEST", ERR_LIB_PROV, PROV_R_MISSING_MESSAGE_DIGEST}, | |
| #else | |
| {"MISSING_MESSAGE_DIGEST", 57, 129}, | |
| #endif | |
| #ifdef PROV_R_MISSING_OID | |
| {"MISSING_OID", ERR_LIB_PROV, PROV_R_MISSING_OID}, | |
| #else | |
| {"MISSING_OID", 57, 209}, | |
| #endif | |
| #ifdef PROV_R_MISSING_PASS | |
| {"MISSING_PASS", ERR_LIB_PROV, PROV_R_MISSING_PASS}, | |
| #else | |
| {"MISSING_PASS", 57, 130}, | |
| #endif | |
| #ifdef PROV_R_MISSING_SALT | |
| {"MISSING_SALT", ERR_LIB_PROV, PROV_R_MISSING_SALT}, | |
| #else | |
| {"MISSING_SALT", 57, 131}, | |
| #endif | |
| #ifdef PROV_R_MISSING_SECRET | |
| {"MISSING_SECRET", ERR_LIB_PROV, PROV_R_MISSING_SECRET}, | |
| #else | |
| {"MISSING_SECRET", 57, 132}, | |
| #endif | |
| #ifdef PROV_R_MISSING_SEED | |
| {"MISSING_SEED", ERR_LIB_PROV, PROV_R_MISSING_SEED}, | |
| #else | |
| {"MISSING_SEED", 57, 140}, | |
| #endif | |
| #ifdef PROV_R_MISSING_SESSION_ID | |
| {"MISSING_SESSION_ID", ERR_LIB_PROV, PROV_R_MISSING_SESSION_ID}, | |
| #else | |
| {"MISSING_SESSION_ID", 57, 133}, | |
| #endif | |
| #ifdef PROV_R_MISSING_TYPE | |
| {"MISSING_TYPE", ERR_LIB_PROV, PROV_R_MISSING_TYPE}, | |
| #else | |
| {"MISSING_TYPE", 57, 134}, | |
| #endif | |
| #ifdef PROV_R_MISSING_XCGHASH | |
| {"MISSING_XCGHASH", ERR_LIB_PROV, PROV_R_MISSING_XCGHASH}, | |
| #else | |
| {"MISSING_XCGHASH", 57, 135}, | |
| #endif | |
| #ifdef PROV_R_ML_DSA_NO_FORMAT | |
| {"ML_DSA_NO_FORMAT", ERR_LIB_PROV, PROV_R_ML_DSA_NO_FORMAT}, | |
| #else | |
| {"ML_DSA_NO_FORMAT", 57, 245}, | |
| #endif | |
| #ifdef PROV_R_ML_KEM_NO_FORMAT | |
| {"ML_KEM_NO_FORMAT", ERR_LIB_PROV, PROV_R_ML_KEM_NO_FORMAT}, | |
| #else | |
| {"ML_KEM_NO_FORMAT", 57, 246}, | |
| #endif | |
| #ifdef PROV_R_MODULE_INTEGRITY_FAILURE | |
| {"MODULE_INTEGRITY_FAILURE", ERR_LIB_PROV, PROV_R_MODULE_INTEGRITY_FAILURE}, | |
| #else | |
| {"MODULE_INTEGRITY_FAILURE", 57, 214}, | |
| #endif | |
| #ifdef PROV_R_NOT_A_PRIVATE_KEY | |
| {"NOT_A_PRIVATE_KEY", ERR_LIB_PROV, PROV_R_NOT_A_PRIVATE_KEY}, | |
| #else | |
| {"NOT_A_PRIVATE_KEY", 57, 221}, | |
| #endif | |
| #ifdef PROV_R_NOT_A_PUBLIC_KEY | |
| {"NOT_A_PUBLIC_KEY", ERR_LIB_PROV, PROV_R_NOT_A_PUBLIC_KEY}, | |
| #else | |
| {"NOT_A_PUBLIC_KEY", 57, 220}, | |
| #endif | |
| #ifdef PROV_R_NOT_INSTANTIATED | |
| {"NOT_INSTANTIATED", ERR_LIB_PROV, PROV_R_NOT_INSTANTIATED}, | |
| #else | |
| {"NOT_INSTANTIATED", 57, 193}, | |
| #endif | |
| #ifdef PROV_R_NOT_PARAMETERS | |
| {"NOT_PARAMETERS", ERR_LIB_PROV, PROV_R_NOT_PARAMETERS}, | |
| #else | |
| {"NOT_PARAMETERS", 57, 226}, | |
| #endif | |
| #ifdef PROV_R_NOT_SUPPORTED | |
| {"NOT_SUPPORTED", ERR_LIB_PROV, PROV_R_NOT_SUPPORTED}, | |
| #else | |
| {"NOT_SUPPORTED", 57, 136}, | |
| #endif | |
| #ifdef PROV_R_NOT_XOF_OR_INVALID_LENGTH | |
| {"NOT_XOF_OR_INVALID_LENGTH", ERR_LIB_PROV, PROV_R_NOT_XOF_OR_INVALID_LENGTH}, | |
| #else | |
| {"NOT_XOF_OR_INVALID_LENGTH", 57, 113}, | |
| #endif | |
| #ifdef PROV_R_NO_INSTANCE_ALLOWED | |
| {"NO_INSTANCE_ALLOWED", ERR_LIB_PROV, PROV_R_NO_INSTANCE_ALLOWED}, | |
| #else | |
| {"NO_INSTANCE_ALLOWED", 57, 242}, | |
| #endif | |
| #ifdef PROV_R_NO_KEY_SET | |
| {"NO_KEY_SET", ERR_LIB_PROV, PROV_R_NO_KEY_SET}, | |
| #else | |
| {"NO_KEY_SET", 57, 114}, | |
| #endif | |
| #ifdef PROV_R_NO_PARAMETERS_SET | |
| {"NO_PARAMETERS_SET", ERR_LIB_PROV, PROV_R_NO_PARAMETERS_SET}, | |
| #else | |
| {"NO_PARAMETERS_SET", 57, 177}, | |
| #endif | |
| #ifdef PROV_R_NULL_LENGTH_POINTER | |
| {"NULL_LENGTH_POINTER", ERR_LIB_PROV, PROV_R_NULL_LENGTH_POINTER}, | |
| #else | |
| {"NULL_LENGTH_POINTER", 57, 247}, | |
| #endif | |
| #ifdef PROV_R_NULL_OUTPUT_BUFFER | |
| {"NULL_OUTPUT_BUFFER", ERR_LIB_PROV, PROV_R_NULL_OUTPUT_BUFFER}, | |
| #else | |
| {"NULL_OUTPUT_BUFFER", 57, 248}, | |
| #endif | |
| #ifdef PROV_R_ONESHOT_CALL_OUT_OF_ORDER | |
| {"ONESHOT_CALL_OUT_OF_ORDER", ERR_LIB_PROV, PROV_R_ONESHOT_CALL_OUT_OF_ORDER}, | |
| #else | |
| {"ONESHOT_CALL_OUT_OF_ORDER", 57, 239}, | |
| #endif | |
| #ifdef PROV_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", ERR_LIB_PROV, PROV_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", 57, 178}, | |
| #endif | |
| #ifdef PROV_R_OUTPUT_BUFFER_TOO_SMALL | |
| {"OUTPUT_BUFFER_TOO_SMALL", ERR_LIB_PROV, PROV_R_OUTPUT_BUFFER_TOO_SMALL}, | |
| #else | |
| {"OUTPUT_BUFFER_TOO_SMALL", 57, 106}, | |
| #endif | |
| #ifdef PROV_R_PARENT_CANNOT_GENERATE_RANDOM_NUMBERS | |
| {"PARENT_CANNOT_GENERATE_RANDOM_NUMBERS", ERR_LIB_PROV, PROV_R_PARENT_CANNOT_GENERATE_RANDOM_NUMBERS}, | |
| #else | |
| {"PARENT_CANNOT_GENERATE_RANDOM_NUMBERS", 57, 228}, | |
| #endif | |
| #ifdef PROV_R_PARENT_CANNOT_SUPPLY_ENTROPY_SEED | |
| {"PARENT_CANNOT_SUPPLY_ENTROPY_SEED", ERR_LIB_PROV, PROV_R_PARENT_CANNOT_SUPPLY_ENTROPY_SEED}, | |
| #else | |
| {"PARENT_CANNOT_SUPPLY_ENTROPY_SEED", 57, 187}, | |
| #endif | |
| #ifdef PROV_R_PARENT_LOCKING_NOT_ENABLED | |
| {"PARENT_LOCKING_NOT_ENABLED", ERR_LIB_PROV, PROV_R_PARENT_LOCKING_NOT_ENABLED}, | |
| #else | |
| {"PARENT_LOCKING_NOT_ENABLED", 57, 182}, | |
| #endif | |
| #ifdef PROV_R_PARENT_STRENGTH_TOO_WEAK | |
| {"PARENT_STRENGTH_TOO_WEAK", ERR_LIB_PROV, PROV_R_PARENT_STRENGTH_TOO_WEAK}, | |
| #else | |
| {"PARENT_STRENGTH_TOO_WEAK", 57, 194}, | |
| #endif | |
| #ifdef PROV_R_PATH_MUST_BE_ABSOLUTE | |
| {"PATH_MUST_BE_ABSOLUTE", ERR_LIB_PROV, PROV_R_PATH_MUST_BE_ABSOLUTE}, | |
| #else | |
| {"PATH_MUST_BE_ABSOLUTE", 57, 219}, | |
| #endif | |
| #ifdef PROV_R_PERSONALISATION_STRING_TOO_LONG | |
| {"PERSONALISATION_STRING_TOO_LONG", ERR_LIB_PROV, PROV_R_PERSONALISATION_STRING_TOO_LONG}, | |
| #else | |
| {"PERSONALISATION_STRING_TOO_LONG", 57, 195}, | |
| #endif | |
| #ifdef PROV_R_PSS_SALTLEN_TOO_SMALL | |
| {"PSS_SALTLEN_TOO_SMALL", ERR_LIB_PROV, PROV_R_PSS_SALTLEN_TOO_SMALL}, | |
| #else | |
| {"PSS_SALTLEN_TOO_SMALL", 57, 172}, | |
| #endif | |
| #ifdef PROV_R_REPEATED_PARAMETER | |
| {"REPEATED_PARAMETER", ERR_LIB_PROV, PROV_R_REPEATED_PARAMETER}, | |
| #else | |
| {"REPEATED_PARAMETER", 57, 252}, | |
| #endif | |
| #ifdef PROV_R_REQUEST_TOO_LARGE_FOR_DRBG | |
| {"REQUEST_TOO_LARGE_FOR_DRBG", ERR_LIB_PROV, PROV_R_REQUEST_TOO_LARGE_FOR_DRBG}, | |
| #else | |
| {"REQUEST_TOO_LARGE_FOR_DRBG", 57, 196}, | |
| #endif | |
| #ifdef PROV_R_REQUIRE_CTR_MODE_CIPHER | |
| {"REQUIRE_CTR_MODE_CIPHER", ERR_LIB_PROV, PROV_R_REQUIRE_CTR_MODE_CIPHER}, | |
| #else | |
| {"REQUIRE_CTR_MODE_CIPHER", 57, 206}, | |
| #endif | |
| #ifdef PROV_R_RESEED_ERROR | |
| {"RESEED_ERROR", ERR_LIB_PROV, PROV_R_RESEED_ERROR}, | |
| #else | |
| {"RESEED_ERROR", 57, 197}, | |
| #endif | |
| #ifdef PROV_R_SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES | |
| {"SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES", ERR_LIB_PROV, PROV_R_SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES}, | |
| #else | |
| {"SEARCH_ONLY_SUPPORTED_FOR_DIRECTORIES", 57, 222}, | |
| #endif | |
| #ifdef PROV_R_SEED_SOURCES_MUST_NOT_HAVE_A_PARENT | |
| {"SEED_SOURCES_MUST_NOT_HAVE_A_PARENT", ERR_LIB_PROV, PROV_R_SEED_SOURCES_MUST_NOT_HAVE_A_PARENT}, | |
| #else | |
| {"SEED_SOURCES_MUST_NOT_HAVE_A_PARENT", 57, 229}, | |
| #endif | |
| #ifdef PROV_R_SELF_TEST_KAT_FAILURE | |
| {"SELF_TEST_KAT_FAILURE", ERR_LIB_PROV, PROV_R_SELF_TEST_KAT_FAILURE}, | |
| #else | |
| {"SELF_TEST_KAT_FAILURE", 57, 215}, | |
| #endif | |
| #ifdef PROV_R_SELF_TEST_POST_FAILURE | |
| {"SELF_TEST_POST_FAILURE", ERR_LIB_PROV, PROV_R_SELF_TEST_POST_FAILURE}, | |
| #else | |
| {"SELF_TEST_POST_FAILURE", 57, 216}, | |
| #endif | |
| #ifdef PROV_R_TAG_NOT_NEEDED | |
| {"TAG_NOT_NEEDED", ERR_LIB_PROV, PROV_R_TAG_NOT_NEEDED}, | |
| #else | |
| {"TAG_NOT_NEEDED", 57, 120}, | |
| #endif | |
| #ifdef PROV_R_TAG_NOT_SET | |
| {"TAG_NOT_SET", ERR_LIB_PROV, PROV_R_TAG_NOT_SET}, | |
| #else | |
| {"TAG_NOT_SET", 57, 119}, | |
| #endif | |
| #ifdef PROV_R_TOO_MANY_RECORDS | |
| {"TOO_MANY_RECORDS", ERR_LIB_PROV, PROV_R_TOO_MANY_RECORDS}, | |
| #else | |
| {"TOO_MANY_RECORDS", 57, 126}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_FIND_CIPHERS | |
| {"UNABLE_TO_FIND_CIPHERS", ERR_LIB_PROV, PROV_R_UNABLE_TO_FIND_CIPHERS}, | |
| #else | |
| {"UNABLE_TO_FIND_CIPHERS", 57, 207}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_GET_PARENT_STRENGTH | |
| {"UNABLE_TO_GET_PARENT_STRENGTH", ERR_LIB_PROV, PROV_R_UNABLE_TO_GET_PARENT_STRENGTH}, | |
| #else | |
| {"UNABLE_TO_GET_PARENT_STRENGTH", 57, 199}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_GET_PASSPHRASE | |
| {"UNABLE_TO_GET_PASSPHRASE", ERR_LIB_PROV, PROV_R_UNABLE_TO_GET_PASSPHRASE}, | |
| #else | |
| {"UNABLE_TO_GET_PASSPHRASE", 57, 159}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_INITIALISE_CIPHERS | |
| {"UNABLE_TO_INITIALISE_CIPHERS", ERR_LIB_PROV, PROV_R_UNABLE_TO_INITIALISE_CIPHERS}, | |
| #else | |
| {"UNABLE_TO_INITIALISE_CIPHERS", 57, 208}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_LOAD_SHA256 | |
| {"UNABLE_TO_LOAD_SHA256", ERR_LIB_PROV, PROV_R_UNABLE_TO_LOAD_SHA256}, | |
| #else | |
| {"UNABLE_TO_LOAD_SHA256", 57, 147}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_LOCK_PARENT | |
| {"UNABLE_TO_LOCK_PARENT", ERR_LIB_PROV, PROV_R_UNABLE_TO_LOCK_PARENT}, | |
| #else | |
| {"UNABLE_TO_LOCK_PARENT", 57, 201}, | |
| #endif | |
| #ifdef PROV_R_UNABLE_TO_RESEED | |
| {"UNABLE_TO_RESEED", ERR_LIB_PROV, PROV_R_UNABLE_TO_RESEED}, | |
| #else | |
| {"UNABLE_TO_RESEED", 57, 204}, | |
| #endif | |
| #ifdef PROV_R_UNEXPECTED_KEY_PARAMETERS | |
| {"UNEXPECTED_KEY_PARAMETERS", ERR_LIB_PROV, PROV_R_UNEXPECTED_KEY_PARAMETERS}, | |
| #else | |
| {"UNEXPECTED_KEY_PARAMETERS", 57, 249}, | |
| #endif | |
| #ifdef PROV_R_UNSUPPORTED_CEK_ALG | |
| {"UNSUPPORTED_CEK_ALG", ERR_LIB_PROV, PROV_R_UNSUPPORTED_CEK_ALG}, | |
| #else | |
| {"UNSUPPORTED_CEK_ALG", 57, 145}, | |
| #endif | |
| #ifdef PROV_R_UNSUPPORTED_KEY_SIZE | |
| {"UNSUPPORTED_KEY_SIZE", ERR_LIB_PROV, PROV_R_UNSUPPORTED_KEY_SIZE}, | |
| #else | |
| {"UNSUPPORTED_KEY_SIZE", 57, 153}, | |
| #endif | |
| #ifdef PROV_R_UNSUPPORTED_MAC_TYPE | |
| {"UNSUPPORTED_MAC_TYPE", ERR_LIB_PROV, PROV_R_UNSUPPORTED_MAC_TYPE}, | |
| #else | |
| {"UNSUPPORTED_MAC_TYPE", 57, 137}, | |
| #endif | |
| #ifdef PROV_R_UNSUPPORTED_NUMBER_OF_ROUNDS | |
| {"UNSUPPORTED_NUMBER_OF_ROUNDS", ERR_LIB_PROV, PROV_R_UNSUPPORTED_NUMBER_OF_ROUNDS}, | |
| #else | |
| {"UNSUPPORTED_NUMBER_OF_ROUNDS", 57, 152}, | |
| #endif | |
| #ifdef PROV_R_UNSUPPORTED_SELECTION | |
| {"UNSUPPORTED_SELECTION", ERR_LIB_PROV, PROV_R_UNSUPPORTED_SELECTION}, | |
| #else | |
| {"UNSUPPORTED_SELECTION", 57, 250}, | |
| #endif | |
| #ifdef PROV_R_UPDATE_CALL_OUT_OF_ORDER | |
| {"UPDATE_CALL_OUT_OF_ORDER", ERR_LIB_PROV, PROV_R_UPDATE_CALL_OUT_OF_ORDER}, | |
| #else | |
| {"UPDATE_CALL_OUT_OF_ORDER", 57, 240}, | |
| #endif | |
| #ifdef PROV_R_URI_AUTHORITY_UNSUPPORTED | |
| {"URI_AUTHORITY_UNSUPPORTED", ERR_LIB_PROV, PROV_R_URI_AUTHORITY_UNSUPPORTED}, | |
| #else | |
| {"URI_AUTHORITY_UNSUPPORTED", 57, 223}, | |
| #endif | |
| #ifdef PROV_R_VALUE_ERROR | |
| {"VALUE_ERROR", ERR_LIB_PROV, PROV_R_VALUE_ERROR}, | |
| #else | |
| {"VALUE_ERROR", 57, 138}, | |
| #endif | |
| #ifdef PROV_R_WRONG_CIPHERTEXT_SIZE | |
| {"WRONG_CIPHERTEXT_SIZE", ERR_LIB_PROV, PROV_R_WRONG_CIPHERTEXT_SIZE}, | |
| #else | |
| {"WRONG_CIPHERTEXT_SIZE", 57, 251}, | |
| #endif | |
| #ifdef PROV_R_WRONG_FINAL_BLOCK_LENGTH | |
| {"WRONG_FINAL_BLOCK_LENGTH", ERR_LIB_PROV, PROV_R_WRONG_FINAL_BLOCK_LENGTH}, | |
| #else | |
| {"WRONG_FINAL_BLOCK_LENGTH", 57, 107}, | |
| #endif | |
| #ifdef PROV_R_WRONG_OUTPUT_BUFFER_SIZE | |
| {"WRONG_OUTPUT_BUFFER_SIZE", ERR_LIB_PROV, PROV_R_WRONG_OUTPUT_BUFFER_SIZE}, | |
| #else | |
| {"WRONG_OUTPUT_BUFFER_SIZE", 57, 139}, | |
| #endif | |
| #ifdef PROV_R_XOF_DIGESTS_NOT_ALLOWED | |
| {"XOF_DIGESTS_NOT_ALLOWED", ERR_LIB_PROV, PROV_R_XOF_DIGESTS_NOT_ALLOWED}, | |
| #else | |
| {"XOF_DIGESTS_NOT_ALLOWED", 57, 183}, | |
| #endif | |
| #ifdef PROV_R_XTS_DATA_UNIT_IS_TOO_LARGE | |
| {"XTS_DATA_UNIT_IS_TOO_LARGE", ERR_LIB_PROV, PROV_R_XTS_DATA_UNIT_IS_TOO_LARGE}, | |
| #else | |
| {"XTS_DATA_UNIT_IS_TOO_LARGE", 57, 148}, | |
| #endif | |
| #ifdef PROV_R_XTS_DUPLICATED_KEYS | |
| {"XTS_DUPLICATED_KEYS", ERR_LIB_PROV, PROV_R_XTS_DUPLICATED_KEYS}, | |
| #else | |
| {"XTS_DUPLICATED_KEYS", 57, 149}, | |
| #endif | |
| #ifdef RAND_R_ADDITIONAL_INPUT_TOO_LONG | |
| {"ADDITIONAL_INPUT_TOO_LONG", ERR_LIB_RAND, RAND_R_ADDITIONAL_INPUT_TOO_LONG}, | |
| #else | |
| {"ADDITIONAL_INPUT_TOO_LONG", 36, 102}, | |
| #endif | |
| #ifdef RAND_R_ALREADY_INSTANTIATED | |
| {"ALREADY_INSTANTIATED", ERR_LIB_RAND, RAND_R_ALREADY_INSTANTIATED}, | |
| #else | |
| {"ALREADY_INSTANTIATED", 36, 103}, | |
| #endif | |
| #ifdef RAND_R_ARGUMENT_OUT_OF_RANGE | |
| {"ARGUMENT_OUT_OF_RANGE", ERR_LIB_RAND, RAND_R_ARGUMENT_OUT_OF_RANGE}, | |
| #else | |
| {"ARGUMENT_OUT_OF_RANGE", 36, 105}, | |
| #endif | |
| #ifdef RAND_R_CANNOT_OPEN_FILE | |
| {"CANNOT_OPEN_FILE", ERR_LIB_RAND, RAND_R_CANNOT_OPEN_FILE}, | |
| #else | |
| {"CANNOT_OPEN_FILE", 36, 121}, | |
| #endif | |
| #ifdef RAND_R_DRBG_ALREADY_INITIALIZED | |
| {"DRBG_ALREADY_INITIALIZED", ERR_LIB_RAND, RAND_R_DRBG_ALREADY_INITIALIZED}, | |
| #else | |
| {"DRBG_ALREADY_INITIALIZED", 36, 129}, | |
| #endif | |
| #ifdef RAND_R_DRBG_NOT_INITIALISED | |
| {"DRBG_NOT_INITIALISED", ERR_LIB_RAND, RAND_R_DRBG_NOT_INITIALISED}, | |
| #else | |
| {"DRBG_NOT_INITIALISED", 36, 104}, | |
| #endif | |
| #ifdef RAND_R_ENTROPY_INPUT_TOO_LONG | |
| {"ENTROPY_INPUT_TOO_LONG", ERR_LIB_RAND, RAND_R_ENTROPY_INPUT_TOO_LONG}, | |
| #else | |
| {"ENTROPY_INPUT_TOO_LONG", 36, 106}, | |
| #endif | |
| #ifdef RAND_R_ENTROPY_OUT_OF_RANGE | |
| {"ENTROPY_OUT_OF_RANGE", ERR_LIB_RAND, RAND_R_ENTROPY_OUT_OF_RANGE}, | |
| #else | |
| {"ENTROPY_OUT_OF_RANGE", 36, 124}, | |
| #endif | |
| #ifdef RAND_R_ERROR_ENTROPY_POOL_WAS_IGNORED | |
| {"ERROR_ENTROPY_POOL_WAS_IGNORED", ERR_LIB_RAND, RAND_R_ERROR_ENTROPY_POOL_WAS_IGNORED}, | |
| #else | |
| {"ERROR_ENTROPY_POOL_WAS_IGNORED", 36, 127}, | |
| #endif | |
| #ifdef RAND_R_ERROR_INITIALISING_DRBG | |
| {"ERROR_INITIALISING_DRBG", ERR_LIB_RAND, RAND_R_ERROR_INITIALISING_DRBG}, | |
| #else | |
| {"ERROR_INITIALISING_DRBG", 36, 107}, | |
| #endif | |
| #ifdef RAND_R_ERROR_INSTANTIATING_DRBG | |
| {"ERROR_INSTANTIATING_DRBG", ERR_LIB_RAND, RAND_R_ERROR_INSTANTIATING_DRBG}, | |
| #else | |
| {"ERROR_INSTANTIATING_DRBG", 36, 108}, | |
| #endif | |
| #ifdef RAND_R_ERROR_RETRIEVING_ADDITIONAL_INPUT | |
| {"ERROR_RETRIEVING_ADDITIONAL_INPUT", ERR_LIB_RAND, RAND_R_ERROR_RETRIEVING_ADDITIONAL_INPUT}, | |
| #else | |
| {"ERROR_RETRIEVING_ADDITIONAL_INPUT", 36, 109}, | |
| #endif | |
| #ifdef RAND_R_ERROR_RETRIEVING_ENTROPY | |
| {"ERROR_RETRIEVING_ENTROPY", ERR_LIB_RAND, RAND_R_ERROR_RETRIEVING_ENTROPY}, | |
| #else | |
| {"ERROR_RETRIEVING_ENTROPY", 36, 110}, | |
| #endif | |
| #ifdef RAND_R_ERROR_RETRIEVING_NONCE | |
| {"ERROR_RETRIEVING_NONCE", ERR_LIB_RAND, RAND_R_ERROR_RETRIEVING_NONCE}, | |
| #else | |
| {"ERROR_RETRIEVING_NONCE", 36, 111}, | |
| #endif | |
| #ifdef RAND_R_FAILED_TO_CREATE_LOCK | |
| {"FAILED_TO_CREATE_LOCK", ERR_LIB_RAND, RAND_R_FAILED_TO_CREATE_LOCK}, | |
| #else | |
| {"FAILED_TO_CREATE_LOCK", 36, 126}, | |
| #endif | |
| #ifdef RAND_R_FUNC_NOT_IMPLEMENTED | |
| {"FUNC_NOT_IMPLEMENTED", ERR_LIB_RAND, RAND_R_FUNC_NOT_IMPLEMENTED}, | |
| #else | |
| {"FUNC_NOT_IMPLEMENTED", 36, 101}, | |
| #endif | |
| #ifdef RAND_R_FWRITE_ERROR | |
| {"FWRITE_ERROR", ERR_LIB_RAND, RAND_R_FWRITE_ERROR}, | |
| #else | |
| {"FWRITE_ERROR", 36, 123}, | |
| #endif | |
| #ifdef RAND_R_GENERATE_ERROR | |
| {"GENERATE_ERROR", ERR_LIB_RAND, RAND_R_GENERATE_ERROR}, | |
| #else | |
| {"GENERATE_ERROR", 36, 112}, | |
| #endif | |
| #ifdef RAND_R_INSUFFICIENT_DRBG_STRENGTH | |
| {"INSUFFICIENT_DRBG_STRENGTH", ERR_LIB_RAND, RAND_R_INSUFFICIENT_DRBG_STRENGTH}, | |
| #else | |
| {"INSUFFICIENT_DRBG_STRENGTH", 36, 139}, | |
| #endif | |
| #ifdef RAND_R_INTERNAL_ERROR | |
| {"INTERNAL_ERROR", ERR_LIB_RAND, RAND_R_INTERNAL_ERROR}, | |
| #else | |
| {"INTERNAL_ERROR", 36, 113}, | |
| #endif | |
| #ifdef RAND_R_INVALID_PROPERTY_QUERY | |
| {"INVALID_PROPERTY_QUERY", ERR_LIB_RAND, RAND_R_INVALID_PROPERTY_QUERY}, | |
| #else | |
| {"INVALID_PROPERTY_QUERY", 36, 137}, | |
| #endif | |
| #ifdef RAND_R_IN_ERROR_STATE | |
| {"IN_ERROR_STATE", ERR_LIB_RAND, RAND_R_IN_ERROR_STATE}, | |
| #else | |
| {"IN_ERROR_STATE", 36, 114}, | |
| #endif | |
| #ifdef RAND_R_NOT_A_REGULAR_FILE | |
| {"NOT_A_REGULAR_FILE", ERR_LIB_RAND, RAND_R_NOT_A_REGULAR_FILE}, | |
| #else | |
| {"NOT_A_REGULAR_FILE", 36, 122}, | |
| #endif | |
| #ifdef RAND_R_NOT_INSTANTIATED | |
| {"NOT_INSTANTIATED", ERR_LIB_RAND, RAND_R_NOT_INSTANTIATED}, | |
| #else | |
| {"NOT_INSTANTIATED", 36, 115}, | |
| #endif | |
| #ifdef RAND_R_NO_DRBG_IMPLEMENTATION_SELECTED | |
| {"NO_DRBG_IMPLEMENTATION_SELECTED", ERR_LIB_RAND, RAND_R_NO_DRBG_IMPLEMENTATION_SELECTED}, | |
| #else | |
| {"NO_DRBG_IMPLEMENTATION_SELECTED", 36, 128}, | |
| #endif | |
| #ifdef RAND_R_PARENT_LOCKING_NOT_ENABLED | |
| {"PARENT_LOCKING_NOT_ENABLED", ERR_LIB_RAND, RAND_R_PARENT_LOCKING_NOT_ENABLED}, | |
| #else | |
| {"PARENT_LOCKING_NOT_ENABLED", 36, 130}, | |
| #endif | |
| #ifdef RAND_R_PARENT_STRENGTH_TOO_WEAK | |
| {"PARENT_STRENGTH_TOO_WEAK", ERR_LIB_RAND, RAND_R_PARENT_STRENGTH_TOO_WEAK}, | |
| #else | |
| {"PARENT_STRENGTH_TOO_WEAK", 36, 131}, | |
| #endif | |
| #ifdef RAND_R_PERSONALISATION_STRING_TOO_LONG | |
| {"PERSONALISATION_STRING_TOO_LONG", ERR_LIB_RAND, RAND_R_PERSONALISATION_STRING_TOO_LONG}, | |
| #else | |
| {"PERSONALISATION_STRING_TOO_LONG", 36, 116}, | |
| #endif | |
| #ifdef RAND_R_PREDICTION_RESISTANCE_NOT_SUPPORTED | |
| {"PREDICTION_RESISTANCE_NOT_SUPPORTED", ERR_LIB_RAND, RAND_R_PREDICTION_RESISTANCE_NOT_SUPPORTED}, | |
| #else | |
| {"PREDICTION_RESISTANCE_NOT_SUPPORTED", 36, 133}, | |
| #endif | |
| #ifdef RAND_R_PRNG_NOT_SEEDED | |
| {"PRNG_NOT_SEEDED", ERR_LIB_RAND, RAND_R_PRNG_NOT_SEEDED}, | |
| #else | |
| {"PRNG_NOT_SEEDED", 36, 100}, | |
| #endif | |
| #ifdef RAND_R_RANDOM_POOL_IS_EMPTY | |
| {"RANDOM_POOL_IS_EMPTY", ERR_LIB_RAND, RAND_R_RANDOM_POOL_IS_EMPTY}, | |
| #else | |
| {"RANDOM_POOL_IS_EMPTY", 36, 142}, | |
| #endif | |
| #ifdef RAND_R_RANDOM_POOL_OVERFLOW | |
| {"RANDOM_POOL_OVERFLOW", ERR_LIB_RAND, RAND_R_RANDOM_POOL_OVERFLOW}, | |
| #else | |
| {"RANDOM_POOL_OVERFLOW", 36, 125}, | |
| #endif | |
| #ifdef RAND_R_RANDOM_POOL_UNDERFLOW | |
| {"RANDOM_POOL_UNDERFLOW", ERR_LIB_RAND, RAND_R_RANDOM_POOL_UNDERFLOW}, | |
| #else | |
| {"RANDOM_POOL_UNDERFLOW", 36, 134}, | |
| #endif | |
| #ifdef RAND_R_REQUEST_TOO_LARGE_FOR_DRBG | |
| {"REQUEST_TOO_LARGE_FOR_DRBG", ERR_LIB_RAND, RAND_R_REQUEST_TOO_LARGE_FOR_DRBG}, | |
| #else | |
| {"REQUEST_TOO_LARGE_FOR_DRBG", 36, 117}, | |
| #endif | |
| #ifdef RAND_R_RESEED_ERROR | |
| {"RESEED_ERROR", ERR_LIB_RAND, RAND_R_RESEED_ERROR}, | |
| #else | |
| {"RESEED_ERROR", 36, 118}, | |
| #endif | |
| #ifdef RAND_R_SELFTEST_FAILURE | |
| {"SELFTEST_FAILURE", ERR_LIB_RAND, RAND_R_SELFTEST_FAILURE}, | |
| #else | |
| {"SELFTEST_FAILURE", 36, 119}, | |
| #endif | |
| #ifdef RAND_R_TOO_LITTLE_NONCE_REQUESTED | |
| {"TOO_LITTLE_NONCE_REQUESTED", ERR_LIB_RAND, RAND_R_TOO_LITTLE_NONCE_REQUESTED}, | |
| #else | |
| {"TOO_LITTLE_NONCE_REQUESTED", 36, 135}, | |
| #endif | |
| #ifdef RAND_R_TOO_MUCH_NONCE_REQUESTED | |
| {"TOO_MUCH_NONCE_REQUESTED", ERR_LIB_RAND, RAND_R_TOO_MUCH_NONCE_REQUESTED}, | |
| #else | |
| {"TOO_MUCH_NONCE_REQUESTED", 36, 136}, | |
| #endif | |
| #ifdef RAND_R_UNABLE_TO_CREATE_DRBG | |
| {"UNABLE_TO_CREATE_DRBG", ERR_LIB_RAND, RAND_R_UNABLE_TO_CREATE_DRBG}, | |
| #else | |
| {"UNABLE_TO_CREATE_DRBG", 36, 143}, | |
| #endif | |
| #ifdef RAND_R_UNABLE_TO_FETCH_DRBG | |
| {"UNABLE_TO_FETCH_DRBG", ERR_LIB_RAND, RAND_R_UNABLE_TO_FETCH_DRBG}, | |
| #else | |
| {"UNABLE_TO_FETCH_DRBG", 36, 144}, | |
| #endif | |
| #ifdef RAND_R_UNABLE_TO_GET_PARENT_RESEED_PROP_COUNTER | |
| {"UNABLE_TO_GET_PARENT_RESEED_PROP_COUNTER", ERR_LIB_RAND, RAND_R_UNABLE_TO_GET_PARENT_RESEED_PROP_COUNTER}, | |
| #else | |
| {"UNABLE_TO_GET_PARENT_RESEED_PROP_COUNTER", 36, 141}, | |
| #endif | |
| #ifdef RAND_R_UNABLE_TO_GET_PARENT_STRENGTH | |
| {"UNABLE_TO_GET_PARENT_STRENGTH", ERR_LIB_RAND, RAND_R_UNABLE_TO_GET_PARENT_STRENGTH}, | |
| #else | |
| {"UNABLE_TO_GET_PARENT_STRENGTH", 36, 138}, | |
| #endif | |
| #ifdef RAND_R_UNABLE_TO_LOCK_PARENT | |
| {"UNABLE_TO_LOCK_PARENT", ERR_LIB_RAND, RAND_R_UNABLE_TO_LOCK_PARENT}, | |
| #else | |
| {"UNABLE_TO_LOCK_PARENT", 36, 140}, | |
| #endif | |
| #ifdef RAND_R_UNSUPPORTED_DRBG_FLAGS | |
| {"UNSUPPORTED_DRBG_FLAGS", ERR_LIB_RAND, RAND_R_UNSUPPORTED_DRBG_FLAGS}, | |
| #else | |
| {"UNSUPPORTED_DRBG_FLAGS", 36, 132}, | |
| #endif | |
| #ifdef RAND_R_UNSUPPORTED_DRBG_TYPE | |
| {"UNSUPPORTED_DRBG_TYPE", ERR_LIB_RAND, RAND_R_UNSUPPORTED_DRBG_TYPE}, | |
| #else | |
| {"UNSUPPORTED_DRBG_TYPE", 36, 120}, | |
| #endif | |
| #ifdef RSA_R_ALGORITHM_MISMATCH | |
| {"ALGORITHM_MISMATCH", ERR_LIB_RSA, RSA_R_ALGORITHM_MISMATCH}, | |
| #else | |
| {"ALGORITHM_MISMATCH", 4, 100}, | |
| #endif | |
| #ifdef RSA_R_BAD_E_VALUE | |
| {"BAD_E_VALUE", ERR_LIB_RSA, RSA_R_BAD_E_VALUE}, | |
| #else | |
| {"BAD_E_VALUE", 4, 101}, | |
| #endif | |
| #ifdef RSA_R_BAD_FIXED_HEADER_DECRYPT | |
| {"BAD_FIXED_HEADER_DECRYPT", ERR_LIB_RSA, RSA_R_BAD_FIXED_HEADER_DECRYPT}, | |
| #else | |
| {"BAD_FIXED_HEADER_DECRYPT", 4, 102}, | |
| #endif | |
| #ifdef RSA_R_BAD_PAD_BYTE_COUNT | |
| {"BAD_PAD_BYTE_COUNT", ERR_LIB_RSA, RSA_R_BAD_PAD_BYTE_COUNT}, | |
| #else | |
| {"BAD_PAD_BYTE_COUNT", 4, 103}, | |
| #endif | |
| #ifdef RSA_R_BAD_SIGNATURE | |
| {"BAD_SIGNATURE", ERR_LIB_RSA, RSA_R_BAD_SIGNATURE}, | |
| #else | |
| {"BAD_SIGNATURE", 4, 104}, | |
| #endif | |
| #ifdef RSA_R_BLOCK_TYPE_IS_NOT_01 | |
| {"BLOCK_TYPE_IS_NOT_01", ERR_LIB_RSA, RSA_R_BLOCK_TYPE_IS_NOT_01}, | |
| #else | |
| {"BLOCK_TYPE_IS_NOT_01", 4, 106}, | |
| #endif | |
| #ifdef RSA_R_BLOCK_TYPE_IS_NOT_02 | |
| {"BLOCK_TYPE_IS_NOT_02", ERR_LIB_RSA, RSA_R_BLOCK_TYPE_IS_NOT_02}, | |
| #else | |
| {"BLOCK_TYPE_IS_NOT_02", 4, 107}, | |
| #endif | |
| #ifdef RSA_R_DATA_GREATER_THAN_MOD_LEN | |
| {"DATA_GREATER_THAN_MOD_LEN", ERR_LIB_RSA, RSA_R_DATA_GREATER_THAN_MOD_LEN}, | |
| #else | |
| {"DATA_GREATER_THAN_MOD_LEN", 4, 108}, | |
| #endif | |
| #ifdef RSA_R_DATA_TOO_LARGE | |
| {"DATA_TOO_LARGE", ERR_LIB_RSA, RSA_R_DATA_TOO_LARGE}, | |
| #else | |
| {"DATA_TOO_LARGE", 4, 109}, | |
| #endif | |
| #ifdef RSA_R_DATA_TOO_LARGE_FOR_KEY_SIZE | |
| {"DATA_TOO_LARGE_FOR_KEY_SIZE", ERR_LIB_RSA, RSA_R_DATA_TOO_LARGE_FOR_KEY_SIZE}, | |
| #else | |
| {"DATA_TOO_LARGE_FOR_KEY_SIZE", 4, 110}, | |
| #endif | |
| #ifdef RSA_R_DATA_TOO_LARGE_FOR_MODULUS | |
| {"DATA_TOO_LARGE_FOR_MODULUS", ERR_LIB_RSA, RSA_R_DATA_TOO_LARGE_FOR_MODULUS}, | |
| #else | |
| {"DATA_TOO_LARGE_FOR_MODULUS", 4, 132}, | |
| #endif | |
| #ifdef RSA_R_DATA_TOO_SMALL | |
| {"DATA_TOO_SMALL", ERR_LIB_RSA, RSA_R_DATA_TOO_SMALL}, | |
| #else | |
| {"DATA_TOO_SMALL", 4, 111}, | |
| #endif | |
| #ifdef RSA_R_DATA_TOO_SMALL_FOR_KEY_SIZE | |
| {"DATA_TOO_SMALL_FOR_KEY_SIZE", ERR_LIB_RSA, RSA_R_DATA_TOO_SMALL_FOR_KEY_SIZE}, | |
| #else | |
| {"DATA_TOO_SMALL_FOR_KEY_SIZE", 4, 122}, | |
| #endif | |
| #ifdef RSA_R_DIGEST_DOES_NOT_MATCH | |
| {"DIGEST_DOES_NOT_MATCH", ERR_LIB_RSA, RSA_R_DIGEST_DOES_NOT_MATCH}, | |
| #else | |
| {"DIGEST_DOES_NOT_MATCH", 4, 158}, | |
| #endif | |
| #ifdef RSA_R_DIGEST_NOT_ALLOWED | |
| {"DIGEST_NOT_ALLOWED", ERR_LIB_RSA, RSA_R_DIGEST_NOT_ALLOWED}, | |
| #else | |
| {"DIGEST_NOT_ALLOWED", 4, 145}, | |
| #endif | |
| #ifdef RSA_R_DIGEST_TOO_BIG_FOR_RSA_KEY | |
| {"DIGEST_TOO_BIG_FOR_RSA_KEY", ERR_LIB_RSA, RSA_R_DIGEST_TOO_BIG_FOR_RSA_KEY}, | |
| #else | |
| {"DIGEST_TOO_BIG_FOR_RSA_KEY", 4, 112}, | |
| #endif | |
| #ifdef RSA_R_DMP1_NOT_CONGRUENT_TO_D | |
| {"DMP1_NOT_CONGRUENT_TO_D", ERR_LIB_RSA, RSA_R_DMP1_NOT_CONGRUENT_TO_D}, | |
| #else | |
| {"DMP1_NOT_CONGRUENT_TO_D", 4, 124}, | |
| #endif | |
| #ifdef RSA_R_DMQ1_NOT_CONGRUENT_TO_D | |
| {"DMQ1_NOT_CONGRUENT_TO_D", ERR_LIB_RSA, RSA_R_DMQ1_NOT_CONGRUENT_TO_D}, | |
| #else | |
| {"DMQ1_NOT_CONGRUENT_TO_D", 4, 125}, | |
| #endif | |
| #ifdef RSA_R_D_E_NOT_CONGRUENT_TO_1 | |
| {"D_E_NOT_CONGRUENT_TO_1", ERR_LIB_RSA, RSA_R_D_E_NOT_CONGRUENT_TO_1}, | |
| #else | |
| {"D_E_NOT_CONGRUENT_TO_1", 4, 123}, | |
| #endif | |
| #ifdef RSA_R_FIRST_OCTET_INVALID | |
| {"FIRST_OCTET_INVALID", ERR_LIB_RSA, RSA_R_FIRST_OCTET_INVALID}, | |
| #else | |
| {"FIRST_OCTET_INVALID", 4, 133}, | |
| #endif | |
| #ifdef RSA_R_ILLEGAL_OR_UNSUPPORTED_PADDING_MODE | |
| {"ILLEGAL_OR_UNSUPPORTED_PADDING_MODE", ERR_LIB_RSA, RSA_R_ILLEGAL_OR_UNSUPPORTED_PADDING_MODE}, | |
| #else | |
| {"ILLEGAL_OR_UNSUPPORTED_PADDING_MODE", 4, 144}, | |
| #endif | |
| #ifdef RSA_R_INVALID_DIGEST | |
| {"INVALID_DIGEST", ERR_LIB_RSA, RSA_R_INVALID_DIGEST}, | |
| #else | |
| {"INVALID_DIGEST", 4, 157}, | |
| #endif | |
| #ifdef RSA_R_INVALID_DIGEST_LENGTH | |
| {"INVALID_DIGEST_LENGTH", ERR_LIB_RSA, RSA_R_INVALID_DIGEST_LENGTH}, | |
| #else | |
| {"INVALID_DIGEST_LENGTH", 4, 143}, | |
| #endif | |
| #ifdef RSA_R_INVALID_HEADER | |
| {"INVALID_HEADER", ERR_LIB_RSA, RSA_R_INVALID_HEADER}, | |
| #else | |
| {"INVALID_HEADER", 4, 137}, | |
| #endif | |
| #ifdef RSA_R_INVALID_KEYPAIR | |
| {"INVALID_KEYPAIR", ERR_LIB_RSA, RSA_R_INVALID_KEYPAIR}, | |
| #else | |
| {"INVALID_KEYPAIR", 4, 171}, | |
| #endif | |
| #ifdef RSA_R_INVALID_KEY_LENGTH | |
| {"INVALID_KEY_LENGTH", ERR_LIB_RSA, RSA_R_INVALID_KEY_LENGTH}, | |
| #else | |
| {"INVALID_KEY_LENGTH", 4, 173}, | |
| #endif | |
| #ifdef RSA_R_INVALID_LABEL | |
| {"INVALID_LABEL", ERR_LIB_RSA, RSA_R_INVALID_LABEL}, | |
| #else | |
| {"INVALID_LABEL", 4, 160}, | |
| #endif | |
| #ifdef RSA_R_INVALID_LENGTH | |
| {"INVALID_LENGTH", ERR_LIB_RSA, RSA_R_INVALID_LENGTH}, | |
| #else | |
| {"INVALID_LENGTH", 4, 181}, | |
| #endif | |
| #ifdef RSA_R_INVALID_MESSAGE_LENGTH | |
| {"INVALID_MESSAGE_LENGTH", ERR_LIB_RSA, RSA_R_INVALID_MESSAGE_LENGTH}, | |
| #else | |
| {"INVALID_MESSAGE_LENGTH", 4, 131}, | |
| #endif | |
| #ifdef RSA_R_INVALID_MGF1_MD | |
| {"INVALID_MGF1_MD", ERR_LIB_RSA, RSA_R_INVALID_MGF1_MD}, | |
| #else | |
| {"INVALID_MGF1_MD", 4, 156}, | |
| #endif | |
| #ifdef RSA_R_INVALID_MODULUS | |
| {"INVALID_MODULUS", ERR_LIB_RSA, RSA_R_INVALID_MODULUS}, | |
| #else | |
| {"INVALID_MODULUS", 4, 174}, | |
| #endif | |
| #ifdef RSA_R_INVALID_MULTI_PRIME_KEY | |
| {"INVALID_MULTI_PRIME_KEY", ERR_LIB_RSA, RSA_R_INVALID_MULTI_PRIME_KEY}, | |
| #else | |
| {"INVALID_MULTI_PRIME_KEY", 4, 167}, | |
| #endif | |
| #ifdef RSA_R_INVALID_OAEP_PARAMETERS | |
| {"INVALID_OAEP_PARAMETERS", ERR_LIB_RSA, RSA_R_INVALID_OAEP_PARAMETERS}, | |
| #else | |
| {"INVALID_OAEP_PARAMETERS", 4, 161}, | |
| #endif | |
| #ifdef RSA_R_INVALID_PADDING | |
| {"INVALID_PADDING", ERR_LIB_RSA, RSA_R_INVALID_PADDING}, | |
| #else | |
| {"INVALID_PADDING", 4, 138}, | |
| #endif | |
| #ifdef RSA_R_INVALID_PADDING_MODE | |
| {"INVALID_PADDING_MODE", ERR_LIB_RSA, RSA_R_INVALID_PADDING_MODE}, | |
| #else | |
| {"INVALID_PADDING_MODE", 4, 141}, | |
| #endif | |
| #ifdef RSA_R_INVALID_PSS_PARAMETERS | |
| {"INVALID_PSS_PARAMETERS", ERR_LIB_RSA, RSA_R_INVALID_PSS_PARAMETERS}, | |
| #else | |
| {"INVALID_PSS_PARAMETERS", 4, 149}, | |
| #endif | |
| #ifdef RSA_R_INVALID_PSS_SALTLEN | |
| {"INVALID_PSS_SALTLEN", ERR_LIB_RSA, RSA_R_INVALID_PSS_SALTLEN}, | |
| #else | |
| {"INVALID_PSS_SALTLEN", 4, 146}, | |
| #endif | |
| #ifdef RSA_R_INVALID_REQUEST | |
| {"INVALID_REQUEST", ERR_LIB_RSA, RSA_R_INVALID_REQUEST}, | |
| #else | |
| {"INVALID_REQUEST", 4, 175}, | |
| #endif | |
| #ifdef RSA_R_INVALID_SALT_LENGTH | |
| {"INVALID_SALT_LENGTH", ERR_LIB_RSA, RSA_R_INVALID_SALT_LENGTH}, | |
| #else | |
| {"INVALID_SALT_LENGTH", 4, 150}, | |
| #endif | |
| #ifdef RSA_R_INVALID_STRENGTH | |
| {"INVALID_STRENGTH", ERR_LIB_RSA, RSA_R_INVALID_STRENGTH}, | |
| #else | |
| {"INVALID_STRENGTH", 4, 176}, | |
| #endif | |
| #ifdef RSA_R_INVALID_TRAILER | |
| {"INVALID_TRAILER", ERR_LIB_RSA, RSA_R_INVALID_TRAILER}, | |
| #else | |
| {"INVALID_TRAILER", 4, 139}, | |
| #endif | |
| #ifdef RSA_R_INVALID_X931_DIGEST | |
| {"INVALID_X931_DIGEST", ERR_LIB_RSA, RSA_R_INVALID_X931_DIGEST}, | |
| #else | |
| {"INVALID_X931_DIGEST", 4, 142}, | |
| #endif | |
| #ifdef RSA_R_IQMP_NOT_INVERSE_OF_Q | |
| {"IQMP_NOT_INVERSE_OF_Q", ERR_LIB_RSA, RSA_R_IQMP_NOT_INVERSE_OF_Q}, | |
| #else | |
| {"IQMP_NOT_INVERSE_OF_Q", 4, 126}, | |
| #endif | |
| #ifdef RSA_R_KEY_PRIME_NUM_INVALID | |
| {"KEY_PRIME_NUM_INVALID", ERR_LIB_RSA, RSA_R_KEY_PRIME_NUM_INVALID}, | |
| #else | |
| {"KEY_PRIME_NUM_INVALID", 4, 165}, | |
| #endif | |
| #ifdef RSA_R_KEY_SIZE_TOO_SMALL | |
| {"KEY_SIZE_TOO_SMALL", ERR_LIB_RSA, RSA_R_KEY_SIZE_TOO_SMALL}, | |
| #else | |
| {"KEY_SIZE_TOO_SMALL", 4, 120}, | |
| #endif | |
| #ifdef RSA_R_LAST_OCTET_INVALID | |
| {"LAST_OCTET_INVALID", ERR_LIB_RSA, RSA_R_LAST_OCTET_INVALID}, | |
| #else | |
| {"LAST_OCTET_INVALID", 4, 134}, | |
| #endif | |
| #ifdef RSA_R_MGF1_DIGEST_NOT_ALLOWED | |
| {"MGF1_DIGEST_NOT_ALLOWED", ERR_LIB_RSA, RSA_R_MGF1_DIGEST_NOT_ALLOWED}, | |
| #else | |
| {"MGF1_DIGEST_NOT_ALLOWED", 4, 152}, | |
| #endif | |
| #ifdef RSA_R_MISSING_PRIVATE_KEY | |
| {"MISSING_PRIVATE_KEY", ERR_LIB_RSA, RSA_R_MISSING_PRIVATE_KEY}, | |
| #else | |
| {"MISSING_PRIVATE_KEY", 4, 179}, | |
| #endif | |
| #ifdef RSA_R_MODULUS_TOO_LARGE | |
| {"MODULUS_TOO_LARGE", ERR_LIB_RSA, RSA_R_MODULUS_TOO_LARGE}, | |
| #else | |
| {"MODULUS_TOO_LARGE", 4, 105}, | |
| #endif | |
| #ifdef RSA_R_MP_COEFFICIENT_NOT_INVERSE_OF_R | |
| {"MP_COEFFICIENT_NOT_INVERSE_OF_R", ERR_LIB_RSA, RSA_R_MP_COEFFICIENT_NOT_INVERSE_OF_R}, | |
| #else | |
| {"MP_COEFFICIENT_NOT_INVERSE_OF_R", 4, 168}, | |
| #endif | |
| #ifdef RSA_R_MP_EXPONENT_NOT_CONGRUENT_TO_D | |
| {"MP_EXPONENT_NOT_CONGRUENT_TO_D", ERR_LIB_RSA, RSA_R_MP_EXPONENT_NOT_CONGRUENT_TO_D}, | |
| #else | |
| {"MP_EXPONENT_NOT_CONGRUENT_TO_D", 4, 169}, | |
| #endif | |
| #ifdef RSA_R_MP_R_NOT_PRIME | |
| {"MP_R_NOT_PRIME", ERR_LIB_RSA, RSA_R_MP_R_NOT_PRIME}, | |
| #else | |
| {"MP_R_NOT_PRIME", 4, 170}, | |
| #endif | |
| #ifdef RSA_R_NO_PUBLIC_EXPONENT | |
| {"NO_PUBLIC_EXPONENT", ERR_LIB_RSA, RSA_R_NO_PUBLIC_EXPONENT}, | |
| #else | |
| {"NO_PUBLIC_EXPONENT", 4, 140}, | |
| #endif | |
| #ifdef RSA_R_NULL_BEFORE_BLOCK_MISSING | |
| {"NULL_BEFORE_BLOCK_MISSING", ERR_LIB_RSA, RSA_R_NULL_BEFORE_BLOCK_MISSING}, | |
| #else | |
| {"NULL_BEFORE_BLOCK_MISSING", 4, 113}, | |
| #endif | |
| #ifdef RSA_R_N_DOES_NOT_EQUAL_PRODUCT_OF_PRIMES | |
| {"N_DOES_NOT_EQUAL_PRODUCT_OF_PRIMES", ERR_LIB_RSA, RSA_R_N_DOES_NOT_EQUAL_PRODUCT_OF_PRIMES}, | |
| #else | |
| {"N_DOES_NOT_EQUAL_PRODUCT_OF_PRIMES", 4, 172}, | |
| #endif | |
| #ifdef RSA_R_N_DOES_NOT_EQUAL_P_Q | |
| {"N_DOES_NOT_EQUAL_P_Q", ERR_LIB_RSA, RSA_R_N_DOES_NOT_EQUAL_P_Q}, | |
| #else | |
| {"N_DOES_NOT_EQUAL_P_Q", 4, 127}, | |
| #endif | |
| #ifdef RSA_R_OAEP_DECODING_ERROR | |
| {"OAEP_DECODING_ERROR", ERR_LIB_RSA, RSA_R_OAEP_DECODING_ERROR}, | |
| #else | |
| {"OAEP_DECODING_ERROR", 4, 121}, | |
| #endif | |
| #ifdef RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", ERR_LIB_RSA, RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE}, | |
| #else | |
| {"OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE", 4, 148}, | |
| #endif | |
| #ifdef RSA_R_PADDING_CHECK_FAILED | |
| {"PADDING_CHECK_FAILED", ERR_LIB_RSA, RSA_R_PADDING_CHECK_FAILED}, | |
| #else | |
| {"PADDING_CHECK_FAILED", 4, 114}, | |
| #endif | |
| #ifdef RSA_R_PAIRWISE_TEST_FAILURE | |
| {"PAIRWISE_TEST_FAILURE", ERR_LIB_RSA, RSA_R_PAIRWISE_TEST_FAILURE}, | |
| #else | |
| {"PAIRWISE_TEST_FAILURE", 4, 177}, | |
| #endif | |
| #ifdef RSA_R_PKCS_DECODING_ERROR | |
| {"PKCS_DECODING_ERROR", ERR_LIB_RSA, RSA_R_PKCS_DECODING_ERROR}, | |
| #else | |
| {"PKCS_DECODING_ERROR", 4, 159}, | |
| #endif | |
| #ifdef RSA_R_PSS_SALTLEN_TOO_SMALL | |
| {"PSS_SALTLEN_TOO_SMALL", ERR_LIB_RSA, RSA_R_PSS_SALTLEN_TOO_SMALL}, | |
| #else | |
| {"PSS_SALTLEN_TOO_SMALL", 4, 164}, | |
| #endif | |
| #ifdef RSA_R_PUB_EXPONENT_OUT_OF_RANGE | |
| {"PUB_EXPONENT_OUT_OF_RANGE", ERR_LIB_RSA, RSA_R_PUB_EXPONENT_OUT_OF_RANGE}, | |
| #else | |
| {"PUB_EXPONENT_OUT_OF_RANGE", 4, 178}, | |
| #endif | |
| #ifdef RSA_R_P_NOT_PRIME | |
| {"P_NOT_PRIME", ERR_LIB_RSA, RSA_R_P_NOT_PRIME}, | |
| #else | |
| {"P_NOT_PRIME", 4, 128}, | |
| #endif | |
| #ifdef RSA_R_Q_NOT_PRIME | |
| {"Q_NOT_PRIME", ERR_LIB_RSA, RSA_R_Q_NOT_PRIME}, | |
| #else | |
| {"Q_NOT_PRIME", 4, 129}, | |
| #endif | |
| #ifdef RSA_R_RANDOMNESS_SOURCE_STRENGTH_INSUFFICIENT | |
| {"RANDOMNESS_SOURCE_STRENGTH_INSUFFICIENT", ERR_LIB_RSA, RSA_R_RANDOMNESS_SOURCE_STRENGTH_INSUFFICIENT}, | |
| #else | |
| {"RANDOMNESS_SOURCE_STRENGTH_INSUFFICIENT", 4, 180}, | |
| #endif | |
| #ifdef RSA_R_RSA_OPERATIONS_NOT_SUPPORTED | |
| {"RSA_OPERATIONS_NOT_SUPPORTED", ERR_LIB_RSA, RSA_R_RSA_OPERATIONS_NOT_SUPPORTED}, | |
| #else | |
| {"RSA_OPERATIONS_NOT_SUPPORTED", 4, 130}, | |
| #endif | |
| #ifdef RSA_R_SLEN_CHECK_FAILED | |
| {"SLEN_CHECK_FAILED", ERR_LIB_RSA, RSA_R_SLEN_CHECK_FAILED}, | |
| #else | |
| {"SLEN_CHECK_FAILED", 4, 136}, | |
| #endif | |
| #ifdef RSA_R_SLEN_RECOVERY_FAILED | |
| {"SLEN_RECOVERY_FAILED", ERR_LIB_RSA, RSA_R_SLEN_RECOVERY_FAILED}, | |
| #else | |
| {"SLEN_RECOVERY_FAILED", 4, 135}, | |
| #endif | |
| #ifdef RSA_R_SSLV3_ROLLBACK_ATTACK | |
| {"SSLV3_ROLLBACK_ATTACK", ERR_LIB_RSA, RSA_R_SSLV3_ROLLBACK_ATTACK}, | |
| #else | |
| {"SSLV3_ROLLBACK_ATTACK", 4, 115}, | |
| #endif | |
| #ifdef RSA_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD | |
| {"THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD", ERR_LIB_RSA, RSA_R_THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD}, | |
| #else | |
| {"THE_ASN1_OBJECT_IDENTIFIER_IS_NOT_KNOWN_FOR_THIS_MD", 4, 116}, | |
| #endif | |
| #ifdef RSA_R_UNKNOWN_ALGORITHM_TYPE | |
| {"UNKNOWN_ALGORITHM_TYPE", ERR_LIB_RSA, RSA_R_UNKNOWN_ALGORITHM_TYPE}, | |
| #else | |
| {"UNKNOWN_ALGORITHM_TYPE", 4, 117}, | |
| #endif | |
| #ifdef RSA_R_UNKNOWN_DIGEST | |
| {"UNKNOWN_DIGEST", ERR_LIB_RSA, RSA_R_UNKNOWN_DIGEST}, | |
| #else | |
| {"UNKNOWN_DIGEST", 4, 166}, | |
| #endif | |
| #ifdef RSA_R_UNKNOWN_MASK_DIGEST | |
| {"UNKNOWN_MASK_DIGEST", ERR_LIB_RSA, RSA_R_UNKNOWN_MASK_DIGEST}, | |
| #else | |
| {"UNKNOWN_MASK_DIGEST", 4, 151}, | |
| #endif | |
| #ifdef RSA_R_UNKNOWN_PADDING_TYPE | |
| {"UNKNOWN_PADDING_TYPE", ERR_LIB_RSA, RSA_R_UNKNOWN_PADDING_TYPE}, | |
| #else | |
| {"UNKNOWN_PADDING_TYPE", 4, 118}, | |
| #endif | |
| #ifdef RSA_R_UNSUPPORTED_ENCRYPTION_TYPE | |
| {"UNSUPPORTED_ENCRYPTION_TYPE", ERR_LIB_RSA, RSA_R_UNSUPPORTED_ENCRYPTION_TYPE}, | |
| #else | |
| {"UNSUPPORTED_ENCRYPTION_TYPE", 4, 162}, | |
| #endif | |
| #ifdef RSA_R_UNSUPPORTED_LABEL_SOURCE | |
| {"UNSUPPORTED_LABEL_SOURCE", ERR_LIB_RSA, RSA_R_UNSUPPORTED_LABEL_SOURCE}, | |
| #else | |
| {"UNSUPPORTED_LABEL_SOURCE", 4, 163}, | |
| #endif | |
| #ifdef RSA_R_UNSUPPORTED_MASK_ALGORITHM | |
| {"UNSUPPORTED_MASK_ALGORITHM", ERR_LIB_RSA, RSA_R_UNSUPPORTED_MASK_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_MASK_ALGORITHM", 4, 153}, | |
| #endif | |
| #ifdef RSA_R_UNSUPPORTED_MASK_PARAMETER | |
| {"UNSUPPORTED_MASK_PARAMETER", ERR_LIB_RSA, RSA_R_UNSUPPORTED_MASK_PARAMETER}, | |
| #else | |
| {"UNSUPPORTED_MASK_PARAMETER", 4, 154}, | |
| #endif | |
| #ifdef RSA_R_UNSUPPORTED_SIGNATURE_TYPE | |
| {"UNSUPPORTED_SIGNATURE_TYPE", ERR_LIB_RSA, RSA_R_UNSUPPORTED_SIGNATURE_TYPE}, | |
| #else | |
| {"UNSUPPORTED_SIGNATURE_TYPE", 4, 155}, | |
| #endif | |
| #ifdef RSA_R_VALUE_MISSING | |
| {"VALUE_MISSING", ERR_LIB_RSA, RSA_R_VALUE_MISSING}, | |
| #else | |
| {"VALUE_MISSING", 4, 147}, | |
| #endif | |
| #ifdef RSA_R_WRONG_SIGNATURE_LENGTH | |
| {"WRONG_SIGNATURE_LENGTH", ERR_LIB_RSA, RSA_R_WRONG_SIGNATURE_LENGTH}, | |
| #else | |
| {"WRONG_SIGNATURE_LENGTH", 4, 119}, | |
| #endif | |
| #ifdef SM2_R_ASN1_ERROR | |
| {"ASN1_ERROR", ERR_LIB_SM2, SM2_R_ASN1_ERROR}, | |
| #else | |
| {"ASN1_ERROR", 53, 100}, | |
| #endif | |
| #ifdef SM2_R_BAD_SIGNATURE | |
| {"BAD_SIGNATURE", ERR_LIB_SM2, SM2_R_BAD_SIGNATURE}, | |
| #else | |
| {"BAD_SIGNATURE", 53, 101}, | |
| #endif | |
| #ifdef SM2_R_BUFFER_TOO_SMALL | |
| {"BUFFER_TOO_SMALL", ERR_LIB_SM2, SM2_R_BUFFER_TOO_SMALL}, | |
| #else | |
| {"BUFFER_TOO_SMALL", 53, 107}, | |
| #endif | |
| #ifdef SM2_R_DIST_ID_TOO_LARGE | |
| {"DIST_ID_TOO_LARGE", ERR_LIB_SM2, SM2_R_DIST_ID_TOO_LARGE}, | |
| #else | |
| {"DIST_ID_TOO_LARGE", 53, 110}, | |
| #endif | |
| #ifdef SM2_R_ID_NOT_SET | |
| {"ID_NOT_SET", ERR_LIB_SM2, SM2_R_ID_NOT_SET}, | |
| #else | |
| {"ID_NOT_SET", 53, 112}, | |
| #endif | |
| #ifdef SM2_R_ID_TOO_LARGE | |
| {"ID_TOO_LARGE", ERR_LIB_SM2, SM2_R_ID_TOO_LARGE}, | |
| #else | |
| {"ID_TOO_LARGE", 53, 111}, | |
| #endif | |
| #ifdef SM2_R_INVALID_CURVE | |
| {"INVALID_CURVE", ERR_LIB_SM2, SM2_R_INVALID_CURVE}, | |
| #else | |
| {"INVALID_CURVE", 53, 108}, | |
| #endif | |
| #ifdef SM2_R_INVALID_DIGEST | |
| {"INVALID_DIGEST", ERR_LIB_SM2, SM2_R_INVALID_DIGEST}, | |
| #else | |
| {"INVALID_DIGEST", 53, 102}, | |
| #endif | |
| #ifdef SM2_R_INVALID_DIGEST_TYPE | |
| {"INVALID_DIGEST_TYPE", ERR_LIB_SM2, SM2_R_INVALID_DIGEST_TYPE}, | |
| #else | |
| {"INVALID_DIGEST_TYPE", 53, 103}, | |
| #endif | |
| #ifdef SM2_R_INVALID_ENCODING | |
| {"INVALID_ENCODING", ERR_LIB_SM2, SM2_R_INVALID_ENCODING}, | |
| #else | |
| {"INVALID_ENCODING", 53, 104}, | |
| #endif | |
| #ifdef SM2_R_INVALID_FIELD | |
| {"INVALID_FIELD", ERR_LIB_SM2, SM2_R_INVALID_FIELD}, | |
| #else | |
| {"INVALID_FIELD", 53, 105}, | |
| #endif | |
| #ifdef SM2_R_INVALID_PRIVATE_KEY | |
| {"INVALID_PRIVATE_KEY", ERR_LIB_SM2, SM2_R_INVALID_PRIVATE_KEY}, | |
| #else | |
| {"INVALID_PRIVATE_KEY", 53, 113}, | |
| #endif | |
| #ifdef SM2_R_NO_PARAMETERS_SET | |
| {"NO_PARAMETERS_SET", ERR_LIB_SM2, SM2_R_NO_PARAMETERS_SET}, | |
| #else | |
| {"NO_PARAMETERS_SET", 53, 109}, | |
| #endif | |
| #ifdef SM2_R_USER_ID_TOO_LARGE | |
| {"USER_ID_TOO_LARGE", ERR_LIB_SM2, SM2_R_USER_ID_TOO_LARGE}, | |
| #else | |
| {"USER_ID_TOO_LARGE", 53, 106}, | |
| #endif | |
| #ifdef SSL_R_APPLICATION_DATA_AFTER_CLOSE_NOTIFY | |
| {"APPLICATION_DATA_AFTER_CLOSE_NOTIFY", ERR_LIB_SSL, SSL_R_APPLICATION_DATA_AFTER_CLOSE_NOTIFY}, | |
| #else | |
| {"APPLICATION_DATA_AFTER_CLOSE_NOTIFY", 20, 291}, | |
| #endif | |
| #ifdef SSL_R_APP_DATA_IN_HANDSHAKE | |
| {"APP_DATA_IN_HANDSHAKE", ERR_LIB_SSL, SSL_R_APP_DATA_IN_HANDSHAKE}, | |
| #else | |
| {"APP_DATA_IN_HANDSHAKE", 20, 100}, | |
| #endif | |
| #ifdef SSL_R_ATTEMPT_TO_REUSE_SESSION_IN_DIFFERENT_CONTEXT | |
| {"ATTEMPT_TO_REUSE_SESSION_IN_DIFFERENT_CONTEXT", ERR_LIB_SSL, SSL_R_ATTEMPT_TO_REUSE_SESSION_IN_DIFFERENT_CONTEXT}, | |
| #else | |
| {"ATTEMPT_TO_REUSE_SESSION_IN_DIFFERENT_CONTEXT", 20, 272}, | |
| #endif | |
| #ifdef SSL_R_AT_LEAST_TLS_1_2_NEEDED_IN_SUITEB_MODE | |
| {"AT_LEAST_TLS_1_2_NEEDED_IN_SUITEB_MODE", ERR_LIB_SSL, SSL_R_AT_LEAST_TLS_1_2_NEEDED_IN_SUITEB_MODE}, | |
| #else | |
| {"AT_LEAST_TLS_1_2_NEEDED_IN_SUITEB_MODE", 20, 158}, | |
| #endif | |
| #ifdef SSL_R_BAD_CERTIFICATE | |
| {"BAD_CERTIFICATE", ERR_LIB_SSL, SSL_R_BAD_CERTIFICATE}, | |
| #else | |
| {"BAD_CERTIFICATE", 20, 348}, | |
| #endif | |
| #ifdef SSL_R_BAD_CHANGE_CIPHER_SPEC | |
| {"BAD_CHANGE_CIPHER_SPEC", ERR_LIB_SSL, SSL_R_BAD_CHANGE_CIPHER_SPEC}, | |
| #else | |
| {"BAD_CHANGE_CIPHER_SPEC", 20, 103}, | |
| #endif | |
| #ifdef SSL_R_BAD_CIPHER | |
| {"BAD_CIPHER", ERR_LIB_SSL, SSL_R_BAD_CIPHER}, | |
| #else | |
| {"BAD_CIPHER", 20, 186}, | |
| #endif | |
| #ifdef SSL_R_BAD_COMPRESSION_ALGORITHM | |
| {"BAD_COMPRESSION_ALGORITHM", ERR_LIB_SSL, SSL_R_BAD_COMPRESSION_ALGORITHM}, | |
| #else | |
| {"BAD_COMPRESSION_ALGORITHM", 20, 326}, | |
| #endif | |
| #ifdef SSL_R_BAD_DATA | |
| {"BAD_DATA", ERR_LIB_SSL, SSL_R_BAD_DATA}, | |
| #else | |
| {"BAD_DATA", 20, 390}, | |
| #endif | |
| #ifdef SSL_R_BAD_DATA_RETURNED_BY_CALLBACK | |
| {"BAD_DATA_RETURNED_BY_CALLBACK", ERR_LIB_SSL, SSL_R_BAD_DATA_RETURNED_BY_CALLBACK}, | |
| #else | |
| {"BAD_DATA_RETURNED_BY_CALLBACK", 20, 106}, | |
| #endif | |
| #ifdef SSL_R_BAD_DECOMPRESSION | |
| {"BAD_DECOMPRESSION", ERR_LIB_SSL, SSL_R_BAD_DECOMPRESSION}, | |
| #else | |
| {"BAD_DECOMPRESSION", 20, 107}, | |
| #endif | |
| #ifdef SSL_R_BAD_DH_VALUE | |
| {"BAD_DH_VALUE", ERR_LIB_SSL, SSL_R_BAD_DH_VALUE}, | |
| #else | |
| {"BAD_DH_VALUE", 20, 102}, | |
| #endif | |
| #ifdef SSL_R_BAD_DIGEST_LENGTH | |
| {"BAD_DIGEST_LENGTH", ERR_LIB_SSL, SSL_R_BAD_DIGEST_LENGTH}, | |
| #else | |
| {"BAD_DIGEST_LENGTH", 20, 111}, | |
| #endif | |
| #ifdef SSL_R_BAD_EARLY_DATA | |
| {"BAD_EARLY_DATA", ERR_LIB_SSL, SSL_R_BAD_EARLY_DATA}, | |
| #else | |
| {"BAD_EARLY_DATA", 20, 233}, | |
| #endif | |
| #ifdef SSL_R_BAD_ECC_CERT | |
| {"BAD_ECC_CERT", ERR_LIB_SSL, SSL_R_BAD_ECC_CERT}, | |
| #else | |
| {"BAD_ECC_CERT", 20, 304}, | |
| #endif | |
| #ifdef SSL_R_BAD_ECPOINT | |
| {"BAD_ECPOINT", ERR_LIB_SSL, SSL_R_BAD_ECPOINT}, | |
| #else | |
| {"BAD_ECPOINT", 20, 306}, | |
| #endif | |
| #ifdef SSL_R_BAD_EXTENSION | |
| {"BAD_EXTENSION", ERR_LIB_SSL, SSL_R_BAD_EXTENSION}, | |
| #else | |
| {"BAD_EXTENSION", 20, 110}, | |
| #endif | |
| #ifdef SSL_R_BAD_HANDSHAKE_LENGTH | |
| {"BAD_HANDSHAKE_LENGTH", ERR_LIB_SSL, SSL_R_BAD_HANDSHAKE_LENGTH}, | |
| #else | |
| {"BAD_HANDSHAKE_LENGTH", 20, 332}, | |
| #endif | |
| #ifdef SSL_R_BAD_HANDSHAKE_STATE | |
| {"BAD_HANDSHAKE_STATE", ERR_LIB_SSL, SSL_R_BAD_HANDSHAKE_STATE}, | |
| #else | |
| {"BAD_HANDSHAKE_STATE", 20, 236}, | |
| #endif | |
| #ifdef SSL_R_BAD_HELLO_REQUEST | |
| {"BAD_HELLO_REQUEST", ERR_LIB_SSL, SSL_R_BAD_HELLO_REQUEST}, | |
| #else | |
| {"BAD_HELLO_REQUEST", 20, 105}, | |
| #endif | |
| #ifdef SSL_R_BAD_HRR_VERSION | |
| {"BAD_HRR_VERSION", ERR_LIB_SSL, SSL_R_BAD_HRR_VERSION}, | |
| #else | |
| {"BAD_HRR_VERSION", 20, 263}, | |
| #endif | |
| #ifdef SSL_R_BAD_KEY_SHARE | |
| {"BAD_KEY_SHARE", ERR_LIB_SSL, SSL_R_BAD_KEY_SHARE}, | |
| #else | |
| {"BAD_KEY_SHARE", 20, 108}, | |
| #endif | |
| #ifdef SSL_R_BAD_KEY_UPDATE | |
| {"BAD_KEY_UPDATE", ERR_LIB_SSL, SSL_R_BAD_KEY_UPDATE}, | |
| #else | |
| {"BAD_KEY_UPDATE", 20, 122}, | |
| #endif | |
| #ifdef SSL_R_BAD_LEGACY_VERSION | |
| {"BAD_LEGACY_VERSION", ERR_LIB_SSL, SSL_R_BAD_LEGACY_VERSION}, | |
| #else | |
| {"BAD_LEGACY_VERSION", 20, 292}, | |
| #endif | |
| #ifdef SSL_R_BAD_LENGTH | |
| {"BAD_LENGTH", ERR_LIB_SSL, SSL_R_BAD_LENGTH}, | |
| #else | |
| {"BAD_LENGTH", 20, 271}, | |
| #endif | |
| #ifdef SSL_R_BAD_PACKET | |
| {"BAD_PACKET", ERR_LIB_SSL, SSL_R_BAD_PACKET}, | |
| #else | |
| {"BAD_PACKET", 20, 240}, | |
| #endif | |
| #ifdef SSL_R_BAD_PACKET_LENGTH | |
| {"BAD_PACKET_LENGTH", ERR_LIB_SSL, SSL_R_BAD_PACKET_LENGTH}, | |
| #else | |
| {"BAD_PACKET_LENGTH", 20, 115}, | |
| #endif | |
| #ifdef SSL_R_BAD_PROTOCOL_VERSION_NUMBER | |
| {"BAD_PROTOCOL_VERSION_NUMBER", ERR_LIB_SSL, SSL_R_BAD_PROTOCOL_VERSION_NUMBER}, | |
| #else | |
| {"BAD_PROTOCOL_VERSION_NUMBER", 20, 116}, | |
| #endif | |
| #ifdef SSL_R_BAD_PSK | |
| {"BAD_PSK", ERR_LIB_SSL, SSL_R_BAD_PSK}, | |
| #else | |
| {"BAD_PSK", 20, 219}, | |
| #endif | |
| #ifdef SSL_R_BAD_PSK_IDENTITY | |
| {"BAD_PSK_IDENTITY", ERR_LIB_SSL, SSL_R_BAD_PSK_IDENTITY}, | |
| #else | |
| {"BAD_PSK_IDENTITY", 20, 114}, | |
| #endif | |
| #ifdef SSL_R_BAD_RECORD_TYPE | |
| {"BAD_RECORD_TYPE", ERR_LIB_SSL, SSL_R_BAD_RECORD_TYPE}, | |
| #else | |
| {"BAD_RECORD_TYPE", 20, 443}, | |
| #endif | |
| #ifdef SSL_R_BAD_RSA_ENCRYPT | |
| {"BAD_RSA_ENCRYPT", ERR_LIB_SSL, SSL_R_BAD_RSA_ENCRYPT}, | |
| #else | |
| {"BAD_RSA_ENCRYPT", 20, 119}, | |
| #endif | |
| #ifdef SSL_R_BAD_SIGNATURE | |
| {"BAD_SIGNATURE", ERR_LIB_SSL, SSL_R_BAD_SIGNATURE}, | |
| #else | |
| {"BAD_SIGNATURE", 20, 123}, | |
| #endif | |
| #ifdef SSL_R_BAD_SRP_A_LENGTH | |
| {"BAD_SRP_A_LENGTH", ERR_LIB_SSL, SSL_R_BAD_SRP_A_LENGTH}, | |
| #else | |
| {"BAD_SRP_A_LENGTH", 20, 347}, | |
| #endif | |
| #ifdef SSL_R_BAD_SRP_PARAMETERS | |
| {"BAD_SRP_PARAMETERS", ERR_LIB_SSL, SSL_R_BAD_SRP_PARAMETERS}, | |
| #else | |
| {"BAD_SRP_PARAMETERS", 20, 371}, | |
| #endif | |
| #ifdef SSL_R_BAD_SRTP_MKI_VALUE | |
| {"BAD_SRTP_MKI_VALUE", ERR_LIB_SSL, SSL_R_BAD_SRTP_MKI_VALUE}, | |
| #else | |
| {"BAD_SRTP_MKI_VALUE", 20, 352}, | |
| #endif | |
| #ifdef SSL_R_BAD_SRTP_PROTECTION_PROFILE_LIST | |
| {"BAD_SRTP_PROTECTION_PROFILE_LIST", ERR_LIB_SSL, SSL_R_BAD_SRTP_PROTECTION_PROFILE_LIST}, | |
| #else | |
| {"BAD_SRTP_PROTECTION_PROFILE_LIST", 20, 353}, | |
| #endif | |
| #ifdef SSL_R_BAD_SSL_FILETYPE | |
| {"BAD_SSL_FILETYPE", ERR_LIB_SSL, SSL_R_BAD_SSL_FILETYPE}, | |
| #else | |
| {"BAD_SSL_FILETYPE", 20, 124}, | |
| #endif | |
| #ifdef SSL_R_BAD_VALUE | |
| {"BAD_VALUE", ERR_LIB_SSL, SSL_R_BAD_VALUE}, | |
| #else | |
| {"BAD_VALUE", 20, 384}, | |
| #endif | |
| #ifdef SSL_R_BAD_WRITE_RETRY | |
| {"BAD_WRITE_RETRY", ERR_LIB_SSL, SSL_R_BAD_WRITE_RETRY}, | |
| #else | |
| {"BAD_WRITE_RETRY", 20, 127}, | |
| #endif | |
| #ifdef SSL_R_BINDER_DOES_NOT_VERIFY | |
| {"BINDER_DOES_NOT_VERIFY", ERR_LIB_SSL, SSL_R_BINDER_DOES_NOT_VERIFY}, | |
| #else | |
| {"BINDER_DOES_NOT_VERIFY", 20, 253}, | |
| #endif | |
| #ifdef SSL_R_BIO_NOT_SET | |
| {"BIO_NOT_SET", ERR_LIB_SSL, SSL_R_BIO_NOT_SET}, | |
| #else | |
| {"BIO_NOT_SET", 20, 128}, | |
| #endif | |
| #ifdef SSL_R_BLOCK_CIPHER_PAD_IS_WRONG | |
| {"BLOCK_CIPHER_PAD_IS_WRONG", ERR_LIB_SSL, SSL_R_BLOCK_CIPHER_PAD_IS_WRONG}, | |
| #else | |
| {"BLOCK_CIPHER_PAD_IS_WRONG", 20, 129}, | |
| #endif | |
| #ifdef SSL_R_BN_LIB | |
| {"BN_LIB", ERR_LIB_SSL, SSL_R_BN_LIB}, | |
| #else | |
| {"BN_LIB", 20, 130}, | |
| #endif | |
| #ifdef SSL_R_CALLBACK_FAILED | |
| {"CALLBACK_FAILED", ERR_LIB_SSL, SSL_R_CALLBACK_FAILED}, | |
| #else | |
| {"CALLBACK_FAILED", 20, 234}, | |
| #endif | |
| #ifdef SSL_R_CANNOT_CHANGE_CIPHER | |
| {"CANNOT_CHANGE_CIPHER", ERR_LIB_SSL, SSL_R_CANNOT_CHANGE_CIPHER}, | |
| #else | |
| {"CANNOT_CHANGE_CIPHER", 20, 109}, | |
| #endif | |
| #ifdef SSL_R_CANNOT_GET_GROUP_NAME | |
| {"CANNOT_GET_GROUP_NAME", ERR_LIB_SSL, SSL_R_CANNOT_GET_GROUP_NAME}, | |
| #else | |
| {"CANNOT_GET_GROUP_NAME", 20, 299}, | |
| #endif | |
| #ifdef SSL_R_CA_DN_LENGTH_MISMATCH | |
| {"CA_DN_LENGTH_MISMATCH", ERR_LIB_SSL, SSL_R_CA_DN_LENGTH_MISMATCH}, | |
| #else | |
| {"CA_DN_LENGTH_MISMATCH", 20, 131}, | |
| #endif | |
| #ifdef SSL_R_CA_KEY_TOO_SMALL | |
| {"CA_KEY_TOO_SMALL", ERR_LIB_SSL, SSL_R_CA_KEY_TOO_SMALL}, | |
| #else | |
| {"CA_KEY_TOO_SMALL", 20, 397}, | |
| #endif | |
| #ifdef SSL_R_CA_MD_TOO_WEAK | |
| {"CA_MD_TOO_WEAK", ERR_LIB_SSL, SSL_R_CA_MD_TOO_WEAK}, | |
| #else | |
| {"CA_MD_TOO_WEAK", 20, 398}, | |
| #endif | |
| #ifdef SSL_R_CCS_RECEIVED_EARLY | |
| {"CCS_RECEIVED_EARLY", ERR_LIB_SSL, SSL_R_CCS_RECEIVED_EARLY}, | |
| #else | |
| {"CCS_RECEIVED_EARLY", 20, 133}, | |
| #endif | |
| #ifdef SSL_R_CERTIFICATE_VERIFY_FAILED | |
| {"CERTIFICATE_VERIFY_FAILED", ERR_LIB_SSL, SSL_R_CERTIFICATE_VERIFY_FAILED}, | |
| #else | |
| {"CERTIFICATE_VERIFY_FAILED", 20, 134}, | |
| #endif | |
| #ifdef SSL_R_CERT_CB_ERROR | |
| {"CERT_CB_ERROR", ERR_LIB_SSL, SSL_R_CERT_CB_ERROR}, | |
| #else | |
| {"CERT_CB_ERROR", 20, 377}, | |
| #endif | |
| #ifdef SSL_R_CERT_LENGTH_MISMATCH | |
| {"CERT_LENGTH_MISMATCH", ERR_LIB_SSL, SSL_R_CERT_LENGTH_MISMATCH}, | |
| #else | |
| {"CERT_LENGTH_MISMATCH", 20, 135}, | |
| #endif | |
| #ifdef SSL_R_CIPHERSUITE_DIGEST_HAS_CHANGED | |
| {"CIPHERSUITE_DIGEST_HAS_CHANGED", ERR_LIB_SSL, SSL_R_CIPHERSUITE_DIGEST_HAS_CHANGED}, | |
| #else | |
| {"CIPHERSUITE_DIGEST_HAS_CHANGED", 20, 218}, | |
| #endif | |
| #ifdef SSL_R_CIPHER_CODE_WRONG_LENGTH | |
| {"CIPHER_CODE_WRONG_LENGTH", ERR_LIB_SSL, SSL_R_CIPHER_CODE_WRONG_LENGTH}, | |
| #else | |
| {"CIPHER_CODE_WRONG_LENGTH", 20, 137}, | |
| #endif | |
| #ifdef SSL_R_CLIENTHELLO_TLSEXT | |
| {"CLIENTHELLO_TLSEXT", ERR_LIB_SSL, SSL_R_CLIENTHELLO_TLSEXT}, | |
| #else | |
| {"CLIENTHELLO_TLSEXT", 20, 226}, | |
| #endif | |
| #ifdef SSL_R_COMPRESSED_LENGTH_TOO_LONG | |
| {"COMPRESSED_LENGTH_TOO_LONG", ERR_LIB_SSL, SSL_R_COMPRESSED_LENGTH_TOO_LONG}, | |
| #else | |
| {"COMPRESSED_LENGTH_TOO_LONG", 20, 140}, | |
| #endif | |
| #ifdef SSL_R_COMPRESSION_DISABLED | |
| {"COMPRESSION_DISABLED", ERR_LIB_SSL, SSL_R_COMPRESSION_DISABLED}, | |
| #else | |
| {"COMPRESSION_DISABLED", 20, 343}, | |
| #endif | |
| #ifdef SSL_R_COMPRESSION_FAILURE | |
| {"COMPRESSION_FAILURE", ERR_LIB_SSL, SSL_R_COMPRESSION_FAILURE}, | |
| #else | |
| {"COMPRESSION_FAILURE", 20, 141}, | |
| #endif | |
| #ifdef SSL_R_COMPRESSION_ID_NOT_WITHIN_PRIVATE_RANGE | |
| {"COMPRESSION_ID_NOT_WITHIN_PRIVATE_RANGE", ERR_LIB_SSL, SSL_R_COMPRESSION_ID_NOT_WITHIN_PRIVATE_RANGE}, | |
| #else | |
| {"COMPRESSION_ID_NOT_WITHIN_PRIVATE_RANGE", 20, 307}, | |
| #endif | |
| #ifdef SSL_R_COMPRESSION_LIBRARY_ERROR | |
| {"COMPRESSION_LIBRARY_ERROR", ERR_LIB_SSL, SSL_R_COMPRESSION_LIBRARY_ERROR}, | |
| #else | |
| {"COMPRESSION_LIBRARY_ERROR", 20, 142}, | |
| #endif | |
| #ifdef SSL_R_CONNECTION_TYPE_NOT_SET | |
| {"CONNECTION_TYPE_NOT_SET", ERR_LIB_SSL, SSL_R_CONNECTION_TYPE_NOT_SET}, | |
| #else | |
| {"CONNECTION_TYPE_NOT_SET", 20, 144}, | |
| #endif | |
| #ifdef SSL_R_CONN_USE_ONLY | |
| {"CONN_USE_ONLY", ERR_LIB_SSL, SSL_R_CONN_USE_ONLY}, | |
| #else | |
| {"CONN_USE_ONLY", 20, 356}, | |
| #endif | |
| #ifdef SSL_R_CONTEXT_NOT_DANE_ENABLED | |
| {"CONTEXT_NOT_DANE_ENABLED", ERR_LIB_SSL, SSL_R_CONTEXT_NOT_DANE_ENABLED}, | |
| #else | |
| {"CONTEXT_NOT_DANE_ENABLED", 20, 167}, | |
| #endif | |
| #ifdef SSL_R_COOKIE_GEN_CALLBACK_FAILURE | |
| {"COOKIE_GEN_CALLBACK_FAILURE", ERR_LIB_SSL, SSL_R_COOKIE_GEN_CALLBACK_FAILURE}, | |
| #else | |
| {"COOKIE_GEN_CALLBACK_FAILURE", 20, 400}, | |
| #endif | |
| #ifdef SSL_R_COOKIE_MISMATCH | |
| {"COOKIE_MISMATCH", ERR_LIB_SSL, SSL_R_COOKIE_MISMATCH}, | |
| #else | |
| {"COOKIE_MISMATCH", 20, 308}, | |
| #endif | |
| #ifdef SSL_R_COPY_PARAMETERS_FAILED | |
| {"COPY_PARAMETERS_FAILED", ERR_LIB_SSL, SSL_R_COPY_PARAMETERS_FAILED}, | |
| #else | |
| {"COPY_PARAMETERS_FAILED", 20, 296}, | |
| #endif | |
| #ifdef SSL_R_CUSTOM_EXT_HANDLER_ALREADY_INSTALLED | |
| {"CUSTOM_EXT_HANDLER_ALREADY_INSTALLED", ERR_LIB_SSL, SSL_R_CUSTOM_EXT_HANDLER_ALREADY_INSTALLED}, | |
| #else | |
| {"CUSTOM_EXT_HANDLER_ALREADY_INSTALLED", 20, 206}, | |
| #endif | |
| #ifdef SSL_R_DANE_ALREADY_ENABLED | |
| {"DANE_ALREADY_ENABLED", ERR_LIB_SSL, SSL_R_DANE_ALREADY_ENABLED}, | |
| #else | |
| {"DANE_ALREADY_ENABLED", 20, 172}, | |
| #endif | |
| #ifdef SSL_R_DANE_CANNOT_OVERRIDE_MTYPE_FULL | |
| {"DANE_CANNOT_OVERRIDE_MTYPE_FULL", ERR_LIB_SSL, SSL_R_DANE_CANNOT_OVERRIDE_MTYPE_FULL}, | |
| #else | |
| {"DANE_CANNOT_OVERRIDE_MTYPE_FULL", 20, 173}, | |
| #endif | |
| #ifdef SSL_R_DANE_NOT_ENABLED | |
| {"DANE_NOT_ENABLED", ERR_LIB_SSL, SSL_R_DANE_NOT_ENABLED}, | |
| #else | |
| {"DANE_NOT_ENABLED", 20, 175}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_CERTIFICATE | |
| {"DANE_TLSA_BAD_CERTIFICATE", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_CERTIFICATE}, | |
| #else | |
| {"DANE_TLSA_BAD_CERTIFICATE", 20, 180}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_CERTIFICATE_USAGE | |
| {"DANE_TLSA_BAD_CERTIFICATE_USAGE", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_CERTIFICATE_USAGE}, | |
| #else | |
| {"DANE_TLSA_BAD_CERTIFICATE_USAGE", 20, 184}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_DATA_LENGTH | |
| {"DANE_TLSA_BAD_DATA_LENGTH", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_DATA_LENGTH}, | |
| #else | |
| {"DANE_TLSA_BAD_DATA_LENGTH", 20, 189}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_DIGEST_LENGTH | |
| {"DANE_TLSA_BAD_DIGEST_LENGTH", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_DIGEST_LENGTH}, | |
| #else | |
| {"DANE_TLSA_BAD_DIGEST_LENGTH", 20, 192}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_MATCHING_TYPE | |
| {"DANE_TLSA_BAD_MATCHING_TYPE", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_MATCHING_TYPE}, | |
| #else | |
| {"DANE_TLSA_BAD_MATCHING_TYPE", 20, 200}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_PUBLIC_KEY | |
| {"DANE_TLSA_BAD_PUBLIC_KEY", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_PUBLIC_KEY}, | |
| #else | |
| {"DANE_TLSA_BAD_PUBLIC_KEY", 20, 201}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_BAD_SELECTOR | |
| {"DANE_TLSA_BAD_SELECTOR", ERR_LIB_SSL, SSL_R_DANE_TLSA_BAD_SELECTOR}, | |
| #else | |
| {"DANE_TLSA_BAD_SELECTOR", 20, 202}, | |
| #endif | |
| #ifdef SSL_R_DANE_TLSA_NULL_DATA | |
| {"DANE_TLSA_NULL_DATA", ERR_LIB_SSL, SSL_R_DANE_TLSA_NULL_DATA}, | |
| #else | |
| {"DANE_TLSA_NULL_DATA", 20, 203}, | |
| #endif | |
| #ifdef SSL_R_DATA_BETWEEN_CCS_AND_FINISHED | |
| {"DATA_BETWEEN_CCS_AND_FINISHED", ERR_LIB_SSL, SSL_R_DATA_BETWEEN_CCS_AND_FINISHED}, | |
| #else | |
| {"DATA_BETWEEN_CCS_AND_FINISHED", 20, 145}, | |
| #endif | |
| #ifdef SSL_R_DATA_LENGTH_TOO_LONG | |
| {"DATA_LENGTH_TOO_LONG", ERR_LIB_SSL, SSL_R_DATA_LENGTH_TOO_LONG}, | |
| #else | |
| {"DATA_LENGTH_TOO_LONG", 20, 146}, | |
| #endif | |
| #ifdef SSL_R_DECRYPTION_FAILED | |
| {"DECRYPTION_FAILED", ERR_LIB_SSL, SSL_R_DECRYPTION_FAILED}, | |
| #else | |
| {"DECRYPTION_FAILED", 20, 147}, | |
| #endif | |
| #ifdef SSL_R_DECRYPTION_FAILED_OR_BAD_RECORD_MAC | |
| {"DECRYPTION_FAILED_OR_BAD_RECORD_MAC", ERR_LIB_SSL, SSL_R_DECRYPTION_FAILED_OR_BAD_RECORD_MAC}, | |
| #else | |
| {"DECRYPTION_FAILED_OR_BAD_RECORD_MAC", 20, 281}, | |
| #endif | |
| #ifdef SSL_R_DH_KEY_TOO_SMALL | |
| {"DH_KEY_TOO_SMALL", ERR_LIB_SSL, SSL_R_DH_KEY_TOO_SMALL}, | |
| #else | |
| {"DH_KEY_TOO_SMALL", 20, 394}, | |
| #endif | |
| #ifdef SSL_R_DH_PUBLIC_VALUE_LENGTH_IS_WRONG | |
| {"DH_PUBLIC_VALUE_LENGTH_IS_WRONG", ERR_LIB_SSL, SSL_R_DH_PUBLIC_VALUE_LENGTH_IS_WRONG}, | |
| #else | |
| {"DH_PUBLIC_VALUE_LENGTH_IS_WRONG", 20, 148}, | |
| #endif | |
| #ifdef SSL_R_DIGEST_CHECK_FAILED | |
| {"DIGEST_CHECK_FAILED", ERR_LIB_SSL, SSL_R_DIGEST_CHECK_FAILED}, | |
| #else | |
| {"DIGEST_CHECK_FAILED", 20, 149}, | |
| #endif | |
| #ifdef SSL_R_DOMAIN_USE_ONLY | |
| {"DOMAIN_USE_ONLY", ERR_LIB_SSL, SSL_R_DOMAIN_USE_ONLY}, | |
| #else | |
| {"DOMAIN_USE_ONLY", 20, 422}, | |
| #endif | |
| #ifdef SSL_R_DTLS_MESSAGE_TOO_BIG | |
| {"DTLS_MESSAGE_TOO_BIG", ERR_LIB_SSL, SSL_R_DTLS_MESSAGE_TOO_BIG}, | |
| #else | |
| {"DTLS_MESSAGE_TOO_BIG", 20, 334}, | |
| #endif | |
| #ifdef SSL_R_DUPLICATE_COMPRESSION_ID | |
| {"DUPLICATE_COMPRESSION_ID", ERR_LIB_SSL, SSL_R_DUPLICATE_COMPRESSION_ID}, | |
| #else | |
| {"DUPLICATE_COMPRESSION_ID", 20, 309}, | |
| #endif | |
| #ifdef SSL_R_ECC_CERT_NOT_FOR_SIGNING | |
| {"ECC_CERT_NOT_FOR_SIGNING", ERR_LIB_SSL, SSL_R_ECC_CERT_NOT_FOR_SIGNING}, | |
| #else | |
| {"ECC_CERT_NOT_FOR_SIGNING", 20, 318}, | |
| #endif | |
| #ifdef SSL_R_ECDH_REQUIRED_FOR_SUITEB_MODE | |
| {"ECDH_REQUIRED_FOR_SUITEB_MODE", ERR_LIB_SSL, SSL_R_ECDH_REQUIRED_FOR_SUITEB_MODE}, | |
| #else | |
| {"ECDH_REQUIRED_FOR_SUITEB_MODE", 20, 374}, | |
| #endif | |
| #ifdef SSL_R_EE_KEY_TOO_SMALL | |
| {"EE_KEY_TOO_SMALL", ERR_LIB_SSL, SSL_R_EE_KEY_TOO_SMALL}, | |
| #else | |
| {"EE_KEY_TOO_SMALL", 20, 399}, | |
| #endif | |
| #ifdef SSL_R_EMPTY_RAW_PUBLIC_KEY | |
| {"EMPTY_RAW_PUBLIC_KEY", ERR_LIB_SSL, SSL_R_EMPTY_RAW_PUBLIC_KEY}, | |
| #else | |
| {"EMPTY_RAW_PUBLIC_KEY", 20, 349}, | |
| #endif | |
| #ifdef SSL_R_EMPTY_SRTP_PROTECTION_PROFILE_LIST | |
| {"EMPTY_SRTP_PROTECTION_PROFILE_LIST", ERR_LIB_SSL, SSL_R_EMPTY_SRTP_PROTECTION_PROFILE_LIST}, | |
| #else | |
| {"EMPTY_SRTP_PROTECTION_PROFILE_LIST", 20, 354}, | |
| #endif | |
| #ifdef SSL_R_ENCRYPTED_LENGTH_TOO_LONG | |
| {"ENCRYPTED_LENGTH_TOO_LONG", ERR_LIB_SSL, SSL_R_ENCRYPTED_LENGTH_TOO_LONG}, | |
| #else | |
| {"ENCRYPTED_LENGTH_TOO_LONG", 20, 150}, | |
| #endif | |
| #ifdef SSL_R_ERROR_IN_RECEIVED_CIPHER_LIST | |
| {"ERROR_IN_RECEIVED_CIPHER_LIST", ERR_LIB_SSL, SSL_R_ERROR_IN_RECEIVED_CIPHER_LIST}, | |
| #else | |
| {"ERROR_IN_RECEIVED_CIPHER_LIST", 20, 151}, | |
| #endif | |
| #ifdef SSL_R_ERROR_IN_SYSTEM_DEFAULT_CONFIG | |
| {"ERROR_IN_SYSTEM_DEFAULT_CONFIG", ERR_LIB_SSL, SSL_R_ERROR_IN_SYSTEM_DEFAULT_CONFIG}, | |
| #else | |
| {"ERROR_IN_SYSTEM_DEFAULT_CONFIG", 20, 419}, | |
| #endif | |
| #ifdef SSL_R_ERROR_SETTING_TLSA_BASE_DOMAIN | |
| {"ERROR_SETTING_TLSA_BASE_DOMAIN", ERR_LIB_SSL, SSL_R_ERROR_SETTING_TLSA_BASE_DOMAIN}, | |
| #else | |
| {"ERROR_SETTING_TLSA_BASE_DOMAIN", 20, 204}, | |
| #endif | |
| #ifdef SSL_R_EXCEEDS_MAX_FRAGMENT_SIZE | |
| {"EXCEEDS_MAX_FRAGMENT_SIZE", ERR_LIB_SSL, SSL_R_EXCEEDS_MAX_FRAGMENT_SIZE}, | |
| #else | |
| {"EXCEEDS_MAX_FRAGMENT_SIZE", 20, 194}, | |
| #endif | |
| #ifdef SSL_R_EXCESSIVE_MESSAGE_SIZE | |
| {"EXCESSIVE_MESSAGE_SIZE", ERR_LIB_SSL, SSL_R_EXCESSIVE_MESSAGE_SIZE}, | |
| #else | |
| {"EXCESSIVE_MESSAGE_SIZE", 20, 152}, | |
| #endif | |
| #ifdef SSL_R_EXTENSION_NOT_RECEIVED | |
| {"EXTENSION_NOT_RECEIVED", ERR_LIB_SSL, SSL_R_EXTENSION_NOT_RECEIVED}, | |
| #else | |
| {"EXTENSION_NOT_RECEIVED", 20, 279}, | |
| #endif | |
| #ifdef SSL_R_EXTRA_DATA_IN_MESSAGE | |
| {"EXTRA_DATA_IN_MESSAGE", ERR_LIB_SSL, SSL_R_EXTRA_DATA_IN_MESSAGE}, | |
| #else | |
| {"EXTRA_DATA_IN_MESSAGE", 20, 153}, | |
| #endif | |
| #ifdef SSL_R_EXT_LENGTH_MISMATCH | |
| {"EXT_LENGTH_MISMATCH", ERR_LIB_SSL, SSL_R_EXT_LENGTH_MISMATCH}, | |
| #else | |
| {"EXT_LENGTH_MISMATCH", 20, 163}, | |
| #endif | |
| #ifdef SSL_R_FAILED_TO_GET_PARAMETER | |
| {"FAILED_TO_GET_PARAMETER", ERR_LIB_SSL, SSL_R_FAILED_TO_GET_PARAMETER}, | |
| #else | |
| {"FAILED_TO_GET_PARAMETER", 20, 316}, | |
| #endif | |
| #ifdef SSL_R_FAILED_TO_INIT_ASYNC | |
| {"FAILED_TO_INIT_ASYNC", ERR_LIB_SSL, SSL_R_FAILED_TO_INIT_ASYNC}, | |
| #else | |
| {"FAILED_TO_INIT_ASYNC", 20, 405}, | |
| #endif | |
| #ifdef SSL_R_FEATURE_NEGOTIATION_NOT_COMPLETE | |
| {"FEATURE_NEGOTIATION_NOT_COMPLETE", ERR_LIB_SSL, SSL_R_FEATURE_NEGOTIATION_NOT_COMPLETE}, | |
| #else | |
| {"FEATURE_NEGOTIATION_NOT_COMPLETE", 20, 417}, | |
| #endif | |
| #ifdef SSL_R_FEATURE_NOT_RENEGOTIABLE | |
| {"FEATURE_NOT_RENEGOTIABLE", ERR_LIB_SSL, SSL_R_FEATURE_NOT_RENEGOTIABLE}, | |
| #else | |
| {"FEATURE_NOT_RENEGOTIABLE", 20, 413}, | |
| #endif | |
| #ifdef SSL_R_FRAGMENTED_CLIENT_HELLO | |
| {"FRAGMENTED_CLIENT_HELLO", ERR_LIB_SSL, SSL_R_FRAGMENTED_CLIENT_HELLO}, | |
| #else | |
| {"FRAGMENTED_CLIENT_HELLO", 20, 401}, | |
| #endif | |
| #ifdef SSL_R_GOT_A_FIN_BEFORE_A_CCS | |
| {"GOT_A_FIN_BEFORE_A_CCS", ERR_LIB_SSL, SSL_R_GOT_A_FIN_BEFORE_A_CCS}, | |
| #else | |
| {"GOT_A_FIN_BEFORE_A_CCS", 20, 154}, | |
| #endif | |
| #ifdef SSL_R_HTTPS_PROXY_REQUEST | |
| {"HTTPS_PROXY_REQUEST", ERR_LIB_SSL, SSL_R_HTTPS_PROXY_REQUEST}, | |
| #else | |
| {"HTTPS_PROXY_REQUEST", 20, 155}, | |
| #endif | |
| #ifdef SSL_R_HTTP_REQUEST | |
| {"HTTP_REQUEST", ERR_LIB_SSL, SSL_R_HTTP_REQUEST}, | |
| #else | |
| {"HTTP_REQUEST", 20, 156}, | |
| #endif | |
| #ifdef SSL_R_ILLEGAL_POINT_COMPRESSION | |
| {"ILLEGAL_POINT_COMPRESSION", ERR_LIB_SSL, SSL_R_ILLEGAL_POINT_COMPRESSION}, | |
| #else | |
| {"ILLEGAL_POINT_COMPRESSION", 20, 162}, | |
| #endif | |
| #ifdef SSL_R_ILLEGAL_SUITEB_DIGEST | |
| {"ILLEGAL_SUITEB_DIGEST", ERR_LIB_SSL, SSL_R_ILLEGAL_SUITEB_DIGEST}, | |
| #else | |
| {"ILLEGAL_SUITEB_DIGEST", 20, 380}, | |
| #endif | |
| #ifdef SSL_R_INAPPROPRIATE_FALLBACK | |
| {"INAPPROPRIATE_FALLBACK", ERR_LIB_SSL, SSL_R_INAPPROPRIATE_FALLBACK}, | |
| #else | |
| {"INAPPROPRIATE_FALLBACK", 20, 373}, | |
| #endif | |
| #ifdef SSL_R_INCONSISTENT_COMPRESSION | |
| {"INCONSISTENT_COMPRESSION", ERR_LIB_SSL, SSL_R_INCONSISTENT_COMPRESSION}, | |
| #else | |
| {"INCONSISTENT_COMPRESSION", 20, 340}, | |
| #endif | |
| #ifdef SSL_R_INCONSISTENT_EARLY_DATA_ALPN | |
| {"INCONSISTENT_EARLY_DATA_ALPN", ERR_LIB_SSL, SSL_R_INCONSISTENT_EARLY_DATA_ALPN}, | |
| #else | |
| {"INCONSISTENT_EARLY_DATA_ALPN", 20, 222}, | |
| #endif | |
| #ifdef SSL_R_INCONSISTENT_EARLY_DATA_SNI | |
| {"INCONSISTENT_EARLY_DATA_SNI", ERR_LIB_SSL, SSL_R_INCONSISTENT_EARLY_DATA_SNI}, | |
| #else | |
| {"INCONSISTENT_EARLY_DATA_SNI", 20, 231}, | |
| #endif | |
| #ifdef SSL_R_INCONSISTENT_EXTMS | |
| {"INCONSISTENT_EXTMS", ERR_LIB_SSL, SSL_R_INCONSISTENT_EXTMS}, | |
| #else | |
| {"INCONSISTENT_EXTMS", 20, 104}, | |
| #endif | |
| #ifdef SSL_R_INSUFFICIENT_SECURITY | |
| {"INSUFFICIENT_SECURITY", ERR_LIB_SSL, SSL_R_INSUFFICIENT_SECURITY}, | |
| #else | |
| {"INSUFFICIENT_SECURITY", 20, 241}, | |
| #endif | |
| #ifdef SSL_R_INVALID_ALERT | |
| {"INVALID_ALERT", ERR_LIB_SSL, SSL_R_INVALID_ALERT}, | |
| #else | |
| {"INVALID_ALERT", 20, 205}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CCS_MESSAGE | |
| {"INVALID_CCS_MESSAGE", ERR_LIB_SSL, SSL_R_INVALID_CCS_MESSAGE}, | |
| #else | |
| {"INVALID_CCS_MESSAGE", 20, 260}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CERTIFICATE_OR_ALG | |
| {"INVALID_CERTIFICATE_OR_ALG", ERR_LIB_SSL, SSL_R_INVALID_CERTIFICATE_OR_ALG}, | |
| #else | |
| {"INVALID_CERTIFICATE_OR_ALG", 20, 238}, | |
| #endif | |
| #ifdef SSL_R_INVALID_COMMAND | |
| {"INVALID_COMMAND", ERR_LIB_SSL, SSL_R_INVALID_COMMAND}, | |
| #else | |
| {"INVALID_COMMAND", 20, 280}, | |
| #endif | |
| #ifdef SSL_R_INVALID_COMPRESSION_ALGORITHM | |
| {"INVALID_COMPRESSION_ALGORITHM", ERR_LIB_SSL, SSL_R_INVALID_COMPRESSION_ALGORITHM}, | |
| #else | |
| {"INVALID_COMPRESSION_ALGORITHM", 20, 341}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CONFIG | |
| {"INVALID_CONFIG", ERR_LIB_SSL, SSL_R_INVALID_CONFIG}, | |
| #else | |
| {"INVALID_CONFIG", 20, 283}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CONFIGURATION_NAME | |
| {"INVALID_CONFIGURATION_NAME", ERR_LIB_SSL, SSL_R_INVALID_CONFIGURATION_NAME}, | |
| #else | |
| {"INVALID_CONFIGURATION_NAME", 20, 113}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CONTEXT | |
| {"INVALID_CONTEXT", ERR_LIB_SSL, SSL_R_INVALID_CONTEXT}, | |
| #else | |
| {"INVALID_CONTEXT", 20, 282}, | |
| #endif | |
| #ifdef SSL_R_INVALID_CT_VALIDATION_TYPE | |
| {"INVALID_CT_VALIDATION_TYPE", ERR_LIB_SSL, SSL_R_INVALID_CT_VALIDATION_TYPE}, | |
| #else | |
| {"INVALID_CT_VALIDATION_TYPE", 20, 212}, | |
| #endif | |
| #ifdef SSL_R_INVALID_KEY_UPDATE_TYPE | |
| {"INVALID_KEY_UPDATE_TYPE", ERR_LIB_SSL, SSL_R_INVALID_KEY_UPDATE_TYPE}, | |
| #else | |
| {"INVALID_KEY_UPDATE_TYPE", 20, 120}, | |
| #endif | |
| #ifdef SSL_R_INVALID_MAX_EARLY_DATA | |
| {"INVALID_MAX_EARLY_DATA", ERR_LIB_SSL, SSL_R_INVALID_MAX_EARLY_DATA}, | |
| #else | |
| {"INVALID_MAX_EARLY_DATA", 20, 174}, | |
| #endif | |
| #ifdef SSL_R_INVALID_NULL_CMD_NAME | |
| {"INVALID_NULL_CMD_NAME", ERR_LIB_SSL, SSL_R_INVALID_NULL_CMD_NAME}, | |
| #else | |
| {"INVALID_NULL_CMD_NAME", 20, 385}, | |
| #endif | |
| #ifdef SSL_R_INVALID_RAW_PUBLIC_KEY | |
| {"INVALID_RAW_PUBLIC_KEY", ERR_LIB_SSL, SSL_R_INVALID_RAW_PUBLIC_KEY}, | |
| #else | |
| {"INVALID_RAW_PUBLIC_KEY", 20, 350}, | |
| #endif | |
| #ifdef SSL_R_INVALID_RECORD | |
| {"INVALID_RECORD", ERR_LIB_SSL, SSL_R_INVALID_RECORD}, | |
| #else | |
| {"INVALID_RECORD", 20, 317}, | |
| #endif | |
| #ifdef SSL_R_INVALID_SEQUENCE_NUMBER | |
| {"INVALID_SEQUENCE_NUMBER", ERR_LIB_SSL, SSL_R_INVALID_SEQUENCE_NUMBER}, | |
| #else | |
| {"INVALID_SEQUENCE_NUMBER", 20, 402}, | |
| #endif | |
| #ifdef SSL_R_INVALID_SERVERINFO_DATA | |
| {"INVALID_SERVERINFO_DATA", ERR_LIB_SSL, SSL_R_INVALID_SERVERINFO_DATA}, | |
| #else | |
| {"INVALID_SERVERINFO_DATA", 20, 388}, | |
| #endif | |
| #ifdef SSL_R_INVALID_SESSION_ID | |
| {"INVALID_SESSION_ID", ERR_LIB_SSL, SSL_R_INVALID_SESSION_ID}, | |
| #else | |
| {"INVALID_SESSION_ID", 20, 999}, | |
| #endif | |
| #ifdef SSL_R_INVALID_SRP_USERNAME | |
| {"INVALID_SRP_USERNAME", ERR_LIB_SSL, SSL_R_INVALID_SRP_USERNAME}, | |
| #else | |
| {"INVALID_SRP_USERNAME", 20, 357}, | |
| #endif | |
| #ifdef SSL_R_INVALID_STATUS_RESPONSE | |
| {"INVALID_STATUS_RESPONSE", ERR_LIB_SSL, SSL_R_INVALID_STATUS_RESPONSE}, | |
| #else | |
| {"INVALID_STATUS_RESPONSE", 20, 328}, | |
| #endif | |
| #ifdef SSL_R_INVALID_TICKET_KEYS_LENGTH | |
| {"INVALID_TICKET_KEYS_LENGTH", ERR_LIB_SSL, SSL_R_INVALID_TICKET_KEYS_LENGTH}, | |
| #else | |
| {"INVALID_TICKET_KEYS_LENGTH", 20, 325}, | |
| #endif | |
| #ifdef SSL_R_LEGACY_SIGALG_DISALLOWED_OR_UNSUPPORTED | |
| {"LEGACY_SIGALG_DISALLOWED_OR_UNSUPPORTED", ERR_LIB_SSL, SSL_R_LEGACY_SIGALG_DISALLOWED_OR_UNSUPPORTED}, | |
| #else | |
| {"LEGACY_SIGALG_DISALLOWED_OR_UNSUPPORTED", 20, 333}, | |
| #endif | |
| #ifdef SSL_R_LENGTH_MISMATCH | |
| {"LENGTH_MISMATCH", ERR_LIB_SSL, SSL_R_LENGTH_MISMATCH}, | |
| #else | |
| {"LENGTH_MISMATCH", 20, 159}, | |
| #endif | |
| #ifdef SSL_R_LENGTH_TOO_LONG | |
| {"LENGTH_TOO_LONG", ERR_LIB_SSL, SSL_R_LENGTH_TOO_LONG}, | |
| #else | |
| {"LENGTH_TOO_LONG", 20, 404}, | |
| #endif | |
| #ifdef SSL_R_LENGTH_TOO_SHORT | |
| {"LENGTH_TOO_SHORT", ERR_LIB_SSL, SSL_R_LENGTH_TOO_SHORT}, | |
| #else | |
| {"LENGTH_TOO_SHORT", 20, 160}, | |
| #endif | |
| #ifdef SSL_R_LIBRARY_BUG | |
| {"LIBRARY_BUG", ERR_LIB_SSL, SSL_R_LIBRARY_BUG}, | |
| #else | |
| {"LIBRARY_BUG", 20, 274}, | |
| #endif | |
| #ifdef SSL_R_LIBRARY_HAS_NO_CIPHERS | |
| {"LIBRARY_HAS_NO_CIPHERS", ERR_LIB_SSL, SSL_R_LIBRARY_HAS_NO_CIPHERS}, | |
| #else | |
| {"LIBRARY_HAS_NO_CIPHERS", 20, 161}, | |
| #endif | |
| #ifdef SSL_R_LISTENER_USE_ONLY | |
| {"LISTENER_USE_ONLY", ERR_LIB_SSL, SSL_R_LISTENER_USE_ONLY}, | |
| #else | |
| {"LISTENER_USE_ONLY", 20, 421}, | |
| #endif | |
| #ifdef SSL_R_MAXIMUM_ENCRYPTED_PKTS_REACHED | |
| {"MAXIMUM_ENCRYPTED_PKTS_REACHED", ERR_LIB_SSL, SSL_R_MAXIMUM_ENCRYPTED_PKTS_REACHED}, | |
| #else | |
| {"MAXIMUM_ENCRYPTED_PKTS_REACHED", 20, 395}, | |
| #endif | |
| #ifdef SSL_R_MISSING_DSA_SIGNING_CERT | |
| {"MISSING_DSA_SIGNING_CERT", ERR_LIB_SSL, SSL_R_MISSING_DSA_SIGNING_CERT}, | |
| #else | |
| {"MISSING_DSA_SIGNING_CERT", 20, 165}, | |
| #endif | |
| #ifdef SSL_R_MISSING_ECDSA_SIGNING_CERT | |
| {"MISSING_ECDSA_SIGNING_CERT", ERR_LIB_SSL, SSL_R_MISSING_ECDSA_SIGNING_CERT}, | |
| #else | |
| {"MISSING_ECDSA_SIGNING_CERT", 20, 381}, | |
| #endif | |
| #ifdef SSL_R_MISSING_FATAL | |
| {"MISSING_FATAL", ERR_LIB_SSL, SSL_R_MISSING_FATAL}, | |
| #else | |
| {"MISSING_FATAL", 20, 256}, | |
| #endif | |
| #ifdef SSL_R_MISSING_PARAMETERS | |
| {"MISSING_PARAMETERS", ERR_LIB_SSL, SSL_R_MISSING_PARAMETERS}, | |
| #else | |
| {"MISSING_PARAMETERS", 20, 290}, | |
| #endif | |
| #ifdef SSL_R_MISSING_PSK_KEX_MODES_EXTENSION | |
| {"MISSING_PSK_KEX_MODES_EXTENSION", ERR_LIB_SSL, SSL_R_MISSING_PSK_KEX_MODES_EXTENSION}, | |
| #else | |
| {"MISSING_PSK_KEX_MODES_EXTENSION", 20, 310}, | |
| #endif | |
| #ifdef SSL_R_MISSING_QUIC_TLS_FUNCTIONS | |
| {"MISSING_QUIC_TLS_FUNCTIONS", ERR_LIB_SSL, SSL_R_MISSING_QUIC_TLS_FUNCTIONS}, | |
| #else | |
| {"MISSING_QUIC_TLS_FUNCTIONS", 20, 423}, | |
| #endif | |
| #ifdef SSL_R_MISSING_RSA_CERTIFICATE | |
| {"MISSING_RSA_CERTIFICATE", ERR_LIB_SSL, SSL_R_MISSING_RSA_CERTIFICATE}, | |
| #else | |
| {"MISSING_RSA_CERTIFICATE", 20, 168}, | |
| #endif | |
| #ifdef SSL_R_MISSING_RSA_ENCRYPTING_CERT | |
| {"MISSING_RSA_ENCRYPTING_CERT", ERR_LIB_SSL, SSL_R_MISSING_RSA_ENCRYPTING_CERT}, | |
| #else | |
| {"MISSING_RSA_ENCRYPTING_CERT", 20, 169}, | |
| #endif | |
| #ifdef SSL_R_MISSING_RSA_SIGNING_CERT | |
| {"MISSING_RSA_SIGNING_CERT", ERR_LIB_SSL, SSL_R_MISSING_RSA_SIGNING_CERT}, | |
| #else | |
| {"MISSING_RSA_SIGNING_CERT", 20, 170}, | |
| #endif | |
| #ifdef SSL_R_MISSING_SIGALGS_EXTENSION | |
| {"MISSING_SIGALGS_EXTENSION", ERR_LIB_SSL, SSL_R_MISSING_SIGALGS_EXTENSION}, | |
| #else | |
| {"MISSING_SIGALGS_EXTENSION", 20, 112}, | |
| #endif | |
| #ifdef SSL_R_MISSING_SIGNING_CERT | |
| {"MISSING_SIGNING_CERT", ERR_LIB_SSL, SSL_R_MISSING_SIGNING_CERT}, | |
| #else | |
| {"MISSING_SIGNING_CERT", 20, 221}, | |
| #endif | |
| #ifdef SSL_R_MISSING_SRP_PARAM | |
| {"MISSING_SRP_PARAM", ERR_LIB_SSL, SSL_R_MISSING_SRP_PARAM}, | |
| #else | |
| {"MISSING_SRP_PARAM", 20, 358}, | |
| #endif | |
| #ifdef SSL_R_MISSING_SUPPORTED_GROUPS_EXTENSION | |
| {"MISSING_SUPPORTED_GROUPS_EXTENSION", ERR_LIB_SSL, SSL_R_MISSING_SUPPORTED_GROUPS_EXTENSION}, | |
| #else | |
| {"MISSING_SUPPORTED_GROUPS_EXTENSION", 20, 209}, | |
| #endif | |
| #ifdef SSL_R_MISSING_SUPPORTED_VERSIONS_EXTENSION | |
| {"MISSING_SUPPORTED_VERSIONS_EXTENSION", ERR_LIB_SSL, SSL_R_MISSING_SUPPORTED_VERSIONS_EXTENSION}, | |
| #else | |
| {"MISSING_SUPPORTED_VERSIONS_EXTENSION", 20, 420}, | |
| #endif | |
| #ifdef SSL_R_MISSING_TMP_DH_KEY | |
| {"MISSING_TMP_DH_KEY", ERR_LIB_SSL, SSL_R_MISSING_TMP_DH_KEY}, | |
| #else | |
| {"MISSING_TMP_DH_KEY", 20, 171}, | |
| #endif | |
| #ifdef SSL_R_MISSING_TMP_ECDH_KEY | |
| {"MISSING_TMP_ECDH_KEY", ERR_LIB_SSL, SSL_R_MISSING_TMP_ECDH_KEY}, | |
| #else | |
| {"MISSING_TMP_ECDH_KEY", 20, 311}, | |
| #endif | |
| #ifdef SSL_R_MIXED_HANDSHAKE_AND_NON_HANDSHAKE_DATA | |
| {"MIXED_HANDSHAKE_AND_NON_HANDSHAKE_DATA", ERR_LIB_SSL, SSL_R_MIXED_HANDSHAKE_AND_NON_HANDSHAKE_DATA}, | |
| #else | |
| {"MIXED_HANDSHAKE_AND_NON_HANDSHAKE_DATA", 20, 293}, | |
| #endif | |
| #ifdef SSL_R_NOT_ON_RECORD_BOUNDARY | |
| {"NOT_ON_RECORD_BOUNDARY", ERR_LIB_SSL, SSL_R_NOT_ON_RECORD_BOUNDARY}, | |
| #else | |
| {"NOT_ON_RECORD_BOUNDARY", 20, 182}, | |
| #endif | |
| #ifdef SSL_R_NOT_REPLACING_CERTIFICATE | |
| {"NOT_REPLACING_CERTIFICATE", ERR_LIB_SSL, SSL_R_NOT_REPLACING_CERTIFICATE}, | |
| #else | |
| {"NOT_REPLACING_CERTIFICATE", 20, 289}, | |
| #endif | |
| #ifdef SSL_R_NOT_SERVER | |
| {"NOT_SERVER", ERR_LIB_SSL, SSL_R_NOT_SERVER}, | |
| #else | |
| {"NOT_SERVER", 20, 284}, | |
| #endif | |
| #ifdef SSL_R_NO_APPLICATION_PROTOCOL | |
| {"NO_APPLICATION_PROTOCOL", ERR_LIB_SSL, SSL_R_NO_APPLICATION_PROTOCOL}, | |
| #else | |
| {"NO_APPLICATION_PROTOCOL", 20, 235}, | |
| #endif | |
| #ifdef SSL_R_NO_CERTIFICATES_RETURNED | |
| {"NO_CERTIFICATES_RETURNED", ERR_LIB_SSL, SSL_R_NO_CERTIFICATES_RETURNED}, | |
| #else | |
| {"NO_CERTIFICATES_RETURNED", 20, 176}, | |
| #endif | |
| #ifdef SSL_R_NO_CERTIFICATE_ASSIGNED | |
| {"NO_CERTIFICATE_ASSIGNED", ERR_LIB_SSL, SSL_R_NO_CERTIFICATE_ASSIGNED}, | |
| #else | |
| {"NO_CERTIFICATE_ASSIGNED", 20, 177}, | |
| #endif | |
| #ifdef SSL_R_NO_CERTIFICATE_SET | |
| {"NO_CERTIFICATE_SET", ERR_LIB_SSL, SSL_R_NO_CERTIFICATE_SET}, | |
| #else | |
| {"NO_CERTIFICATE_SET", 20, 179}, | |
| #endif | |
| #ifdef SSL_R_NO_CHANGE_FOLLOWING_HRR | |
| {"NO_CHANGE_FOLLOWING_HRR", ERR_LIB_SSL, SSL_R_NO_CHANGE_FOLLOWING_HRR}, | |
| #else | |
| {"NO_CHANGE_FOLLOWING_HRR", 20, 214}, | |
| #endif | |
| #ifdef SSL_R_NO_CIPHERS_AVAILABLE | |
| {"NO_CIPHERS_AVAILABLE", ERR_LIB_SSL, SSL_R_NO_CIPHERS_AVAILABLE}, | |
| #else | |
| {"NO_CIPHERS_AVAILABLE", 20, 181}, | |
| #endif | |
| #ifdef SSL_R_NO_CIPHERS_SPECIFIED | |
| {"NO_CIPHERS_SPECIFIED", ERR_LIB_SSL, SSL_R_NO_CIPHERS_SPECIFIED}, | |
| #else | |
| {"NO_CIPHERS_SPECIFIED", 20, 183}, | |
| #endif | |
| #ifdef SSL_R_NO_CIPHER_MATCH | |
| {"NO_CIPHER_MATCH", ERR_LIB_SSL, SSL_R_NO_CIPHER_MATCH}, | |
| #else | |
| {"NO_CIPHER_MATCH", 20, 185}, | |
| #endif | |
| #ifdef SSL_R_NO_CLIENT_CERT_METHOD | |
| {"NO_CLIENT_CERT_METHOD", ERR_LIB_SSL, SSL_R_NO_CLIENT_CERT_METHOD}, | |
| #else | |
| {"NO_CLIENT_CERT_METHOD", 20, 331}, | |
| #endif | |
| #ifdef SSL_R_NO_COMPRESSION_SPECIFIED | |
| {"NO_COMPRESSION_SPECIFIED", ERR_LIB_SSL, SSL_R_NO_COMPRESSION_SPECIFIED}, | |
| #else | |
| {"NO_COMPRESSION_SPECIFIED", 20, 187}, | |
| #endif | |
| #ifdef SSL_R_NO_COOKIE_CALLBACK_SET | |
| {"NO_COOKIE_CALLBACK_SET", ERR_LIB_SSL, SSL_R_NO_COOKIE_CALLBACK_SET}, | |
| #else | |
| {"NO_COOKIE_CALLBACK_SET", 20, 287}, | |
| #endif | |
| #ifdef SSL_R_NO_GOST_CERTIFICATE_SENT_BY_PEER | |
| {"NO_GOST_CERTIFICATE_SENT_BY_PEER", ERR_LIB_SSL, SSL_R_NO_GOST_CERTIFICATE_SENT_BY_PEER}, | |
| #else | |
| {"NO_GOST_CERTIFICATE_SENT_BY_PEER", 20, 330}, | |
| #endif | |
| #ifdef SSL_R_NO_METHOD_SPECIFIED | |
| {"NO_METHOD_SPECIFIED", ERR_LIB_SSL, SSL_R_NO_METHOD_SPECIFIED}, | |
| #else | |
| {"NO_METHOD_SPECIFIED", 20, 188}, | |
| #endif | |
| #ifdef SSL_R_NO_PEM_EXTENSIONS | |
| {"NO_PEM_EXTENSIONS", ERR_LIB_SSL, SSL_R_NO_PEM_EXTENSIONS}, | |
| #else | |
| {"NO_PEM_EXTENSIONS", 20, 389}, | |
| #endif | |
| #ifdef SSL_R_NO_PRIVATE_KEY_ASSIGNED | |
| {"NO_PRIVATE_KEY_ASSIGNED", ERR_LIB_SSL, SSL_R_NO_PRIVATE_KEY_ASSIGNED}, | |
| #else | |
| {"NO_PRIVATE_KEY_ASSIGNED", 20, 190}, | |
| #endif | |
| #ifdef SSL_R_NO_PROTOCOLS_AVAILABLE | |
| {"NO_PROTOCOLS_AVAILABLE", ERR_LIB_SSL, SSL_R_NO_PROTOCOLS_AVAILABLE}, | |
| #else | |
| {"NO_PROTOCOLS_AVAILABLE", 20, 191}, | |
| #endif | |
| #ifdef SSL_R_NO_RENEGOTIATION | |
| {"NO_RENEGOTIATION", ERR_LIB_SSL, SSL_R_NO_RENEGOTIATION}, | |
| #else | |
| {"NO_RENEGOTIATION", 20, 339}, | |
| #endif | |
| #ifdef SSL_R_NO_REQUIRED_DIGEST | |
| {"NO_REQUIRED_DIGEST", ERR_LIB_SSL, SSL_R_NO_REQUIRED_DIGEST}, | |
| #else | |
| {"NO_REQUIRED_DIGEST", 20, 324}, | |
| #endif | |
| #ifdef SSL_R_NO_SHARED_CIPHER | |
| {"NO_SHARED_CIPHER", ERR_LIB_SSL, SSL_R_NO_SHARED_CIPHER}, | |
| #else | |
| {"NO_SHARED_CIPHER", 20, 193}, | |
| #endif | |
| #ifdef SSL_R_NO_SHARED_GROUPS | |
| {"NO_SHARED_GROUPS", ERR_LIB_SSL, SSL_R_NO_SHARED_GROUPS}, | |
| #else | |
| {"NO_SHARED_GROUPS", 20, 410}, | |
| #endif | |
| #ifdef SSL_R_NO_SHARED_SIGNATURE_ALGORITHMS | |
| {"NO_SHARED_SIGNATURE_ALGORITHMS", ERR_LIB_SSL, SSL_R_NO_SHARED_SIGNATURE_ALGORITHMS}, | |
| #else | |
| {"NO_SHARED_SIGNATURE_ALGORITHMS", 20, 376}, | |
| #endif | |
| #ifdef SSL_R_NO_SRTP_PROFILES | |
| {"NO_SRTP_PROFILES", ERR_LIB_SSL, SSL_R_NO_SRTP_PROFILES}, | |
| #else | |
| {"NO_SRTP_PROFILES", 20, 359}, | |
| #endif | |
| #ifdef SSL_R_NO_STREAM | |
| {"NO_STREAM", ERR_LIB_SSL, SSL_R_NO_STREAM}, | |
| #else | |
| {"NO_STREAM", 20, 355}, | |
| #endif | |
| #ifdef SSL_R_NO_SUITABLE_DIGEST_ALGORITHM | |
| {"NO_SUITABLE_DIGEST_ALGORITHM", ERR_LIB_SSL, SSL_R_NO_SUITABLE_DIGEST_ALGORITHM}, | |
| #else | |
| {"NO_SUITABLE_DIGEST_ALGORITHM", 20, 297}, | |
| #endif | |
| #ifdef SSL_R_NO_SUITABLE_GROUPS | |
| {"NO_SUITABLE_GROUPS", ERR_LIB_SSL, SSL_R_NO_SUITABLE_GROUPS}, | |
| #else | |
| {"NO_SUITABLE_GROUPS", 20, 295}, | |
| #endif | |
| #ifdef SSL_R_NO_SUITABLE_KEY_SHARE | |
| {"NO_SUITABLE_KEY_SHARE", ERR_LIB_SSL, SSL_R_NO_SUITABLE_KEY_SHARE}, | |
| #else | |
| {"NO_SUITABLE_KEY_SHARE", 20, 101}, | |
| #endif | |
| #ifdef SSL_R_NO_SUITABLE_RECORD_LAYER | |
| {"NO_SUITABLE_RECORD_LAYER", ERR_LIB_SSL, SSL_R_NO_SUITABLE_RECORD_LAYER}, | |
| #else | |
| {"NO_SUITABLE_RECORD_LAYER", 20, 322}, | |
| #endif | |
| #ifdef SSL_R_NO_SUITABLE_SIGNATURE_ALGORITHM | |
| {"NO_SUITABLE_SIGNATURE_ALGORITHM", ERR_LIB_SSL, SSL_R_NO_SUITABLE_SIGNATURE_ALGORITHM}, | |
| #else | |
| {"NO_SUITABLE_SIGNATURE_ALGORITHM", 20, 118}, | |
| #endif | |
| #ifdef SSL_R_NO_VALID_SCTS | |
| {"NO_VALID_SCTS", ERR_LIB_SSL, SSL_R_NO_VALID_SCTS}, | |
| #else | |
| {"NO_VALID_SCTS", 20, 216}, | |
| #endif | |
| #ifdef SSL_R_NO_VERIFY_COOKIE_CALLBACK | |
| {"NO_VERIFY_COOKIE_CALLBACK", ERR_LIB_SSL, SSL_R_NO_VERIFY_COOKIE_CALLBACK}, | |
| #else | |
| {"NO_VERIFY_COOKIE_CALLBACK", 20, 403}, | |
| #endif | |
| #ifdef SSL_R_NULL_SSL_CTX | |
| {"NULL_SSL_CTX", ERR_LIB_SSL, SSL_R_NULL_SSL_CTX}, | |
| #else | |
| {"NULL_SSL_CTX", 20, 195}, | |
| #endif | |
| #ifdef SSL_R_NULL_SSL_METHOD_PASSED | |
| {"NULL_SSL_METHOD_PASSED", ERR_LIB_SSL, SSL_R_NULL_SSL_METHOD_PASSED}, | |
| #else | |
| {"NULL_SSL_METHOD_PASSED", 20, 196}, | |
| #endif | |
| #ifdef SSL_R_OCSP_CALLBACK_FAILURE | |
| {"OCSP_CALLBACK_FAILURE", ERR_LIB_SSL, SSL_R_OCSP_CALLBACK_FAILURE}, | |
| #else | |
| {"OCSP_CALLBACK_FAILURE", 20, 305}, | |
| #endif | |
| #ifdef SSL_R_OLD_SESSION_CIPHER_NOT_RETURNED | |
| {"OLD_SESSION_CIPHER_NOT_RETURNED", ERR_LIB_SSL, SSL_R_OLD_SESSION_CIPHER_NOT_RETURNED}, | |
| #else | |
| {"OLD_SESSION_CIPHER_NOT_RETURNED", 20, 197}, | |
| #endif | |
| #ifdef SSL_R_OLD_SESSION_COMPRESSION_ALGORITHM_NOT_RETURNED | |
| {"OLD_SESSION_COMPRESSION_ALGORITHM_NOT_RETURNED", ERR_LIB_SSL, SSL_R_OLD_SESSION_COMPRESSION_ALGORITHM_NOT_RETURNED}, | |
| #else | |
| {"OLD_SESSION_COMPRESSION_ALGORITHM_NOT_RETURNED", 20, 344}, | |
| #endif | |
| #ifdef SSL_R_OVERFLOW_ERROR | |
| {"OVERFLOW_ERROR", ERR_LIB_SSL, SSL_R_OVERFLOW_ERROR}, | |
| #else | |
| {"OVERFLOW_ERROR", 20, 237}, | |
| #endif | |
| #ifdef SSL_R_PACKET_LENGTH_TOO_LONG | |
| {"PACKET_LENGTH_TOO_LONG", ERR_LIB_SSL, SSL_R_PACKET_LENGTH_TOO_LONG}, | |
| #else | |
| {"PACKET_LENGTH_TOO_LONG", 20, 198}, | |
| #endif | |
| #ifdef SSL_R_PARSE_TLSEXT | |
| {"PARSE_TLSEXT", ERR_LIB_SSL, SSL_R_PARSE_TLSEXT}, | |
| #else | |
| {"PARSE_TLSEXT", 20, 227}, | |
| #endif | |
| #ifdef SSL_R_PATH_TOO_LONG | |
| {"PATH_TOO_LONG", ERR_LIB_SSL, SSL_R_PATH_TOO_LONG}, | |
| #else | |
| {"PATH_TOO_LONG", 20, 270}, | |
| #endif | |
| #ifdef SSL_R_PEER_DID_NOT_RETURN_A_CERTIFICATE | |
| {"PEER_DID_NOT_RETURN_A_CERTIFICATE", ERR_LIB_SSL, SSL_R_PEER_DID_NOT_RETURN_A_CERTIFICATE}, | |
| #else | |
| {"PEER_DID_NOT_RETURN_A_CERTIFICATE", 20, 199}, | |
| #endif | |
| #ifdef SSL_R_PEM_NAME_BAD_PREFIX | |
| {"PEM_NAME_BAD_PREFIX", ERR_LIB_SSL, SSL_R_PEM_NAME_BAD_PREFIX}, | |
| #else | |
| {"PEM_NAME_BAD_PREFIX", 20, 391}, | |
| #endif | |
| #ifdef SSL_R_PEM_NAME_TOO_SHORT | |
| {"PEM_NAME_TOO_SHORT", ERR_LIB_SSL, SSL_R_PEM_NAME_TOO_SHORT}, | |
| #else | |
| {"PEM_NAME_TOO_SHORT", 20, 392}, | |
| #endif | |
| #ifdef SSL_R_PIPELINE_FAILURE | |
| {"PIPELINE_FAILURE", ERR_LIB_SSL, SSL_R_PIPELINE_FAILURE}, | |
| #else | |
| {"PIPELINE_FAILURE", 20, 406}, | |
| #endif | |
| #ifdef SSL_R_POLL_REQUEST_NOT_SUPPORTED | |
| {"POLL_REQUEST_NOT_SUPPORTED", ERR_LIB_SSL, SSL_R_POLL_REQUEST_NOT_SUPPORTED}, | |
| #else | |
| {"POLL_REQUEST_NOT_SUPPORTED", 20, 418}, | |
| #endif | |
| #ifdef SSL_R_POST_HANDSHAKE_AUTH_ENCODING_ERR | |
| {"POST_HANDSHAKE_AUTH_ENCODING_ERR", ERR_LIB_SSL, SSL_R_POST_HANDSHAKE_AUTH_ENCODING_ERR}, | |
| #else | |
| {"POST_HANDSHAKE_AUTH_ENCODING_ERR", 20, 278}, | |
| #endif | |
| #ifdef SSL_R_PRIVATE_KEY_MISMATCH | |
| {"PRIVATE_KEY_MISMATCH", ERR_LIB_SSL, SSL_R_PRIVATE_KEY_MISMATCH}, | |
| #else | |
| {"PRIVATE_KEY_MISMATCH", 20, 288}, | |
| #endif | |
| #ifdef SSL_R_PROTOCOL_IS_SHUTDOWN | |
| {"PROTOCOL_IS_SHUTDOWN", ERR_LIB_SSL, SSL_R_PROTOCOL_IS_SHUTDOWN}, | |
| #else | |
| {"PROTOCOL_IS_SHUTDOWN", 20, 207}, | |
| #endif | |
| #ifdef SSL_R_PSK_IDENTITY_NOT_FOUND | |
| {"PSK_IDENTITY_NOT_FOUND", ERR_LIB_SSL, SSL_R_PSK_IDENTITY_NOT_FOUND}, | |
| #else | |
| {"PSK_IDENTITY_NOT_FOUND", 20, 223}, | |
| #endif | |
| #ifdef SSL_R_PSK_NO_CLIENT_CB | |
| {"PSK_NO_CLIENT_CB", ERR_LIB_SSL, SSL_R_PSK_NO_CLIENT_CB}, | |
| #else | |
| {"PSK_NO_CLIENT_CB", 20, 224}, | |
| #endif | |
| #ifdef SSL_R_PSK_NO_SERVER_CB | |
| {"PSK_NO_SERVER_CB", ERR_LIB_SSL, SSL_R_PSK_NO_SERVER_CB}, | |
| #else | |
| {"PSK_NO_SERVER_CB", 20, 225}, | |
| #endif | |
| #ifdef SSL_R_QUIC_HANDSHAKE_LAYER_ERROR | |
| {"QUIC_HANDSHAKE_LAYER_ERROR", ERR_LIB_SSL, SSL_R_QUIC_HANDSHAKE_LAYER_ERROR}, | |
| #else | |
| {"QUIC_HANDSHAKE_LAYER_ERROR", 20, 393}, | |
| #endif | |
| #ifdef SSL_R_QUIC_NETWORK_ERROR | |
| {"QUIC_NETWORK_ERROR", ERR_LIB_SSL, SSL_R_QUIC_NETWORK_ERROR}, | |
| #else | |
| {"QUIC_NETWORK_ERROR", 20, 387}, | |
| #endif | |
| #ifdef SSL_R_QUIC_PROTOCOL_ERROR | |
| {"QUIC_PROTOCOL_ERROR", ERR_LIB_SSL, SSL_R_QUIC_PROTOCOL_ERROR}, | |
| #else | |
| {"QUIC_PROTOCOL_ERROR", 20, 382}, | |
| #endif | |
| #ifdef SSL_R_READ_BIO_NOT_SET | |
| {"READ_BIO_NOT_SET", ERR_LIB_SSL, SSL_R_READ_BIO_NOT_SET}, | |
| #else | |
| {"READ_BIO_NOT_SET", 20, 211}, | |
| #endif | |
| #ifdef SSL_R_READ_TIMEOUT_EXPIRED | |
| {"READ_TIMEOUT_EXPIRED", ERR_LIB_SSL, SSL_R_READ_TIMEOUT_EXPIRED}, | |
| #else | |
| {"READ_TIMEOUT_EXPIRED", 20, 312}, | |
| #endif | |
| #ifdef SSL_R_RECORDS_NOT_RELEASED | |
| {"RECORDS_NOT_RELEASED", ERR_LIB_SSL, SSL_R_RECORDS_NOT_RELEASED}, | |
| #else | |
| {"RECORDS_NOT_RELEASED", 20, 321}, | |
| #endif | |
| #ifdef SSL_R_RECORD_LAYER_FAILURE | |
| {"RECORD_LAYER_FAILURE", ERR_LIB_SSL, SSL_R_RECORD_LAYER_FAILURE}, | |
| #else | |
| {"RECORD_LAYER_FAILURE", 20, 313}, | |
| #endif | |
| #ifdef SSL_R_RECORD_LENGTH_MISMATCH | |
| {"RECORD_LENGTH_MISMATCH", ERR_LIB_SSL, SSL_R_RECORD_LENGTH_MISMATCH}, | |
| #else | |
| {"RECORD_LENGTH_MISMATCH", 20, 213}, | |
| #endif | |
| #ifdef SSL_R_RECORD_TOO_SMALL | |
| {"RECORD_TOO_SMALL", ERR_LIB_SSL, SSL_R_RECORD_TOO_SMALL}, | |
| #else | |
| {"RECORD_TOO_SMALL", 20, 298}, | |
| #endif | |
| #ifdef SSL_R_REMOTE_PEER_ADDRESS_NOT_SET | |
| {"REMOTE_PEER_ADDRESS_NOT_SET", ERR_LIB_SSL, SSL_R_REMOTE_PEER_ADDRESS_NOT_SET}, | |
| #else | |
| {"REMOTE_PEER_ADDRESS_NOT_SET", 20, 346}, | |
| #endif | |
| #ifdef SSL_R_RENEGOTIATE_EXT_TOO_LONG | |
| {"RENEGOTIATE_EXT_TOO_LONG", ERR_LIB_SSL, SSL_R_RENEGOTIATE_EXT_TOO_LONG}, | |
| #else | |
| {"RENEGOTIATE_EXT_TOO_LONG", 20, 335}, | |
| #endif | |
| #ifdef SSL_R_RENEGOTIATION_ENCODING_ERR | |
| {"RENEGOTIATION_ENCODING_ERR", ERR_LIB_SSL, SSL_R_RENEGOTIATION_ENCODING_ERR}, | |
| #else | |
| {"RENEGOTIATION_ENCODING_ERR", 20, 336}, | |
| #endif | |
| #ifdef SSL_R_RENEGOTIATION_MISMATCH | |
| {"RENEGOTIATION_MISMATCH", ERR_LIB_SSL, SSL_R_RENEGOTIATION_MISMATCH}, | |
| #else | |
| {"RENEGOTIATION_MISMATCH", 20, 337}, | |
| #endif | |
| #ifdef SSL_R_REQUEST_PENDING | |
| {"REQUEST_PENDING", ERR_LIB_SSL, SSL_R_REQUEST_PENDING}, | |
| #else | |
| {"REQUEST_PENDING", 20, 285}, | |
| #endif | |
| #ifdef SSL_R_REQUEST_SENT | |
| {"REQUEST_SENT", ERR_LIB_SSL, SSL_R_REQUEST_SENT}, | |
| #else | |
| {"REQUEST_SENT", 20, 286}, | |
| #endif | |
| #ifdef SSL_R_REQUIRED_CIPHER_MISSING | |
| {"REQUIRED_CIPHER_MISSING", ERR_LIB_SSL, SSL_R_REQUIRED_CIPHER_MISSING}, | |
| #else | |
| {"REQUIRED_CIPHER_MISSING", 20, 215}, | |
| #endif | |
| #ifdef SSL_R_REQUIRED_COMPRESSION_ALGORITHM_MISSING | |
| {"REQUIRED_COMPRESSION_ALGORITHM_MISSING", ERR_LIB_SSL, SSL_R_REQUIRED_COMPRESSION_ALGORITHM_MISSING}, | |
| #else | |
| {"REQUIRED_COMPRESSION_ALGORITHM_MISSING", 20, 342}, | |
| #endif | |
| #ifdef SSL_R_SCSV_RECEIVED_WHEN_RENEGOTIATING | |
| {"SCSV_RECEIVED_WHEN_RENEGOTIATING", ERR_LIB_SSL, SSL_R_SCSV_RECEIVED_WHEN_RENEGOTIATING}, | |
| #else | |
| {"SCSV_RECEIVED_WHEN_RENEGOTIATING", 20, 345}, | |
| #endif | |
| #ifdef SSL_R_SCT_VERIFICATION_FAILED | |
| {"SCT_VERIFICATION_FAILED", ERR_LIB_SSL, SSL_R_SCT_VERIFICATION_FAILED}, | |
| #else | |
| {"SCT_VERIFICATION_FAILED", 20, 208}, | |
| #endif | |
| #ifdef SSL_R_SEQUENCE_CTR_WRAPPED | |
| {"SEQUENCE_CTR_WRAPPED", ERR_LIB_SSL, SSL_R_SEQUENCE_CTR_WRAPPED}, | |
| #else | |
| {"SEQUENCE_CTR_WRAPPED", 20, 327}, | |
| #endif | |
| #ifdef SSL_R_SERVERHELLO_TLSEXT | |
| {"SERVERHELLO_TLSEXT", ERR_LIB_SSL, SSL_R_SERVERHELLO_TLSEXT}, | |
| #else | |
| {"SERVERHELLO_TLSEXT", 20, 275}, | |
| #endif | |
| #ifdef SSL_R_SESSION_ID_CONTEXT_UNINITIALIZED | |
| {"SESSION_ID_CONTEXT_UNINITIALIZED", ERR_LIB_SSL, SSL_R_SESSION_ID_CONTEXT_UNINITIALIZED}, | |
| #else | |
| {"SESSION_ID_CONTEXT_UNINITIALIZED", 20, 277}, | |
| #endif | |
| #ifdef SSL_R_SHUTDOWN_WHILE_IN_INIT | |
| {"SHUTDOWN_WHILE_IN_INIT", ERR_LIB_SSL, SSL_R_SHUTDOWN_WHILE_IN_INIT}, | |
| #else | |
| {"SHUTDOWN_WHILE_IN_INIT", 20, 407}, | |
| #endif | |
| #ifdef SSL_R_SIGNATURE_ALGORITHMS_ERROR | |
| {"SIGNATURE_ALGORITHMS_ERROR", ERR_LIB_SSL, SSL_R_SIGNATURE_ALGORITHMS_ERROR}, | |
| #else | |
| {"SIGNATURE_ALGORITHMS_ERROR", 20, 360}, | |
| #endif | |
| #ifdef SSL_R_SIGNATURE_FOR_NON_SIGNING_CERTIFICATE | |
| {"SIGNATURE_FOR_NON_SIGNING_CERTIFICATE", ERR_LIB_SSL, SSL_R_SIGNATURE_FOR_NON_SIGNING_CERTIFICATE}, | |
| #else | |
| {"SIGNATURE_FOR_NON_SIGNING_CERTIFICATE", 20, 220}, | |
| #endif | |
| #ifdef SSL_R_SRP_A_CALC | |
| {"SRP_A_CALC", ERR_LIB_SSL, SSL_R_SRP_A_CALC}, | |
| #else | |
| {"SRP_A_CALC", 20, 361}, | |
| #endif | |
| #ifdef SSL_R_SRTP_COULD_NOT_ALLOCATE_PROFILES | |
| {"SRTP_COULD_NOT_ALLOCATE_PROFILES", ERR_LIB_SSL, SSL_R_SRTP_COULD_NOT_ALLOCATE_PROFILES}, | |
| #else | |
| {"SRTP_COULD_NOT_ALLOCATE_PROFILES", 20, 362}, | |
| #endif | |
| #ifdef SSL_R_SRTP_PROTECTION_PROFILE_LIST_TOO_LONG | |
| {"SRTP_PROTECTION_PROFILE_LIST_TOO_LONG", ERR_LIB_SSL, SSL_R_SRTP_PROTECTION_PROFILE_LIST_TOO_LONG}, | |
| #else | |
| {"SRTP_PROTECTION_PROFILE_LIST_TOO_LONG", 20, 363}, | |
| #endif | |
| #ifdef SSL_R_SRTP_UNKNOWN_PROTECTION_PROFILE | |
| {"SRTP_UNKNOWN_PROTECTION_PROFILE", ERR_LIB_SSL, SSL_R_SRTP_UNKNOWN_PROTECTION_PROFILE}, | |
| #else | |
| {"SRTP_UNKNOWN_PROTECTION_PROFILE", 20, 364}, | |
| #endif | |
| #ifdef SSL_R_SSL3_EXT_INVALID_MAX_FRAGMENT_LENGTH | |
| {"SSL3_EXT_INVALID_MAX_FRAGMENT_LENGTH", ERR_LIB_SSL, SSL_R_SSL3_EXT_INVALID_MAX_FRAGMENT_LENGTH}, | |
| #else | |
| {"SSL3_EXT_INVALID_MAX_FRAGMENT_LENGTH", 20, 232}, | |
| #endif | |
| #ifdef SSL_R_SSL3_EXT_INVALID_SERVERNAME | |
| {"SSL3_EXT_INVALID_SERVERNAME", ERR_LIB_SSL, SSL_R_SSL3_EXT_INVALID_SERVERNAME}, | |
| #else | |
| {"SSL3_EXT_INVALID_SERVERNAME", 20, 319}, | |
| #endif | |
| #ifdef SSL_R_SSL3_EXT_INVALID_SERVERNAME_TYPE | |
| {"SSL3_EXT_INVALID_SERVERNAME_TYPE", ERR_LIB_SSL, SSL_R_SSL3_EXT_INVALID_SERVERNAME_TYPE}, | |
| #else | |
| {"SSL3_EXT_INVALID_SERVERNAME_TYPE", 20, 320}, | |
| #endif | |
| #ifdef SSL_R_SSL3_SESSION_ID_TOO_LONG | |
| {"SSL3_SESSION_ID_TOO_LONG", ERR_LIB_SSL, SSL_R_SSL3_SESSION_ID_TOO_LONG}, | |
| #else | |
| {"SSL3_SESSION_ID_TOO_LONG", 20, 300}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_BAD_CERTIFICATE | |
| {"SSLV3_ALERT_BAD_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_BAD_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_BAD_CERTIFICATE", 20, 1042}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_BAD_CERTIFICATE | |
| {"SSLV3_ALERT_BAD_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_BAD_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_BAD_CERTIFICATE", 20, 1042}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_BAD_RECORD_MAC | |
| {"SSLV3_ALERT_BAD_RECORD_MAC", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_BAD_RECORD_MAC}, | |
| #else | |
| {"SSLV3_ALERT_BAD_RECORD_MAC", 20, 1020}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_BAD_RECORD_MAC | |
| {"SSLV3_ALERT_BAD_RECORD_MAC", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_BAD_RECORD_MAC}, | |
| #else | |
| {"SSLV3_ALERT_BAD_RECORD_MAC", 20, 1020}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_EXPIRED | |
| {"SSLV3_ALERT_CERTIFICATE_EXPIRED", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_EXPIRED}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_EXPIRED", 20, 1045}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_EXPIRED | |
| {"SSLV3_ALERT_CERTIFICATE_EXPIRED", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_EXPIRED}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_EXPIRED", 20, 1045}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_REVOKED | |
| {"SSLV3_ALERT_CERTIFICATE_REVOKED", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_REVOKED}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_REVOKED", 20, 1044}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_REVOKED | |
| {"SSLV3_ALERT_CERTIFICATE_REVOKED", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_REVOKED}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_REVOKED", 20, 1044}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_UNKNOWN | |
| {"SSLV3_ALERT_CERTIFICATE_UNKNOWN", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_UNKNOWN}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_UNKNOWN", 20, 1046}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_CERTIFICATE_UNKNOWN | |
| {"SSLV3_ALERT_CERTIFICATE_UNKNOWN", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_CERTIFICATE_UNKNOWN}, | |
| #else | |
| {"SSLV3_ALERT_CERTIFICATE_UNKNOWN", 20, 1046}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_DECOMPRESSION_FAILURE | |
| {"SSLV3_ALERT_DECOMPRESSION_FAILURE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_DECOMPRESSION_FAILURE}, | |
| #else | |
| {"SSLV3_ALERT_DECOMPRESSION_FAILURE", 20, 1030}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_DECOMPRESSION_FAILURE | |
| {"SSLV3_ALERT_DECOMPRESSION_FAILURE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_DECOMPRESSION_FAILURE}, | |
| #else | |
| {"SSLV3_ALERT_DECOMPRESSION_FAILURE", 20, 1030}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_HANDSHAKE_FAILURE | |
| {"SSLV3_ALERT_HANDSHAKE_FAILURE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_HANDSHAKE_FAILURE}, | |
| #else | |
| {"SSLV3_ALERT_HANDSHAKE_FAILURE", 20, 1040}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_HANDSHAKE_FAILURE | |
| {"SSLV3_ALERT_HANDSHAKE_FAILURE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_HANDSHAKE_FAILURE}, | |
| #else | |
| {"SSLV3_ALERT_HANDSHAKE_FAILURE", 20, 1040}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_ILLEGAL_PARAMETER | |
| {"SSLV3_ALERT_ILLEGAL_PARAMETER", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_ILLEGAL_PARAMETER}, | |
| #else | |
| {"SSLV3_ALERT_ILLEGAL_PARAMETER", 20, 1047}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_ILLEGAL_PARAMETER | |
| {"SSLV3_ALERT_ILLEGAL_PARAMETER", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_ILLEGAL_PARAMETER}, | |
| #else | |
| {"SSLV3_ALERT_ILLEGAL_PARAMETER", 20, 1047}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_NO_CERTIFICATE | |
| {"SSLV3_ALERT_NO_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_NO_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_NO_CERTIFICATE", 20, 1041}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_NO_CERTIFICATE | |
| {"SSLV3_ALERT_NO_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_NO_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_NO_CERTIFICATE", 20, 1041}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_UNEXPECTED_MESSAGE | |
| {"SSLV3_ALERT_UNEXPECTED_MESSAGE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_UNEXPECTED_MESSAGE}, | |
| #else | |
| {"SSLV3_ALERT_UNEXPECTED_MESSAGE", 20, 1010}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_UNEXPECTED_MESSAGE | |
| {"SSLV3_ALERT_UNEXPECTED_MESSAGE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_UNEXPECTED_MESSAGE}, | |
| #else | |
| {"SSLV3_ALERT_UNEXPECTED_MESSAGE", 20, 1010}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_UNSUPPORTED_CERTIFICATE | |
| {"SSLV3_ALERT_UNSUPPORTED_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_UNSUPPORTED_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_UNSUPPORTED_CERTIFICATE", 20, 1043}, | |
| #endif | |
| #ifdef SSL_R_SSLV3_ALERT_UNSUPPORTED_CERTIFICATE | |
| {"SSLV3_ALERT_UNSUPPORTED_CERTIFICATE", ERR_LIB_SSL, SSL_R_SSLV3_ALERT_UNSUPPORTED_CERTIFICATE}, | |
| #else | |
| {"SSLV3_ALERT_UNSUPPORTED_CERTIFICATE", 20, 1043}, | |
| #endif | |
| #ifdef SSL_R_SSL_COMMAND_SECTION_EMPTY | |
| {"SSL_COMMAND_SECTION_EMPTY", ERR_LIB_SSL, SSL_R_SSL_COMMAND_SECTION_EMPTY}, | |
| #else | |
| {"SSL_COMMAND_SECTION_EMPTY", 20, 117}, | |
| #endif | |
| #ifdef SSL_R_SSL_COMMAND_SECTION_NOT_FOUND | |
| {"SSL_COMMAND_SECTION_NOT_FOUND", ERR_LIB_SSL, SSL_R_SSL_COMMAND_SECTION_NOT_FOUND}, | |
| #else | |
| {"SSL_COMMAND_SECTION_NOT_FOUND", 20, 125}, | |
| #endif | |
| #ifdef SSL_R_SSL_CTX_HAS_NO_DEFAULT_SSL_VERSION | |
| {"SSL_CTX_HAS_NO_DEFAULT_SSL_VERSION", ERR_LIB_SSL, SSL_R_SSL_CTX_HAS_NO_DEFAULT_SSL_VERSION}, | |
| #else | |
| {"SSL_CTX_HAS_NO_DEFAULT_SSL_VERSION", 20, 228}, | |
| #endif | |
| #ifdef SSL_R_SSL_HANDSHAKE_FAILURE | |
| {"SSL_HANDSHAKE_FAILURE", ERR_LIB_SSL, SSL_R_SSL_HANDSHAKE_FAILURE}, | |
| #else | |
| {"SSL_HANDSHAKE_FAILURE", 20, 229}, | |
| #endif | |
| #ifdef SSL_R_SSL_LIBRARY_HAS_NO_CIPHERS | |
| {"SSL_LIBRARY_HAS_NO_CIPHERS", ERR_LIB_SSL, SSL_R_SSL_LIBRARY_HAS_NO_CIPHERS}, | |
| #else | |
| {"SSL_LIBRARY_HAS_NO_CIPHERS", 20, 230}, | |
| #endif | |
| #ifdef SSL_R_SSL_NEGATIVE_LENGTH | |
| {"SSL_NEGATIVE_LENGTH", ERR_LIB_SSL, SSL_R_SSL_NEGATIVE_LENGTH}, | |
| #else | |
| {"SSL_NEGATIVE_LENGTH", 20, 372}, | |
| #endif | |
| #ifdef SSL_R_SSL_SECTION_EMPTY | |
| {"SSL_SECTION_EMPTY", ERR_LIB_SSL, SSL_R_SSL_SECTION_EMPTY}, | |
| #else | |
| {"SSL_SECTION_EMPTY", 20, 126}, | |
| #endif | |
| #ifdef SSL_R_SSL_SECTION_NOT_FOUND | |
| {"SSL_SECTION_NOT_FOUND", ERR_LIB_SSL, SSL_R_SSL_SECTION_NOT_FOUND}, | |
| #else | |
| {"SSL_SECTION_NOT_FOUND", 20, 136}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_ID_CALLBACK_FAILED | |
| {"SSL_SESSION_ID_CALLBACK_FAILED", ERR_LIB_SSL, SSL_R_SSL_SESSION_ID_CALLBACK_FAILED}, | |
| #else | |
| {"SSL_SESSION_ID_CALLBACK_FAILED", 20, 301}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_ID_CONFLICT | |
| {"SSL_SESSION_ID_CONFLICT", ERR_LIB_SSL, SSL_R_SSL_SESSION_ID_CONFLICT}, | |
| #else | |
| {"SSL_SESSION_ID_CONFLICT", 20, 302}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_ID_CONTEXT_TOO_LONG | |
| {"SSL_SESSION_ID_CONTEXT_TOO_LONG", ERR_LIB_SSL, SSL_R_SSL_SESSION_ID_CONTEXT_TOO_LONG}, | |
| #else | |
| {"SSL_SESSION_ID_CONTEXT_TOO_LONG", 20, 273}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_ID_HAS_BAD_LENGTH | |
| {"SSL_SESSION_ID_HAS_BAD_LENGTH", ERR_LIB_SSL, SSL_R_SSL_SESSION_ID_HAS_BAD_LENGTH}, | |
| #else | |
| {"SSL_SESSION_ID_HAS_BAD_LENGTH", 20, 303}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_ID_TOO_LONG | |
| {"SSL_SESSION_ID_TOO_LONG", ERR_LIB_SSL, SSL_R_SSL_SESSION_ID_TOO_LONG}, | |
| #else | |
| {"SSL_SESSION_ID_TOO_LONG", 20, 408}, | |
| #endif | |
| #ifdef SSL_R_SSL_SESSION_VERSION_MISMATCH | |
| {"SSL_SESSION_VERSION_MISMATCH", ERR_LIB_SSL, SSL_R_SSL_SESSION_VERSION_MISMATCH}, | |
| #else | |
| {"SSL_SESSION_VERSION_MISMATCH", 20, 210}, | |
| #endif | |
| #ifdef SSL_R_STILL_IN_INIT | |
| {"STILL_IN_INIT", ERR_LIB_SSL, SSL_R_STILL_IN_INIT}, | |
| #else | |
| {"STILL_IN_INIT", 20, 121}, | |
| #endif | |
| #ifdef SSL_R_STREAM_COUNT_LIMITED | |
| {"STREAM_COUNT_LIMITED", ERR_LIB_SSL, SSL_R_STREAM_COUNT_LIMITED}, | |
| #else | |
| {"STREAM_COUNT_LIMITED", 20, 411}, | |
| #endif | |
| #ifdef SSL_R_STREAM_FINISHED | |
| {"STREAM_FINISHED", ERR_LIB_SSL, SSL_R_STREAM_FINISHED}, | |
| #else | |
| {"STREAM_FINISHED", 20, 365}, | |
| #endif | |
| #ifdef SSL_R_STREAM_RECV_ONLY | |
| {"STREAM_RECV_ONLY", ERR_LIB_SSL, SSL_R_STREAM_RECV_ONLY}, | |
| #else | |
| {"STREAM_RECV_ONLY", 20, 366}, | |
| #endif | |
| #ifdef SSL_R_STREAM_RESET | |
| {"STREAM_RESET", ERR_LIB_SSL, SSL_R_STREAM_RESET}, | |
| #else | |
| {"STREAM_RESET", 20, 375}, | |
| #endif | |
| #ifdef SSL_R_STREAM_SEND_ONLY | |
| {"STREAM_SEND_ONLY", ERR_LIB_SSL, SSL_R_STREAM_SEND_ONLY}, | |
| #else | |
| {"STREAM_SEND_ONLY", 20, 379}, | |
| #endif | |
| #ifdef SSL_R_TLSV13_ALERT_CERTIFICATE_REQUIRED | |
| {"TLSV13_ALERT_CERTIFICATE_REQUIRED", ERR_LIB_SSL, SSL_R_TLSV13_ALERT_CERTIFICATE_REQUIRED}, | |
| #else | |
| {"TLSV13_ALERT_CERTIFICATE_REQUIRED", 20, 1116}, | |
| #endif | |
| #ifdef SSL_R_TLSV13_ALERT_CERTIFICATE_REQUIRED | |
| {"TLSV13_ALERT_CERTIFICATE_REQUIRED", ERR_LIB_SSL, SSL_R_TLSV13_ALERT_CERTIFICATE_REQUIRED}, | |
| #else | |
| {"TLSV13_ALERT_CERTIFICATE_REQUIRED", 20, 1116}, | |
| #endif | |
| #ifdef SSL_R_TLSV13_ALERT_MISSING_EXTENSION | |
| {"TLSV13_ALERT_MISSING_EXTENSION", ERR_LIB_SSL, SSL_R_TLSV13_ALERT_MISSING_EXTENSION}, | |
| #else | |
| {"TLSV13_ALERT_MISSING_EXTENSION", 20, 1109}, | |
| #endif | |
| #ifdef SSL_R_TLSV13_ALERT_MISSING_EXTENSION | |
| {"TLSV13_ALERT_MISSING_EXTENSION", ERR_LIB_SSL, SSL_R_TLSV13_ALERT_MISSING_EXTENSION}, | |
| #else | |
| {"TLSV13_ALERT_MISSING_EXTENSION", 20, 1109}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_ACCESS_DENIED | |
| {"TLSV1_ALERT_ACCESS_DENIED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_ACCESS_DENIED}, | |
| #else | |
| {"TLSV1_ALERT_ACCESS_DENIED", 20, 1049}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_ACCESS_DENIED | |
| {"TLSV1_ALERT_ACCESS_DENIED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_ACCESS_DENIED}, | |
| #else | |
| {"TLSV1_ALERT_ACCESS_DENIED", 20, 1049}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECODE_ERROR | |
| {"TLSV1_ALERT_DECODE_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECODE_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_DECODE_ERROR", 20, 1050}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECODE_ERROR | |
| {"TLSV1_ALERT_DECODE_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECODE_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_DECODE_ERROR", 20, 1050}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECRYPTION_FAILED | |
| {"TLSV1_ALERT_DECRYPTION_FAILED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECRYPTION_FAILED}, | |
| #else | |
| {"TLSV1_ALERT_DECRYPTION_FAILED", 20, 1021}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECRYPTION_FAILED | |
| {"TLSV1_ALERT_DECRYPTION_FAILED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECRYPTION_FAILED}, | |
| #else | |
| {"TLSV1_ALERT_DECRYPTION_FAILED", 20, 1021}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECRYPT_ERROR | |
| {"TLSV1_ALERT_DECRYPT_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECRYPT_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_DECRYPT_ERROR", 20, 1051}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_DECRYPT_ERROR | |
| {"TLSV1_ALERT_DECRYPT_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_DECRYPT_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_DECRYPT_ERROR", 20, 1051}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_EXPORT_RESTRICTION | |
| {"TLSV1_ALERT_EXPORT_RESTRICTION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_EXPORT_RESTRICTION}, | |
| #else | |
| {"TLSV1_ALERT_EXPORT_RESTRICTION", 20, 1060}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_EXPORT_RESTRICTION | |
| {"TLSV1_ALERT_EXPORT_RESTRICTION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_EXPORT_RESTRICTION}, | |
| #else | |
| {"TLSV1_ALERT_EXPORT_RESTRICTION", 20, 1060}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INAPPROPRIATE_FALLBACK | |
| {"TLSV1_ALERT_INAPPROPRIATE_FALLBACK", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INAPPROPRIATE_FALLBACK}, | |
| #else | |
| {"TLSV1_ALERT_INAPPROPRIATE_FALLBACK", 20, 1086}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INAPPROPRIATE_FALLBACK | |
| {"TLSV1_ALERT_INAPPROPRIATE_FALLBACK", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INAPPROPRIATE_FALLBACK}, | |
| #else | |
| {"TLSV1_ALERT_INAPPROPRIATE_FALLBACK", 20, 1086}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INSUFFICIENT_SECURITY | |
| {"TLSV1_ALERT_INSUFFICIENT_SECURITY", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INSUFFICIENT_SECURITY}, | |
| #else | |
| {"TLSV1_ALERT_INSUFFICIENT_SECURITY", 20, 1071}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INSUFFICIENT_SECURITY | |
| {"TLSV1_ALERT_INSUFFICIENT_SECURITY", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INSUFFICIENT_SECURITY}, | |
| #else | |
| {"TLSV1_ALERT_INSUFFICIENT_SECURITY", 20, 1071}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INTERNAL_ERROR | |
| {"TLSV1_ALERT_INTERNAL_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INTERNAL_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_INTERNAL_ERROR", 20, 1080}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_INTERNAL_ERROR | |
| {"TLSV1_ALERT_INTERNAL_ERROR", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_INTERNAL_ERROR}, | |
| #else | |
| {"TLSV1_ALERT_INTERNAL_ERROR", 20, 1080}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_NO_APPLICATION_PROTOCOL | |
| {"TLSV1_ALERT_NO_APPLICATION_PROTOCOL", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_NO_APPLICATION_PROTOCOL}, | |
| #else | |
| {"TLSV1_ALERT_NO_APPLICATION_PROTOCOL", 20, 1120}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_NO_APPLICATION_PROTOCOL | |
| {"TLSV1_ALERT_NO_APPLICATION_PROTOCOL", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_NO_APPLICATION_PROTOCOL}, | |
| #else | |
| {"TLSV1_ALERT_NO_APPLICATION_PROTOCOL", 20, 1120}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_NO_RENEGOTIATION | |
| {"TLSV1_ALERT_NO_RENEGOTIATION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_NO_RENEGOTIATION}, | |
| #else | |
| {"TLSV1_ALERT_NO_RENEGOTIATION", 20, 1100}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_NO_RENEGOTIATION | |
| {"TLSV1_ALERT_NO_RENEGOTIATION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_NO_RENEGOTIATION}, | |
| #else | |
| {"TLSV1_ALERT_NO_RENEGOTIATION", 20, 1100}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_PROTOCOL_VERSION | |
| {"TLSV1_ALERT_PROTOCOL_VERSION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_PROTOCOL_VERSION}, | |
| #else | |
| {"TLSV1_ALERT_PROTOCOL_VERSION", 20, 1070}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_PROTOCOL_VERSION | |
| {"TLSV1_ALERT_PROTOCOL_VERSION", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_PROTOCOL_VERSION}, | |
| #else | |
| {"TLSV1_ALERT_PROTOCOL_VERSION", 20, 1070}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_RECORD_OVERFLOW | |
| {"TLSV1_ALERT_RECORD_OVERFLOW", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_RECORD_OVERFLOW}, | |
| #else | |
| {"TLSV1_ALERT_RECORD_OVERFLOW", 20, 1022}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_RECORD_OVERFLOW | |
| {"TLSV1_ALERT_RECORD_OVERFLOW", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_RECORD_OVERFLOW}, | |
| #else | |
| {"TLSV1_ALERT_RECORD_OVERFLOW", 20, 1022}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_UNKNOWN_CA | |
| {"TLSV1_ALERT_UNKNOWN_CA", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_UNKNOWN_CA}, | |
| #else | |
| {"TLSV1_ALERT_UNKNOWN_CA", 20, 1048}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_UNKNOWN_CA | |
| {"TLSV1_ALERT_UNKNOWN_CA", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_UNKNOWN_CA}, | |
| #else | |
| {"TLSV1_ALERT_UNKNOWN_CA", 20, 1048}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_UNKNOWN_PSK_IDENTITY | |
| {"TLSV1_ALERT_UNKNOWN_PSK_IDENTITY", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_UNKNOWN_PSK_IDENTITY}, | |
| #else | |
| {"TLSV1_ALERT_UNKNOWN_PSK_IDENTITY", 20, 1115}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_UNKNOWN_PSK_IDENTITY | |
| {"TLSV1_ALERT_UNKNOWN_PSK_IDENTITY", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_UNKNOWN_PSK_IDENTITY}, | |
| #else | |
| {"TLSV1_ALERT_UNKNOWN_PSK_IDENTITY", 20, 1115}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_USER_CANCELLED | |
| {"TLSV1_ALERT_USER_CANCELLED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_USER_CANCELLED}, | |
| #else | |
| {"TLSV1_ALERT_USER_CANCELLED", 20, 1090}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_ALERT_USER_CANCELLED | |
| {"TLSV1_ALERT_USER_CANCELLED", ERR_LIB_SSL, SSL_R_TLSV1_ALERT_USER_CANCELLED}, | |
| #else | |
| {"TLSV1_ALERT_USER_CANCELLED", 20, 1090}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_BAD_CERTIFICATE_HASH_VALUE | |
| {"TLSV1_BAD_CERTIFICATE_HASH_VALUE", ERR_LIB_SSL, SSL_R_TLSV1_BAD_CERTIFICATE_HASH_VALUE}, | |
| #else | |
| {"TLSV1_BAD_CERTIFICATE_HASH_VALUE", 20, 1114}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_BAD_CERTIFICATE_HASH_VALUE | |
| {"TLSV1_BAD_CERTIFICATE_HASH_VALUE", ERR_LIB_SSL, SSL_R_TLSV1_BAD_CERTIFICATE_HASH_VALUE}, | |
| #else | |
| {"TLSV1_BAD_CERTIFICATE_HASH_VALUE", 20, 1114}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE | |
| {"TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE", ERR_LIB_SSL, SSL_R_TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE}, | |
| #else | |
| {"TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE", 20, 1113}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE | |
| {"TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE", ERR_LIB_SSL, SSL_R_TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE}, | |
| #else | |
| {"TLSV1_BAD_CERTIFICATE_STATUS_RESPONSE", 20, 1113}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_CERTIFICATE_UNOBTAINABLE | |
| {"TLSV1_CERTIFICATE_UNOBTAINABLE", ERR_LIB_SSL, SSL_R_TLSV1_CERTIFICATE_UNOBTAINABLE}, | |
| #else | |
| {"TLSV1_CERTIFICATE_UNOBTAINABLE", 20, 1111}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_CERTIFICATE_UNOBTAINABLE | |
| {"TLSV1_CERTIFICATE_UNOBTAINABLE", ERR_LIB_SSL, SSL_R_TLSV1_CERTIFICATE_UNOBTAINABLE}, | |
| #else | |
| {"TLSV1_CERTIFICATE_UNOBTAINABLE", 20, 1111}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_UNRECOGNIZED_NAME | |
| {"TLSV1_UNRECOGNIZED_NAME", ERR_LIB_SSL, SSL_R_TLSV1_UNRECOGNIZED_NAME}, | |
| #else | |
| {"TLSV1_UNRECOGNIZED_NAME", 20, 1112}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_UNRECOGNIZED_NAME | |
| {"TLSV1_UNRECOGNIZED_NAME", ERR_LIB_SSL, SSL_R_TLSV1_UNRECOGNIZED_NAME}, | |
| #else | |
| {"TLSV1_UNRECOGNIZED_NAME", 20, 1112}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_UNSUPPORTED_EXTENSION | |
| {"TLSV1_UNSUPPORTED_EXTENSION", ERR_LIB_SSL, SSL_R_TLSV1_UNSUPPORTED_EXTENSION}, | |
| #else | |
| {"TLSV1_UNSUPPORTED_EXTENSION", 20, 1110}, | |
| #endif | |
| #ifdef SSL_R_TLSV1_UNSUPPORTED_EXTENSION | |
| {"TLSV1_UNSUPPORTED_EXTENSION", ERR_LIB_SSL, SSL_R_TLSV1_UNSUPPORTED_EXTENSION}, | |
| #else | |
| {"TLSV1_UNSUPPORTED_EXTENSION", 20, 1110}, | |
| #endif | |
| #ifdef SSL_R_TLS_ILLEGAL_EXPORTER_LABEL | |
| {"TLS_ILLEGAL_EXPORTER_LABEL", ERR_LIB_SSL, SSL_R_TLS_ILLEGAL_EXPORTER_LABEL}, | |
| #else | |
| {"TLS_ILLEGAL_EXPORTER_LABEL", 20, 367}, | |
| #endif | |
| #ifdef SSL_R_TLS_INVALID_ECPOINTFORMAT_LIST | |
| {"TLS_INVALID_ECPOINTFORMAT_LIST", ERR_LIB_SSL, SSL_R_TLS_INVALID_ECPOINTFORMAT_LIST}, | |
| #else | |
| {"TLS_INVALID_ECPOINTFORMAT_LIST", 20, 157}, | |
| #endif | |
| #ifdef SSL_R_TOO_MANY_KEY_UPDATES | |
| {"TOO_MANY_KEY_UPDATES", ERR_LIB_SSL, SSL_R_TOO_MANY_KEY_UPDATES}, | |
| #else | |
| {"TOO_MANY_KEY_UPDATES", 20, 132}, | |
| #endif | |
| #ifdef SSL_R_TOO_MANY_WARN_ALERTS | |
| {"TOO_MANY_WARN_ALERTS", ERR_LIB_SSL, SSL_R_TOO_MANY_WARN_ALERTS}, | |
| #else | |
| {"TOO_MANY_WARN_ALERTS", 20, 409}, | |
| #endif | |
| #ifdef SSL_R_TOO_MUCH_EARLY_DATA | |
| {"TOO_MUCH_EARLY_DATA", ERR_LIB_SSL, SSL_R_TOO_MUCH_EARLY_DATA}, | |
| #else | |
| {"TOO_MUCH_EARLY_DATA", 20, 164}, | |
| #endif | |
| #ifdef SSL_R_UNABLE_TO_FIND_ECDH_PARAMETERS | |
| {"UNABLE_TO_FIND_ECDH_PARAMETERS", ERR_LIB_SSL, SSL_R_UNABLE_TO_FIND_ECDH_PARAMETERS}, | |
| #else | |
| {"UNABLE_TO_FIND_ECDH_PARAMETERS", 20, 314}, | |
| #endif | |
| #ifdef SSL_R_UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS | |
| {"UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS", ERR_LIB_SSL, SSL_R_UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS}, | |
| #else | |
| {"UNABLE_TO_FIND_PUBLIC_KEY_PARAMETERS", 20, 239}, | |
| #endif | |
| #ifdef SSL_R_UNABLE_TO_LOAD_SSL3_MD5_ROUTINES | |
| {"UNABLE_TO_LOAD_SSL3_MD5_ROUTINES", ERR_LIB_SSL, SSL_R_UNABLE_TO_LOAD_SSL3_MD5_ROUTINES}, | |
| #else | |
| {"UNABLE_TO_LOAD_SSL3_MD5_ROUTINES", 20, 242}, | |
| #endif | |
| #ifdef SSL_R_UNABLE_TO_LOAD_SSL3_SHA1_ROUTINES | |
| {"UNABLE_TO_LOAD_SSL3_SHA1_ROUTINES", ERR_LIB_SSL, SSL_R_UNABLE_TO_LOAD_SSL3_SHA1_ROUTINES}, | |
| #else | |
| {"UNABLE_TO_LOAD_SSL3_SHA1_ROUTINES", 20, 243}, | |
| #endif | |
| #ifdef SSL_R_UNEXPECTED_CCS_MESSAGE | |
| {"UNEXPECTED_CCS_MESSAGE", ERR_LIB_SSL, SSL_R_UNEXPECTED_CCS_MESSAGE}, | |
| #else | |
| {"UNEXPECTED_CCS_MESSAGE", 20, 262}, | |
| #endif | |
| #ifdef SSL_R_UNEXPECTED_END_OF_EARLY_DATA | |
| {"UNEXPECTED_END_OF_EARLY_DATA", ERR_LIB_SSL, SSL_R_UNEXPECTED_END_OF_EARLY_DATA}, | |
| #else | |
| {"UNEXPECTED_END_OF_EARLY_DATA", 20, 178}, | |
| #endif | |
| #ifdef SSL_R_UNEXPECTED_EOF_WHILE_READING | |
| {"UNEXPECTED_EOF_WHILE_READING", ERR_LIB_SSL, SSL_R_UNEXPECTED_EOF_WHILE_READING}, | |
| #else | |
| {"UNEXPECTED_EOF_WHILE_READING", 20, 294}, | |
| #endif | |
| #ifdef SSL_R_UNEXPECTED_MESSAGE | |
| {"UNEXPECTED_MESSAGE", ERR_LIB_SSL, SSL_R_UNEXPECTED_MESSAGE}, | |
| #else | |
| {"UNEXPECTED_MESSAGE", 20, 244}, | |
| #endif | |
| #ifdef SSL_R_UNEXPECTED_RECORD | |
| {"UNEXPECTED_RECORD", ERR_LIB_SSL, SSL_R_UNEXPECTED_RECORD}, | |
| #else | |
| {"UNEXPECTED_RECORD", 20, 245}, | |
| #endif | |
| #ifdef SSL_R_UNINITIALIZED | |
| {"UNINITIALIZED", ERR_LIB_SSL, SSL_R_UNINITIALIZED}, | |
| #else | |
| {"UNINITIALIZED", 20, 276}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_ALERT_TYPE | |
| {"UNKNOWN_ALERT_TYPE", ERR_LIB_SSL, SSL_R_UNKNOWN_ALERT_TYPE}, | |
| #else | |
| {"UNKNOWN_ALERT_TYPE", 20, 246}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_CERTIFICATE_TYPE | |
| {"UNKNOWN_CERTIFICATE_TYPE", ERR_LIB_SSL, SSL_R_UNKNOWN_CERTIFICATE_TYPE}, | |
| #else | |
| {"UNKNOWN_CERTIFICATE_TYPE", 20, 247}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_CIPHER_RETURNED | |
| {"UNKNOWN_CIPHER_RETURNED", ERR_LIB_SSL, SSL_R_UNKNOWN_CIPHER_RETURNED}, | |
| #else | |
| {"UNKNOWN_CIPHER_RETURNED", 20, 248}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_CIPHER_TYPE | |
| {"UNKNOWN_CIPHER_TYPE", ERR_LIB_SSL, SSL_R_UNKNOWN_CIPHER_TYPE}, | |
| #else | |
| {"UNKNOWN_CIPHER_TYPE", 20, 249}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_CMD_NAME | |
| {"UNKNOWN_CMD_NAME", ERR_LIB_SSL, SSL_R_UNKNOWN_CMD_NAME}, | |
| #else | |
| {"UNKNOWN_CMD_NAME", 20, 386}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_COMMAND | |
| {"UNKNOWN_COMMAND", ERR_LIB_SSL, SSL_R_UNKNOWN_COMMAND}, | |
| #else | |
| {"UNKNOWN_COMMAND", 20, 139}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_DIGEST | |
| {"UNKNOWN_DIGEST", ERR_LIB_SSL, SSL_R_UNKNOWN_DIGEST}, | |
| #else | |
| {"UNKNOWN_DIGEST", 20, 368}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_KEY_EXCHANGE_TYPE | |
| {"UNKNOWN_KEY_EXCHANGE_TYPE", ERR_LIB_SSL, SSL_R_UNKNOWN_KEY_EXCHANGE_TYPE}, | |
| #else | |
| {"UNKNOWN_KEY_EXCHANGE_TYPE", 20, 250}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_MANDATORY_PARAMETER | |
| {"UNKNOWN_MANDATORY_PARAMETER", ERR_LIB_SSL, SSL_R_UNKNOWN_MANDATORY_PARAMETER}, | |
| #else | |
| {"UNKNOWN_MANDATORY_PARAMETER", 20, 323}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_PKEY_TYPE | |
| {"UNKNOWN_PKEY_TYPE", ERR_LIB_SSL, SSL_R_UNKNOWN_PKEY_TYPE}, | |
| #else | |
| {"UNKNOWN_PKEY_TYPE", 20, 251}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_PROTOCOL | |
| {"UNKNOWN_PROTOCOL", ERR_LIB_SSL, SSL_R_UNKNOWN_PROTOCOL}, | |
| #else | |
| {"UNKNOWN_PROTOCOL", 20, 252}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_SSL_VERSION | |
| {"UNKNOWN_SSL_VERSION", ERR_LIB_SSL, SSL_R_UNKNOWN_SSL_VERSION}, | |
| #else | |
| {"UNKNOWN_SSL_VERSION", 20, 254}, | |
| #endif | |
| #ifdef SSL_R_UNKNOWN_STATE | |
| {"UNKNOWN_STATE", ERR_LIB_SSL, SSL_R_UNKNOWN_STATE}, | |
| #else | |
| {"UNKNOWN_STATE", 20, 255}, | |
| #endif | |
| #ifdef SSL_R_UNSAFE_LEGACY_RENEGOTIATION_DISABLED | |
| {"UNSAFE_LEGACY_RENEGOTIATION_DISABLED", ERR_LIB_SSL, SSL_R_UNSAFE_LEGACY_RENEGOTIATION_DISABLED}, | |
| #else | |
| {"UNSAFE_LEGACY_RENEGOTIATION_DISABLED", 20, 338}, | |
| #endif | |
| #ifdef SSL_R_UNSOLICITED_EXTENSION | |
| {"UNSOLICITED_EXTENSION", ERR_LIB_SSL, SSL_R_UNSOLICITED_EXTENSION}, | |
| #else | |
| {"UNSOLICITED_EXTENSION", 20, 217}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_COMPRESSION_ALGORITHM | |
| {"UNSUPPORTED_COMPRESSION_ALGORITHM", ERR_LIB_SSL, SSL_R_UNSUPPORTED_COMPRESSION_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_COMPRESSION_ALGORITHM", 20, 257}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_CONFIG_VALUE | |
| {"UNSUPPORTED_CONFIG_VALUE", ERR_LIB_SSL, SSL_R_UNSUPPORTED_CONFIG_VALUE}, | |
| #else | |
| {"UNSUPPORTED_CONFIG_VALUE", 20, 414}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_CONFIG_VALUE_CLASS | |
| {"UNSUPPORTED_CONFIG_VALUE_CLASS", ERR_LIB_SSL, SSL_R_UNSUPPORTED_CONFIG_VALUE_CLASS}, | |
| #else | |
| {"UNSUPPORTED_CONFIG_VALUE_CLASS", 20, 415}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_CONFIG_VALUE_OP | |
| {"UNSUPPORTED_CONFIG_VALUE_OP", ERR_LIB_SSL, SSL_R_UNSUPPORTED_CONFIG_VALUE_OP}, | |
| #else | |
| {"UNSUPPORTED_CONFIG_VALUE_OP", 20, 416}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_ELLIPTIC_CURVE | |
| {"UNSUPPORTED_ELLIPTIC_CURVE", ERR_LIB_SSL, SSL_R_UNSUPPORTED_ELLIPTIC_CURVE}, | |
| #else | |
| {"UNSUPPORTED_ELLIPTIC_CURVE", 20, 315}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_PROTOCOL | |
| {"UNSUPPORTED_PROTOCOL", ERR_LIB_SSL, SSL_R_UNSUPPORTED_PROTOCOL}, | |
| #else | |
| {"UNSUPPORTED_PROTOCOL", 20, 258}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_SSL_VERSION | |
| {"UNSUPPORTED_SSL_VERSION", ERR_LIB_SSL, SSL_R_UNSUPPORTED_SSL_VERSION}, | |
| #else | |
| {"UNSUPPORTED_SSL_VERSION", 20, 259}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_STATUS_TYPE | |
| {"UNSUPPORTED_STATUS_TYPE", ERR_LIB_SSL, SSL_R_UNSUPPORTED_STATUS_TYPE}, | |
| #else | |
| {"UNSUPPORTED_STATUS_TYPE", 20, 329}, | |
| #endif | |
| #ifdef SSL_R_UNSUPPORTED_WRITE_FLAG | |
| {"UNSUPPORTED_WRITE_FLAG", ERR_LIB_SSL, SSL_R_UNSUPPORTED_WRITE_FLAG}, | |
| #else | |
| {"UNSUPPORTED_WRITE_FLAG", 20, 412}, | |
| #endif | |
| #ifdef SSL_R_USE_SRTP_NOT_NEGOTIATED | |
| {"USE_SRTP_NOT_NEGOTIATED", ERR_LIB_SSL, SSL_R_USE_SRTP_NOT_NEGOTIATED}, | |
| #else | |
| {"USE_SRTP_NOT_NEGOTIATED", 20, 369}, | |
| #endif | |
| #ifdef SSL_R_VERSION_TOO_HIGH | |
| {"VERSION_TOO_HIGH", ERR_LIB_SSL, SSL_R_VERSION_TOO_HIGH}, | |
| #else | |
| {"VERSION_TOO_HIGH", 20, 166}, | |
| #endif | |
| #ifdef SSL_R_VERSION_TOO_LOW | |
| {"VERSION_TOO_LOW", ERR_LIB_SSL, SSL_R_VERSION_TOO_LOW}, | |
| #else | |
| {"VERSION_TOO_LOW", 20, 396}, | |
| #endif | |
| #ifdef SSL_R_WRONG_CERTIFICATE_TYPE | |
| {"WRONG_CERTIFICATE_TYPE", ERR_LIB_SSL, SSL_R_WRONG_CERTIFICATE_TYPE}, | |
| #else | |
| {"WRONG_CERTIFICATE_TYPE", 20, 383}, | |
| #endif | |
| #ifdef SSL_R_WRONG_CIPHER_RETURNED | |
| {"WRONG_CIPHER_RETURNED", ERR_LIB_SSL, SSL_R_WRONG_CIPHER_RETURNED}, | |
| #else | |
| {"WRONG_CIPHER_RETURNED", 20, 261}, | |
| #endif | |
| #ifdef SSL_R_WRONG_CURVE | |
| {"WRONG_CURVE", ERR_LIB_SSL, SSL_R_WRONG_CURVE}, | |
| #else | |
| {"WRONG_CURVE", 20, 378}, | |
| #endif | |
| #ifdef SSL_R_WRONG_RPK_TYPE | |
| {"WRONG_RPK_TYPE", ERR_LIB_SSL, SSL_R_WRONG_RPK_TYPE}, | |
| #else | |
| {"WRONG_RPK_TYPE", 20, 351}, | |
| #endif | |
| #ifdef SSL_R_WRONG_SIGNATURE_LENGTH | |
| {"WRONG_SIGNATURE_LENGTH", ERR_LIB_SSL, SSL_R_WRONG_SIGNATURE_LENGTH}, | |
| #else | |
| {"WRONG_SIGNATURE_LENGTH", 20, 264}, | |
| #endif | |
| #ifdef SSL_R_WRONG_SIGNATURE_SIZE | |
| {"WRONG_SIGNATURE_SIZE", ERR_LIB_SSL, SSL_R_WRONG_SIGNATURE_SIZE}, | |
| #else | |
| {"WRONG_SIGNATURE_SIZE", 20, 265}, | |
| #endif | |
| #ifdef SSL_R_WRONG_SIGNATURE_TYPE | |
| {"WRONG_SIGNATURE_TYPE", ERR_LIB_SSL, SSL_R_WRONG_SIGNATURE_TYPE}, | |
| #else | |
| {"WRONG_SIGNATURE_TYPE", 20, 370}, | |
| #endif | |
| #ifdef SSL_R_WRONG_SSL_VERSION | |
| {"WRONG_SSL_VERSION", ERR_LIB_SSL, SSL_R_WRONG_SSL_VERSION}, | |
| #else | |
| {"WRONG_SSL_VERSION", 20, 266}, | |
| #endif | |
| #ifdef SSL_R_WRONG_VERSION_NUMBER | |
| {"WRONG_VERSION_NUMBER", ERR_LIB_SSL, SSL_R_WRONG_VERSION_NUMBER}, | |
| #else | |
| {"WRONG_VERSION_NUMBER", 20, 267}, | |
| #endif | |
| #ifdef SSL_R_X509_LIB | |
| {"X509_LIB", ERR_LIB_SSL, SSL_R_X509_LIB}, | |
| #else | |
| {"X509_LIB", 20, 268}, | |
| #endif | |
| #ifdef SSL_R_X509_VERIFICATION_SETUP_PROBLEMS | |
| {"X509_VERIFICATION_SETUP_PROBLEMS", ERR_LIB_SSL, SSL_R_X509_VERIFICATION_SETUP_PROBLEMS}, | |
| #else | |
| {"X509_VERIFICATION_SETUP_PROBLEMS", 20, 269}, | |
| #endif | |
| #ifdef TS_R_BAD_PKCS7_TYPE | |
| {"BAD_PKCS7_TYPE", ERR_LIB_TS, TS_R_BAD_PKCS7_TYPE}, | |
| #else | |
| {"BAD_PKCS7_TYPE", 47, 132}, | |
| #endif | |
| #ifdef TS_R_BAD_TYPE | |
| {"BAD_TYPE", ERR_LIB_TS, TS_R_BAD_TYPE}, | |
| #else | |
| {"BAD_TYPE", 47, 133}, | |
| #endif | |
| #ifdef TS_R_CANNOT_LOAD_CERT | |
| {"CANNOT_LOAD_CERT", ERR_LIB_TS, TS_R_CANNOT_LOAD_CERT}, | |
| #else | |
| {"CANNOT_LOAD_CERT", 47, 137}, | |
| #endif | |
| #ifdef TS_R_CANNOT_LOAD_KEY | |
| {"CANNOT_LOAD_KEY", ERR_LIB_TS, TS_R_CANNOT_LOAD_KEY}, | |
| #else | |
| {"CANNOT_LOAD_KEY", 47, 138}, | |
| #endif | |
| #ifdef TS_R_CERTIFICATE_VERIFY_ERROR | |
| {"CERTIFICATE_VERIFY_ERROR", ERR_LIB_TS, TS_R_CERTIFICATE_VERIFY_ERROR}, | |
| #else | |
| {"CERTIFICATE_VERIFY_ERROR", 47, 100}, | |
| #endif | |
| #ifdef TS_R_COULD_NOT_SET_ENGINE | |
| {"COULD_NOT_SET_ENGINE", ERR_LIB_TS, TS_R_COULD_NOT_SET_ENGINE}, | |
| #else | |
| {"COULD_NOT_SET_ENGINE", 47, 127}, | |
| #endif | |
| #ifdef TS_R_COULD_NOT_SET_TIME | |
| {"COULD_NOT_SET_TIME", ERR_LIB_TS, TS_R_COULD_NOT_SET_TIME}, | |
| #else | |
| {"COULD_NOT_SET_TIME", 47, 115}, | |
| #endif | |
| #ifdef TS_R_DETACHED_CONTENT | |
| {"DETACHED_CONTENT", ERR_LIB_TS, TS_R_DETACHED_CONTENT}, | |
| #else | |
| {"DETACHED_CONTENT", 47, 134}, | |
| #endif | |
| #ifdef TS_R_ESS_ADD_SIGNING_CERT_ERROR | |
| {"ESS_ADD_SIGNING_CERT_ERROR", ERR_LIB_TS, TS_R_ESS_ADD_SIGNING_CERT_ERROR}, | |
| #else | |
| {"ESS_ADD_SIGNING_CERT_ERROR", 47, 116}, | |
| #endif | |
| #ifdef TS_R_ESS_ADD_SIGNING_CERT_V2_ERROR | |
| {"ESS_ADD_SIGNING_CERT_V2_ERROR", ERR_LIB_TS, TS_R_ESS_ADD_SIGNING_CERT_V2_ERROR}, | |
| #else | |
| {"ESS_ADD_SIGNING_CERT_V2_ERROR", 47, 139}, | |
| #endif | |
| #ifdef TS_R_ESS_SIGNING_CERTIFICATE_ERROR | |
| {"ESS_SIGNING_CERTIFICATE_ERROR", ERR_LIB_TS, TS_R_ESS_SIGNING_CERTIFICATE_ERROR}, | |
| #else | |
| {"ESS_SIGNING_CERTIFICATE_ERROR", 47, 101}, | |
| #endif | |
| #ifdef TS_R_INVALID_NULL_POINTER | |
| {"INVALID_NULL_POINTER", ERR_LIB_TS, TS_R_INVALID_NULL_POINTER}, | |
| #else | |
| {"INVALID_NULL_POINTER", 47, 102}, | |
| #endif | |
| #ifdef TS_R_INVALID_SIGNER_CERTIFICATE_PURPOSE | |
| {"INVALID_SIGNER_CERTIFICATE_PURPOSE", ERR_LIB_TS, TS_R_INVALID_SIGNER_CERTIFICATE_PURPOSE}, | |
| #else | |
| {"INVALID_SIGNER_CERTIFICATE_PURPOSE", 47, 117}, | |
| #endif | |
| #ifdef TS_R_MESSAGE_IMPRINT_MISMATCH | |
| {"MESSAGE_IMPRINT_MISMATCH", ERR_LIB_TS, TS_R_MESSAGE_IMPRINT_MISMATCH}, | |
| #else | |
| {"MESSAGE_IMPRINT_MISMATCH", 47, 103}, | |
| #endif | |
| #ifdef TS_R_NONCE_MISMATCH | |
| {"NONCE_MISMATCH", ERR_LIB_TS, TS_R_NONCE_MISMATCH}, | |
| #else | |
| {"NONCE_MISMATCH", 47, 104}, | |
| #endif | |
| #ifdef TS_R_NONCE_NOT_RETURNED | |
| {"NONCE_NOT_RETURNED", ERR_LIB_TS, TS_R_NONCE_NOT_RETURNED}, | |
| #else | |
| {"NONCE_NOT_RETURNED", 47, 105}, | |
| #endif | |
| #ifdef TS_R_NO_CONTENT | |
| {"NO_CONTENT", ERR_LIB_TS, TS_R_NO_CONTENT}, | |
| #else | |
| {"NO_CONTENT", 47, 106}, | |
| #endif | |
| #ifdef TS_R_NO_TIME_STAMP_TOKEN | |
| {"NO_TIME_STAMP_TOKEN", ERR_LIB_TS, TS_R_NO_TIME_STAMP_TOKEN}, | |
| #else | |
| {"NO_TIME_STAMP_TOKEN", 47, 107}, | |
| #endif | |
| #ifdef TS_R_PKCS7_ADD_SIGNATURE_ERROR | |
| {"PKCS7_ADD_SIGNATURE_ERROR", ERR_LIB_TS, TS_R_PKCS7_ADD_SIGNATURE_ERROR}, | |
| #else | |
| {"PKCS7_ADD_SIGNATURE_ERROR", 47, 118}, | |
| #endif | |
| #ifdef TS_R_PKCS7_ADD_SIGNED_ATTR_ERROR | |
| {"PKCS7_ADD_SIGNED_ATTR_ERROR", ERR_LIB_TS, TS_R_PKCS7_ADD_SIGNED_ATTR_ERROR}, | |
| #else | |
| {"PKCS7_ADD_SIGNED_ATTR_ERROR", 47, 119}, | |
| #endif | |
| #ifdef TS_R_PKCS7_TO_TS_TST_INFO_FAILED | |
| {"PKCS7_TO_TS_TST_INFO_FAILED", ERR_LIB_TS, TS_R_PKCS7_TO_TS_TST_INFO_FAILED}, | |
| #else | |
| {"PKCS7_TO_TS_TST_INFO_FAILED", 47, 129}, | |
| #endif | |
| #ifdef TS_R_POLICY_MISMATCH | |
| {"POLICY_MISMATCH", ERR_LIB_TS, TS_R_POLICY_MISMATCH}, | |
| #else | |
| {"POLICY_MISMATCH", 47, 108}, | |
| #endif | |
| #ifdef TS_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", ERR_LIB_TS, TS_R_PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE}, | |
| #else | |
| {"PRIVATE_KEY_DOES_NOT_MATCH_CERTIFICATE", 47, 120}, | |
| #endif | |
| #ifdef TS_R_RESPONSE_SETUP_ERROR | |
| {"RESPONSE_SETUP_ERROR", ERR_LIB_TS, TS_R_RESPONSE_SETUP_ERROR}, | |
| #else | |
| {"RESPONSE_SETUP_ERROR", 47, 121}, | |
| #endif | |
| #ifdef TS_R_SIGNATURE_FAILURE | |
| {"SIGNATURE_FAILURE", ERR_LIB_TS, TS_R_SIGNATURE_FAILURE}, | |
| #else | |
| {"SIGNATURE_FAILURE", 47, 109}, | |
| #endif | |
| #ifdef TS_R_THERE_MUST_BE_ONE_SIGNER | |
| {"THERE_MUST_BE_ONE_SIGNER", ERR_LIB_TS, TS_R_THERE_MUST_BE_ONE_SIGNER}, | |
| #else | |
| {"THERE_MUST_BE_ONE_SIGNER", 47, 110}, | |
| #endif | |
| #ifdef TS_R_TIME_SYSCALL_ERROR | |
| {"TIME_SYSCALL_ERROR", ERR_LIB_TS, TS_R_TIME_SYSCALL_ERROR}, | |
| #else | |
| {"TIME_SYSCALL_ERROR", 47, 122}, | |
| #endif | |
| #ifdef TS_R_TOKEN_NOT_PRESENT | |
| {"TOKEN_NOT_PRESENT", ERR_LIB_TS, TS_R_TOKEN_NOT_PRESENT}, | |
| #else | |
| {"TOKEN_NOT_PRESENT", 47, 130}, | |
| #endif | |
| #ifdef TS_R_TOKEN_PRESENT | |
| {"TOKEN_PRESENT", ERR_LIB_TS, TS_R_TOKEN_PRESENT}, | |
| #else | |
| {"TOKEN_PRESENT", 47, 131}, | |
| #endif | |
| #ifdef TS_R_TSA_NAME_MISMATCH | |
| {"TSA_NAME_MISMATCH", ERR_LIB_TS, TS_R_TSA_NAME_MISMATCH}, | |
| #else | |
| {"TSA_NAME_MISMATCH", 47, 111}, | |
| #endif | |
| #ifdef TS_R_TSA_UNTRUSTED | |
| {"TSA_UNTRUSTED", ERR_LIB_TS, TS_R_TSA_UNTRUSTED}, | |
| #else | |
| {"TSA_UNTRUSTED", 47, 112}, | |
| #endif | |
| #ifdef TS_R_TST_INFO_SETUP_ERROR | |
| {"TST_INFO_SETUP_ERROR", ERR_LIB_TS, TS_R_TST_INFO_SETUP_ERROR}, | |
| #else | |
| {"TST_INFO_SETUP_ERROR", 47, 123}, | |
| #endif | |
| #ifdef TS_R_TS_DATASIGN | |
| {"TS_DATASIGN", ERR_LIB_TS, TS_R_TS_DATASIGN}, | |
| #else | |
| {"TS_DATASIGN", 47, 124}, | |
| #endif | |
| #ifdef TS_R_UNACCEPTABLE_POLICY | |
| {"UNACCEPTABLE_POLICY", ERR_LIB_TS, TS_R_UNACCEPTABLE_POLICY}, | |
| #else | |
| {"UNACCEPTABLE_POLICY", 47, 125}, | |
| #endif | |
| #ifdef TS_R_UNSUPPORTED_MD_ALGORITHM | |
| {"UNSUPPORTED_MD_ALGORITHM", ERR_LIB_TS, TS_R_UNSUPPORTED_MD_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_MD_ALGORITHM", 47, 126}, | |
| #endif | |
| #ifdef TS_R_UNSUPPORTED_VERSION | |
| {"UNSUPPORTED_VERSION", ERR_LIB_TS, TS_R_UNSUPPORTED_VERSION}, | |
| #else | |
| {"UNSUPPORTED_VERSION", 47, 113}, | |
| #endif | |
| #ifdef TS_R_VAR_BAD_VALUE | |
| {"VAR_BAD_VALUE", ERR_LIB_TS, TS_R_VAR_BAD_VALUE}, | |
| #else | |
| {"VAR_BAD_VALUE", 47, 135}, | |
| #endif | |
| #ifdef TS_R_VAR_LOOKUP_FAILURE | |
| {"VAR_LOOKUP_FAILURE", ERR_LIB_TS, TS_R_VAR_LOOKUP_FAILURE}, | |
| #else | |
| {"VAR_LOOKUP_FAILURE", 47, 136}, | |
| #endif | |
| #ifdef TS_R_WRONG_CONTENT_TYPE | |
| {"WRONG_CONTENT_TYPE", ERR_LIB_TS, TS_R_WRONG_CONTENT_TYPE}, | |
| #else | |
| {"WRONG_CONTENT_TYPE", 47, 114}, | |
| #endif | |
| #ifdef UI_R_COMMON_OK_AND_CANCEL_CHARACTERS | |
| {"COMMON_OK_AND_CANCEL_CHARACTERS", ERR_LIB_UI, UI_R_COMMON_OK_AND_CANCEL_CHARACTERS}, | |
| #else | |
| {"COMMON_OK_AND_CANCEL_CHARACTERS", 40, 104}, | |
| #endif | |
| #ifdef UI_R_INDEX_TOO_LARGE | |
| {"INDEX_TOO_LARGE", ERR_LIB_UI, UI_R_INDEX_TOO_LARGE}, | |
| #else | |
| {"INDEX_TOO_LARGE", 40, 102}, | |
| #endif | |
| #ifdef UI_R_INDEX_TOO_SMALL | |
| {"INDEX_TOO_SMALL", ERR_LIB_UI, UI_R_INDEX_TOO_SMALL}, | |
| #else | |
| {"INDEX_TOO_SMALL", 40, 103}, | |
| #endif | |
| #ifdef UI_R_NO_RESULT_BUFFER | |
| {"NO_RESULT_BUFFER", ERR_LIB_UI, UI_R_NO_RESULT_BUFFER}, | |
| #else | |
| {"NO_RESULT_BUFFER", 40, 105}, | |
| #endif | |
| #ifdef UI_R_PROCESSING_ERROR | |
| {"PROCESSING_ERROR", ERR_LIB_UI, UI_R_PROCESSING_ERROR}, | |
| #else | |
| {"PROCESSING_ERROR", 40, 107}, | |
| #endif | |
| #ifdef UI_R_RESULT_TOO_LARGE | |
| {"RESULT_TOO_LARGE", ERR_LIB_UI, UI_R_RESULT_TOO_LARGE}, | |
| #else | |
| {"RESULT_TOO_LARGE", 40, 100}, | |
| #endif | |
| #ifdef UI_R_RESULT_TOO_SMALL | |
| {"RESULT_TOO_SMALL", ERR_LIB_UI, UI_R_RESULT_TOO_SMALL}, | |
| #else | |
| {"RESULT_TOO_SMALL", 40, 101}, | |
| #endif | |
| #ifdef UI_R_SYSASSIGN_ERROR | |
| {"SYSASSIGN_ERROR", ERR_LIB_UI, UI_R_SYSASSIGN_ERROR}, | |
| #else | |
| {"SYSASSIGN_ERROR", 40, 109}, | |
| #endif | |
| #ifdef UI_R_SYSDASSGN_ERROR | |
| {"SYSDASSGN_ERROR", ERR_LIB_UI, UI_R_SYSDASSGN_ERROR}, | |
| #else | |
| {"SYSDASSGN_ERROR", 40, 110}, | |
| #endif | |
| #ifdef UI_R_SYSQIOW_ERROR | |
| {"SYSQIOW_ERROR", ERR_LIB_UI, UI_R_SYSQIOW_ERROR}, | |
| #else | |
| {"SYSQIOW_ERROR", 40, 111}, | |
| #endif | |
| #ifdef UI_R_UNKNOWN_CONTROL_COMMAND | |
| {"UNKNOWN_CONTROL_COMMAND", ERR_LIB_UI, UI_R_UNKNOWN_CONTROL_COMMAND}, | |
| #else | |
| {"UNKNOWN_CONTROL_COMMAND", 40, 106}, | |
| #endif | |
| #ifdef UI_R_UNKNOWN_TTYGET_ERRNO_VALUE | |
| {"UNKNOWN_TTYGET_ERRNO_VALUE", ERR_LIB_UI, UI_R_UNKNOWN_TTYGET_ERRNO_VALUE}, | |
| #else | |
| {"UNKNOWN_TTYGET_ERRNO_VALUE", 40, 108}, | |
| #endif | |
| #ifdef UI_R_USER_DATA_DUPLICATION_UNSUPPORTED | |
| {"USER_DATA_DUPLICATION_UNSUPPORTED", ERR_LIB_UI, UI_R_USER_DATA_DUPLICATION_UNSUPPORTED}, | |
| #else | |
| {"USER_DATA_DUPLICATION_UNSUPPORTED", 40, 112}, | |
| #endif | |
| #ifdef X509V3_R_BAD_IP_ADDRESS | |
| {"BAD_IP_ADDRESS", ERR_LIB_X509V3, X509V3_R_BAD_IP_ADDRESS}, | |
| #else | |
| {"BAD_IP_ADDRESS", 34, 118}, | |
| #endif | |
| #ifdef X509V3_R_BAD_OBJECT | |
| {"BAD_OBJECT", ERR_LIB_X509V3, X509V3_R_BAD_OBJECT}, | |
| #else | |
| {"BAD_OBJECT", 34, 119}, | |
| #endif | |
| #ifdef X509V3_R_BAD_OPTION | |
| {"BAD_OPTION", ERR_LIB_X509V3, X509V3_R_BAD_OPTION}, | |
| #else | |
| {"BAD_OPTION", 34, 170}, | |
| #endif | |
| #ifdef X509V3_R_BAD_VALUE | |
| {"BAD_VALUE", ERR_LIB_X509V3, X509V3_R_BAD_VALUE}, | |
| #else | |
| {"BAD_VALUE", 34, 171}, | |
| #endif | |
| #ifdef X509V3_R_BN_DEC2BN_ERROR | |
| {"BN_DEC2BN_ERROR", ERR_LIB_X509V3, X509V3_R_BN_DEC2BN_ERROR}, | |
| #else | |
| {"BN_DEC2BN_ERROR", 34, 100}, | |
| #endif | |
| #ifdef X509V3_R_BN_TO_ASN1_INTEGER_ERROR | |
| {"BN_TO_ASN1_INTEGER_ERROR", ERR_LIB_X509V3, X509V3_R_BN_TO_ASN1_INTEGER_ERROR}, | |
| #else | |
| {"BN_TO_ASN1_INTEGER_ERROR", 34, 101}, | |
| #endif | |
| #ifdef X509V3_R_DIRNAME_ERROR | |
| {"DIRNAME_ERROR", ERR_LIB_X509V3, X509V3_R_DIRNAME_ERROR}, | |
| #else | |
| {"DIRNAME_ERROR", 34, 149}, | |
| #endif | |
| #ifdef X509V3_R_DISTPOINT_ALREADY_SET | |
| {"DISTPOINT_ALREADY_SET", ERR_LIB_X509V3, X509V3_R_DISTPOINT_ALREADY_SET}, | |
| #else | |
| {"DISTPOINT_ALREADY_SET", 34, 160}, | |
| #endif | |
| #ifdef X509V3_R_DUPLICATE_ZONE_ID | |
| {"DUPLICATE_ZONE_ID", ERR_LIB_X509V3, X509V3_R_DUPLICATE_ZONE_ID}, | |
| #else | |
| {"DUPLICATE_ZONE_ID", 34, 133}, | |
| #endif | |
| #ifdef X509V3_R_EMPTY_KEY_USAGE | |
| {"EMPTY_KEY_USAGE", ERR_LIB_X509V3, X509V3_R_EMPTY_KEY_USAGE}, | |
| #else | |
| {"EMPTY_KEY_USAGE", 34, 169}, | |
| #endif | |
| #ifdef X509V3_R_ERROR_CONVERTING_ZONE | |
| {"ERROR_CONVERTING_ZONE", ERR_LIB_X509V3, X509V3_R_ERROR_CONVERTING_ZONE}, | |
| #else | |
| {"ERROR_CONVERTING_ZONE", 34, 131}, | |
| #endif | |
| #ifdef X509V3_R_ERROR_CREATING_EXTENSION | |
| {"ERROR_CREATING_EXTENSION", ERR_LIB_X509V3, X509V3_R_ERROR_CREATING_EXTENSION}, | |
| #else | |
| {"ERROR_CREATING_EXTENSION", 34, 144}, | |
| #endif | |
| #ifdef X509V3_R_ERROR_IN_EXTENSION | |
| {"ERROR_IN_EXTENSION", ERR_LIB_X509V3, X509V3_R_ERROR_IN_EXTENSION}, | |
| #else | |
| {"ERROR_IN_EXTENSION", 34, 128}, | |
| #endif | |
| #ifdef X509V3_R_EXPECTED_A_SECTION_NAME | |
| {"EXPECTED_A_SECTION_NAME", ERR_LIB_X509V3, X509V3_R_EXPECTED_A_SECTION_NAME}, | |
| #else | |
| {"EXPECTED_A_SECTION_NAME", 34, 137}, | |
| #endif | |
| #ifdef X509V3_R_EXTENSION_EXISTS | |
| {"EXTENSION_EXISTS", ERR_LIB_X509V3, X509V3_R_EXTENSION_EXISTS}, | |
| #else | |
| {"EXTENSION_EXISTS", 34, 145}, | |
| #endif | |
| #ifdef X509V3_R_EXTENSION_NAME_ERROR | |
| {"EXTENSION_NAME_ERROR", ERR_LIB_X509V3, X509V3_R_EXTENSION_NAME_ERROR}, | |
| #else | |
| {"EXTENSION_NAME_ERROR", 34, 115}, | |
| #endif | |
| #ifdef X509V3_R_EXTENSION_NOT_FOUND | |
| {"EXTENSION_NOT_FOUND", ERR_LIB_X509V3, X509V3_R_EXTENSION_NOT_FOUND}, | |
| #else | |
| {"EXTENSION_NOT_FOUND", 34, 102}, | |
| #endif | |
| #ifdef X509V3_R_EXTENSION_SETTING_NOT_SUPPORTED | |
| {"EXTENSION_SETTING_NOT_SUPPORTED", ERR_LIB_X509V3, X509V3_R_EXTENSION_SETTING_NOT_SUPPORTED}, | |
| #else | |
| {"EXTENSION_SETTING_NOT_SUPPORTED", 34, 103}, | |
| #endif | |
| #ifdef X509V3_R_EXTENSION_VALUE_ERROR | |
| {"EXTENSION_VALUE_ERROR", ERR_LIB_X509V3, X509V3_R_EXTENSION_VALUE_ERROR}, | |
| #else | |
| {"EXTENSION_VALUE_ERROR", 34, 116}, | |
| #endif | |
| #ifdef X509V3_R_ILLEGAL_EMPTY_EXTENSION | |
| {"ILLEGAL_EMPTY_EXTENSION", ERR_LIB_X509V3, X509V3_R_ILLEGAL_EMPTY_EXTENSION}, | |
| #else | |
| {"ILLEGAL_EMPTY_EXTENSION", 34, 151}, | |
| #endif | |
| #ifdef X509V3_R_INCORRECT_POLICY_SYNTAX_TAG | |
| {"INCORRECT_POLICY_SYNTAX_TAG", ERR_LIB_X509V3, X509V3_R_INCORRECT_POLICY_SYNTAX_TAG}, | |
| #else | |
| {"INCORRECT_POLICY_SYNTAX_TAG", 34, 152}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_ASNUMBER | |
| {"INVALID_ASNUMBER", ERR_LIB_X509V3, X509V3_R_INVALID_ASNUMBER}, | |
| #else | |
| {"INVALID_ASNUMBER", 34, 162}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_ASRANGE | |
| {"INVALID_ASRANGE", ERR_LIB_X509V3, X509V3_R_INVALID_ASRANGE}, | |
| #else | |
| {"INVALID_ASRANGE", 34, 163}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_BOOLEAN_STRING | |
| {"INVALID_BOOLEAN_STRING", ERR_LIB_X509V3, X509V3_R_INVALID_BOOLEAN_STRING}, | |
| #else | |
| {"INVALID_BOOLEAN_STRING", 34, 104}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_CERTIFICATE | |
| {"INVALID_CERTIFICATE", ERR_LIB_X509V3, X509V3_R_INVALID_CERTIFICATE}, | |
| #else | |
| {"INVALID_CERTIFICATE", 34, 158}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_EMPTY_NAME | |
| {"INVALID_EMPTY_NAME", ERR_LIB_X509V3, X509V3_R_INVALID_EMPTY_NAME}, | |
| #else | |
| {"INVALID_EMPTY_NAME", 34, 108}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_EXTENSION_STRING | |
| {"INVALID_EXTENSION_STRING", ERR_LIB_X509V3, X509V3_R_INVALID_EXTENSION_STRING}, | |
| #else | |
| {"INVALID_EXTENSION_STRING", 34, 105}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_INHERITANCE | |
| {"INVALID_INHERITANCE", ERR_LIB_X509V3, X509V3_R_INVALID_INHERITANCE}, | |
| #else | |
| {"INVALID_INHERITANCE", 34, 165}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_IPADDRESS | |
| {"INVALID_IPADDRESS", ERR_LIB_X509V3, X509V3_R_INVALID_IPADDRESS}, | |
| #else | |
| {"INVALID_IPADDRESS", 34, 166}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_MULTIPLE_RDNS | |
| {"INVALID_MULTIPLE_RDNS", ERR_LIB_X509V3, X509V3_R_INVALID_MULTIPLE_RDNS}, | |
| #else | |
| {"INVALID_MULTIPLE_RDNS", 34, 161}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_NAME | |
| {"INVALID_NAME", ERR_LIB_X509V3, X509V3_R_INVALID_NAME}, | |
| #else | |
| {"INVALID_NAME", 34, 106}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_NULL_ARGUMENT | |
| {"INVALID_NULL_ARGUMENT", ERR_LIB_X509V3, X509V3_R_INVALID_NULL_ARGUMENT}, | |
| #else | |
| {"INVALID_NULL_ARGUMENT", 34, 107}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_NULL_VALUE | |
| {"INVALID_NULL_VALUE", ERR_LIB_X509V3, X509V3_R_INVALID_NULL_VALUE}, | |
| #else | |
| {"INVALID_NULL_VALUE", 34, 109}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_NUMBER | |
| {"INVALID_NUMBER", ERR_LIB_X509V3, X509V3_R_INVALID_NUMBER}, | |
| #else | |
| {"INVALID_NUMBER", 34, 140}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_NUMBERS | |
| {"INVALID_NUMBERS", ERR_LIB_X509V3, X509V3_R_INVALID_NUMBERS}, | |
| #else | |
| {"INVALID_NUMBERS", 34, 141}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_OBJECT_IDENTIFIER | |
| {"INVALID_OBJECT_IDENTIFIER", ERR_LIB_X509V3, X509V3_R_INVALID_OBJECT_IDENTIFIER}, | |
| #else | |
| {"INVALID_OBJECT_IDENTIFIER", 34, 110}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_OPTION | |
| {"INVALID_OPTION", ERR_LIB_X509V3, X509V3_R_INVALID_OPTION}, | |
| #else | |
| {"INVALID_OPTION", 34, 138}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_POLICY_IDENTIFIER | |
| {"INVALID_POLICY_IDENTIFIER", ERR_LIB_X509V3, X509V3_R_INVALID_POLICY_IDENTIFIER}, | |
| #else | |
| {"INVALID_POLICY_IDENTIFIER", 34, 134}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_PROXY_POLICY_SETTING | |
| {"INVALID_PROXY_POLICY_SETTING", ERR_LIB_X509V3, X509V3_R_INVALID_PROXY_POLICY_SETTING}, | |
| #else | |
| {"INVALID_PROXY_POLICY_SETTING", 34, 153}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_PURPOSE | |
| {"INVALID_PURPOSE", ERR_LIB_X509V3, X509V3_R_INVALID_PURPOSE}, | |
| #else | |
| {"INVALID_PURPOSE", 34, 146}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_SAFI | |
| {"INVALID_SAFI", ERR_LIB_X509V3, X509V3_R_INVALID_SAFI}, | |
| #else | |
| {"INVALID_SAFI", 34, 164}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_SECTION | |
| {"INVALID_SECTION", ERR_LIB_X509V3, X509V3_R_INVALID_SECTION}, | |
| #else | |
| {"INVALID_SECTION", 34, 135}, | |
| #endif | |
| #ifdef X509V3_R_INVALID_SYNTAX | |
| {"INVALID_SYNTAX", ERR_LIB_X509V3, X509V3_R_INVALID_SYNTAX}, | |
| #else | |
| {"INVALID_SYNTAX", 34, 143}, | |
| #endif | |
| #ifdef X509V3_R_ISSUER_DECODE_ERROR | |
| {"ISSUER_DECODE_ERROR", ERR_LIB_X509V3, X509V3_R_ISSUER_DECODE_ERROR}, | |
| #else | |
| {"ISSUER_DECODE_ERROR", 34, 126}, | |
| #endif | |
| #ifdef X509V3_R_MISSING_VALUE | |
| {"MISSING_VALUE", ERR_LIB_X509V3, X509V3_R_MISSING_VALUE}, | |
| #else | |
| {"MISSING_VALUE", 34, 124}, | |
| #endif | |
| #ifdef X509V3_R_NEED_ORGANIZATION_AND_NUMBERS | |
| {"NEED_ORGANIZATION_AND_NUMBERS", ERR_LIB_X509V3, X509V3_R_NEED_ORGANIZATION_AND_NUMBERS}, | |
| #else | |
| {"NEED_ORGANIZATION_AND_NUMBERS", 34, 142}, | |
| #endif | |
| #ifdef X509V3_R_NEGATIVE_PATHLEN | |
| {"NEGATIVE_PATHLEN", ERR_LIB_X509V3, X509V3_R_NEGATIVE_PATHLEN}, | |
| #else | |
| {"NEGATIVE_PATHLEN", 34, 168}, | |
| #endif | |
| #ifdef X509V3_R_NO_CONFIG_DATABASE | |
| {"NO_CONFIG_DATABASE", ERR_LIB_X509V3, X509V3_R_NO_CONFIG_DATABASE}, | |
| #else | |
| {"NO_CONFIG_DATABASE", 34, 136}, | |
| #endif | |
| #ifdef X509V3_R_NO_ISSUER_CERTIFICATE | |
| {"NO_ISSUER_CERTIFICATE", ERR_LIB_X509V3, X509V3_R_NO_ISSUER_CERTIFICATE}, | |
| #else | |
| {"NO_ISSUER_CERTIFICATE", 34, 121}, | |
| #endif | |
| #ifdef X509V3_R_NO_ISSUER_DETAILS | |
| {"NO_ISSUER_DETAILS", ERR_LIB_X509V3, X509V3_R_NO_ISSUER_DETAILS}, | |
| #else | |
| {"NO_ISSUER_DETAILS", 34, 127}, | |
| #endif | |
| #ifdef X509V3_R_NO_POLICY_IDENTIFIER | |
| {"NO_POLICY_IDENTIFIER", ERR_LIB_X509V3, X509V3_R_NO_POLICY_IDENTIFIER}, | |
| #else | |
| {"NO_POLICY_IDENTIFIER", 34, 139}, | |
| #endif | |
| #ifdef X509V3_R_NO_PROXY_CERT_POLICY_LANGUAGE_DEFINED | |
| {"NO_PROXY_CERT_POLICY_LANGUAGE_DEFINED", ERR_LIB_X509V3, X509V3_R_NO_PROXY_CERT_POLICY_LANGUAGE_DEFINED}, | |
| #else | |
| {"NO_PROXY_CERT_POLICY_LANGUAGE_DEFINED", 34, 154}, | |
| #endif | |
| #ifdef X509V3_R_NO_PUBLIC_KEY | |
| {"NO_PUBLIC_KEY", ERR_LIB_X509V3, X509V3_R_NO_PUBLIC_KEY}, | |
| #else | |
| {"NO_PUBLIC_KEY", 34, 114}, | |
| #endif | |
| #ifdef X509V3_R_NO_SUBJECT_DETAILS | |
| {"NO_SUBJECT_DETAILS", ERR_LIB_X509V3, X509V3_R_NO_SUBJECT_DETAILS}, | |
| #else | |
| {"NO_SUBJECT_DETAILS", 34, 125}, | |
| #endif | |
| #ifdef X509V3_R_OPERATION_NOT_DEFINED | |
| {"OPERATION_NOT_DEFINED", ERR_LIB_X509V3, X509V3_R_OPERATION_NOT_DEFINED}, | |
| #else | |
| {"OPERATION_NOT_DEFINED", 34, 148}, | |
| #endif | |
| #ifdef X509V3_R_OTHERNAME_ERROR | |
| {"OTHERNAME_ERROR", ERR_LIB_X509V3, X509V3_R_OTHERNAME_ERROR}, | |
| #else | |
| {"OTHERNAME_ERROR", 34, 147}, | |
| #endif | |
| #ifdef X509V3_R_POLICY_LANGUAGE_ALREADY_DEFINED | |
| {"POLICY_LANGUAGE_ALREADY_DEFINED", ERR_LIB_X509V3, X509V3_R_POLICY_LANGUAGE_ALREADY_DEFINED}, | |
| #else | |
| {"POLICY_LANGUAGE_ALREADY_DEFINED", 34, 155}, | |
| #endif | |
| #ifdef X509V3_R_POLICY_PATH_LENGTH | |
| {"POLICY_PATH_LENGTH", ERR_LIB_X509V3, X509V3_R_POLICY_PATH_LENGTH}, | |
| #else | |
| {"POLICY_PATH_LENGTH", 34, 156}, | |
| #endif | |
| #ifdef X509V3_R_POLICY_PATH_LENGTH_ALREADY_DEFINED | |
| {"POLICY_PATH_LENGTH_ALREADY_DEFINED", ERR_LIB_X509V3, X509V3_R_POLICY_PATH_LENGTH_ALREADY_DEFINED}, | |
| #else | |
| {"POLICY_PATH_LENGTH_ALREADY_DEFINED", 34, 157}, | |
| #endif | |
| #ifdef X509V3_R_POLICY_WHEN_PROXY_LANGUAGE_REQUIRES_NO_POLICY | |
| {"POLICY_WHEN_PROXY_LANGUAGE_REQUIRES_NO_POLICY", ERR_LIB_X509V3, X509V3_R_POLICY_WHEN_PROXY_LANGUAGE_REQUIRES_NO_POLICY}, | |
| #else | |
| {"POLICY_WHEN_PROXY_LANGUAGE_REQUIRES_NO_POLICY", 34, 159}, | |
| #endif | |
| #ifdef X509V3_R_PURPOSE_NOT_UNIQUE | |
| {"PURPOSE_NOT_UNIQUE", ERR_LIB_X509V3, X509V3_R_PURPOSE_NOT_UNIQUE}, | |
| #else | |
| {"PURPOSE_NOT_UNIQUE", 34, 173}, | |
| #endif | |
| #ifdef X509V3_R_SECTION_NOT_FOUND | |
| {"SECTION_NOT_FOUND", ERR_LIB_X509V3, X509V3_R_SECTION_NOT_FOUND}, | |
| #else | |
| {"SECTION_NOT_FOUND", 34, 150}, | |
| #endif | |
| #ifdef X509V3_R_UNABLE_TO_GET_ISSUER_DETAILS | |
| {"UNABLE_TO_GET_ISSUER_DETAILS", ERR_LIB_X509V3, X509V3_R_UNABLE_TO_GET_ISSUER_DETAILS}, | |
| #else | |
| {"UNABLE_TO_GET_ISSUER_DETAILS", 34, 122}, | |
| #endif | |
| #ifdef X509V3_R_UNABLE_TO_GET_ISSUER_KEYID | |
| {"UNABLE_TO_GET_ISSUER_KEYID", ERR_LIB_X509V3, X509V3_R_UNABLE_TO_GET_ISSUER_KEYID}, | |
| #else | |
| {"UNABLE_TO_GET_ISSUER_KEYID", 34, 123}, | |
| #endif | |
| #ifdef X509V3_R_UNKNOWN_BIT_STRING_ARGUMENT | |
| {"UNKNOWN_BIT_STRING_ARGUMENT", ERR_LIB_X509V3, X509V3_R_UNKNOWN_BIT_STRING_ARGUMENT}, | |
| #else | |
| {"UNKNOWN_BIT_STRING_ARGUMENT", 34, 111}, | |
| #endif | |
| #ifdef X509V3_R_UNKNOWN_EXTENSION | |
| {"UNKNOWN_EXTENSION", ERR_LIB_X509V3, X509V3_R_UNKNOWN_EXTENSION}, | |
| #else | |
| {"UNKNOWN_EXTENSION", 34, 129}, | |
| #endif | |
| #ifdef X509V3_R_UNKNOWN_EXTENSION_NAME | |
| {"UNKNOWN_EXTENSION_NAME", ERR_LIB_X509V3, X509V3_R_UNKNOWN_EXTENSION_NAME}, | |
| #else | |
| {"UNKNOWN_EXTENSION_NAME", 34, 130}, | |
| #endif | |
| #ifdef X509V3_R_UNKNOWN_OPTION | |
| {"UNKNOWN_OPTION", ERR_LIB_X509V3, X509V3_R_UNKNOWN_OPTION}, | |
| #else | |
| {"UNKNOWN_OPTION", 34, 120}, | |
| #endif | |
| #ifdef X509V3_R_UNKNOWN_VALUE | |
| {"UNKNOWN_VALUE", ERR_LIB_X509V3, X509V3_R_UNKNOWN_VALUE}, | |
| #else | |
| {"UNKNOWN_VALUE", 34, 172}, | |
| #endif | |
| #ifdef X509V3_R_UNSUPPORTED_OPTION | |
| {"UNSUPPORTED_OPTION", ERR_LIB_X509V3, X509V3_R_UNSUPPORTED_OPTION}, | |
| #else | |
| {"UNSUPPORTED_OPTION", 34, 117}, | |
| #endif | |
| #ifdef X509V3_R_UNSUPPORTED_TYPE | |
| {"UNSUPPORTED_TYPE", ERR_LIB_X509V3, X509V3_R_UNSUPPORTED_TYPE}, | |
| #else | |
| {"UNSUPPORTED_TYPE", 34, 167}, | |
| #endif | |
| #ifdef X509V3_R_USER_TOO_LONG | |
| {"USER_TOO_LONG", ERR_LIB_X509V3, X509V3_R_USER_TOO_LONG}, | |
| #else | |
| {"USER_TOO_LONG", 34, 132}, | |
| #endif | |
| #ifdef X509_R_AKID_MISMATCH | |
| {"AKID_MISMATCH", ERR_LIB_X509, X509_R_AKID_MISMATCH}, | |
| #else | |
| {"AKID_MISMATCH", 11, 110}, | |
| #endif | |
| #ifdef X509_R_BAD_SELECTOR | |
| {"BAD_SELECTOR", ERR_LIB_X509, X509_R_BAD_SELECTOR}, | |
| #else | |
| {"BAD_SELECTOR", 11, 133}, | |
| #endif | |
| #ifdef X509_R_BAD_X509_FILETYPE | |
| {"BAD_X509_FILETYPE", ERR_LIB_X509, X509_R_BAD_X509_FILETYPE}, | |
| #else | |
| {"BAD_X509_FILETYPE", 11, 100}, | |
| #endif | |
| #ifdef X509_R_BASE64_DECODE_ERROR | |
| {"BASE64_DECODE_ERROR", ERR_LIB_X509, X509_R_BASE64_DECODE_ERROR}, | |
| #else | |
| {"BASE64_DECODE_ERROR", 11, 118}, | |
| #endif | |
| #ifdef X509_R_CANT_CHECK_DH_KEY | |
| {"CANT_CHECK_DH_KEY", ERR_LIB_X509, X509_R_CANT_CHECK_DH_KEY}, | |
| #else | |
| {"CANT_CHECK_DH_KEY", 11, 114}, | |
| #endif | |
| #ifdef X509_R_CERTIFICATE_VERIFICATION_FAILED | |
| {"CERTIFICATE_VERIFICATION_FAILED", ERR_LIB_X509, X509_R_CERTIFICATE_VERIFICATION_FAILED}, | |
| #else | |
| {"CERTIFICATE_VERIFICATION_FAILED", 11, 139}, | |
| #endif | |
| #ifdef X509_R_CERT_ALREADY_IN_HASH_TABLE | |
| {"CERT_ALREADY_IN_HASH_TABLE", ERR_LIB_X509, X509_R_CERT_ALREADY_IN_HASH_TABLE}, | |
| #else | |
| {"CERT_ALREADY_IN_HASH_TABLE", 11, 101}, | |
| #endif | |
| #ifdef X509_R_CRL_ALREADY_DELTA | |
| {"CRL_ALREADY_DELTA", ERR_LIB_X509, X509_R_CRL_ALREADY_DELTA}, | |
| #else | |
| {"CRL_ALREADY_DELTA", 11, 127}, | |
| #endif | |
| #ifdef X509_R_CRL_VERIFY_FAILURE | |
| {"CRL_VERIFY_FAILURE", ERR_LIB_X509, X509_R_CRL_VERIFY_FAILURE}, | |
| #else | |
| {"CRL_VERIFY_FAILURE", 11, 131}, | |
| #endif | |
| #ifdef X509_R_DUPLICATE_ATTRIBUTE | |
| {"DUPLICATE_ATTRIBUTE", ERR_LIB_X509, X509_R_DUPLICATE_ATTRIBUTE}, | |
| #else | |
| {"DUPLICATE_ATTRIBUTE", 11, 140}, | |
| #endif | |
| #ifdef X509_R_ERROR_GETTING_MD_BY_NID | |
| {"ERROR_GETTING_MD_BY_NID", ERR_LIB_X509, X509_R_ERROR_GETTING_MD_BY_NID}, | |
| #else | |
| {"ERROR_GETTING_MD_BY_NID", 11, 141}, | |
| #endif | |
| #ifdef X509_R_ERROR_USING_SIGINF_SET | |
| {"ERROR_USING_SIGINF_SET", ERR_LIB_X509, X509_R_ERROR_USING_SIGINF_SET}, | |
| #else | |
| {"ERROR_USING_SIGINF_SET", 11, 142}, | |
| #endif | |
| #ifdef X509_R_IDP_MISMATCH | |
| {"IDP_MISMATCH", ERR_LIB_X509, X509_R_IDP_MISMATCH}, | |
| #else | |
| {"IDP_MISMATCH", 11, 128}, | |
| #endif | |
| #ifdef X509_R_INVALID_ATTRIBUTES | |
| {"INVALID_ATTRIBUTES", ERR_LIB_X509, X509_R_INVALID_ATTRIBUTES}, | |
| #else | |
| {"INVALID_ATTRIBUTES", 11, 138}, | |
| #endif | |
| #ifdef X509_R_INVALID_DIRECTORY | |
| {"INVALID_DIRECTORY", ERR_LIB_X509, X509_R_INVALID_DIRECTORY}, | |
| #else | |
| {"INVALID_DIRECTORY", 11, 113}, | |
| #endif | |
| #ifdef X509_R_INVALID_DISTPOINT | |
| {"INVALID_DISTPOINT", ERR_LIB_X509, X509_R_INVALID_DISTPOINT}, | |
| #else | |
| {"INVALID_DISTPOINT", 11, 143}, | |
| #endif | |
| #ifdef X509_R_INVALID_FIELD_NAME | |
| {"INVALID_FIELD_NAME", ERR_LIB_X509, X509_R_INVALID_FIELD_NAME}, | |
| #else | |
| {"INVALID_FIELD_NAME", 11, 119}, | |
| #endif | |
| #ifdef X509_R_INVALID_TRUST | |
| {"INVALID_TRUST", ERR_LIB_X509, X509_R_INVALID_TRUST}, | |
| #else | |
| {"INVALID_TRUST", 11, 123}, | |
| #endif | |
| #ifdef X509_R_ISSUER_MISMATCH | |
| {"ISSUER_MISMATCH", ERR_LIB_X509, X509_R_ISSUER_MISMATCH}, | |
| #else | |
| {"ISSUER_MISMATCH", 11, 129}, | |
| #endif | |
| #ifdef X509_R_KEY_TYPE_MISMATCH | |
| {"KEY_TYPE_MISMATCH", ERR_LIB_X509, X509_R_KEY_TYPE_MISMATCH}, | |
| #else | |
| {"KEY_TYPE_MISMATCH", 11, 115}, | |
| #endif | |
| #ifdef X509_R_KEY_VALUES_MISMATCH | |
| {"KEY_VALUES_MISMATCH", ERR_LIB_X509, X509_R_KEY_VALUES_MISMATCH}, | |
| #else | |
| {"KEY_VALUES_MISMATCH", 11, 116}, | |
| #endif | |
| #ifdef X509_R_LOADING_CERT_DIR | |
| {"LOADING_CERT_DIR", ERR_LIB_X509, X509_R_LOADING_CERT_DIR}, | |
| #else | |
| {"LOADING_CERT_DIR", 11, 103}, | |
| #endif | |
| #ifdef X509_R_LOADING_DEFAULTS | |
| {"LOADING_DEFAULTS", ERR_LIB_X509, X509_R_LOADING_DEFAULTS}, | |
| #else | |
| {"LOADING_DEFAULTS", 11, 104}, | |
| #endif | |
| #ifdef X509_R_METHOD_NOT_SUPPORTED | |
| {"METHOD_NOT_SUPPORTED", ERR_LIB_X509, X509_R_METHOD_NOT_SUPPORTED}, | |
| #else | |
| {"METHOD_NOT_SUPPORTED", 11, 124}, | |
| #endif | |
| #ifdef X509_R_NAME_TOO_LONG | |
| {"NAME_TOO_LONG", ERR_LIB_X509, X509_R_NAME_TOO_LONG}, | |
| #else | |
| {"NAME_TOO_LONG", 11, 134}, | |
| #endif | |
| #ifdef X509_R_NEWER_CRL_NOT_NEWER | |
| {"NEWER_CRL_NOT_NEWER", ERR_LIB_X509, X509_R_NEWER_CRL_NOT_NEWER}, | |
| #else | |
| {"NEWER_CRL_NOT_NEWER", 11, 132}, | |
| #endif | |
| #ifdef X509_R_NO_CERTIFICATE_FOUND | |
| {"NO_CERTIFICATE_FOUND", ERR_LIB_X509, X509_R_NO_CERTIFICATE_FOUND}, | |
| #else | |
| {"NO_CERTIFICATE_FOUND", 11, 135}, | |
| #endif | |
| #ifdef X509_R_NO_CERTIFICATE_OR_CRL_FOUND | |
| {"NO_CERTIFICATE_OR_CRL_FOUND", ERR_LIB_X509, X509_R_NO_CERTIFICATE_OR_CRL_FOUND}, | |
| #else | |
| {"NO_CERTIFICATE_OR_CRL_FOUND", 11, 136}, | |
| #endif | |
| #ifdef X509_R_NO_CERT_SET_FOR_US_TO_VERIFY | |
| {"NO_CERT_SET_FOR_US_TO_VERIFY", ERR_LIB_X509, X509_R_NO_CERT_SET_FOR_US_TO_VERIFY}, | |
| #else | |
| {"NO_CERT_SET_FOR_US_TO_VERIFY", 11, 105}, | |
| #endif | |
| #ifdef X509_R_NO_CRL_FOUND | |
| {"NO_CRL_FOUND", ERR_LIB_X509, X509_R_NO_CRL_FOUND}, | |
| #else | |
| {"NO_CRL_FOUND", 11, 137}, | |
| #endif | |
| #ifdef X509_R_NO_CRL_NUMBER | |
| {"NO_CRL_NUMBER", ERR_LIB_X509, X509_R_NO_CRL_NUMBER}, | |
| #else | |
| {"NO_CRL_NUMBER", 11, 130}, | |
| #endif | |
| #ifdef X509_R_PUBLIC_KEY_DECODE_ERROR | |
| {"PUBLIC_KEY_DECODE_ERROR", ERR_LIB_X509, X509_R_PUBLIC_KEY_DECODE_ERROR}, | |
| #else | |
| {"PUBLIC_KEY_DECODE_ERROR", 11, 125}, | |
| #endif | |
| #ifdef X509_R_PUBLIC_KEY_ENCODE_ERROR | |
| {"PUBLIC_KEY_ENCODE_ERROR", ERR_LIB_X509, X509_R_PUBLIC_KEY_ENCODE_ERROR}, | |
| #else | |
| {"PUBLIC_KEY_ENCODE_ERROR", 11, 126}, | |
| #endif | |
| #ifdef X509_R_SHOULD_RETRY | |
| {"SHOULD_RETRY", ERR_LIB_X509, X509_R_SHOULD_RETRY}, | |
| #else | |
| {"SHOULD_RETRY", 11, 106}, | |
| #endif | |
| #ifdef X509_R_UNABLE_TO_FIND_PARAMETERS_IN_CHAIN | |
| {"UNABLE_TO_FIND_PARAMETERS_IN_CHAIN", ERR_LIB_X509, X509_R_UNABLE_TO_FIND_PARAMETERS_IN_CHAIN}, | |
| #else | |
| {"UNABLE_TO_FIND_PARAMETERS_IN_CHAIN", 11, 107}, | |
| #endif | |
| #ifdef X509_R_UNABLE_TO_GET_CERTS_PUBLIC_KEY | |
| {"UNABLE_TO_GET_CERTS_PUBLIC_KEY", ERR_LIB_X509, X509_R_UNABLE_TO_GET_CERTS_PUBLIC_KEY}, | |
| #else | |
| {"UNABLE_TO_GET_CERTS_PUBLIC_KEY", 11, 108}, | |
| #endif | |
| #ifdef X509_R_UNKNOWN_KEY_TYPE | |
| {"UNKNOWN_KEY_TYPE", ERR_LIB_X509, X509_R_UNKNOWN_KEY_TYPE}, | |
| #else | |
| {"UNKNOWN_KEY_TYPE", 11, 117}, | |
| #endif | |
| #ifdef X509_R_UNKNOWN_NID | |
| {"UNKNOWN_NID", ERR_LIB_X509, X509_R_UNKNOWN_NID}, | |
| #else | |
| {"UNKNOWN_NID", 11, 109}, | |
| #endif | |
| #ifdef X509_R_UNKNOWN_PURPOSE_ID | |
| {"UNKNOWN_PURPOSE_ID", ERR_LIB_X509, X509_R_UNKNOWN_PURPOSE_ID}, | |
| #else | |
| {"UNKNOWN_PURPOSE_ID", 11, 121}, | |
| #endif | |
| #ifdef X509_R_UNKNOWN_SIGID_ALGS | |
| {"UNKNOWN_SIGID_ALGS", ERR_LIB_X509, X509_R_UNKNOWN_SIGID_ALGS}, | |
| #else | |
| {"UNKNOWN_SIGID_ALGS", 11, 144}, | |
| #endif | |
| #ifdef X509_R_UNKNOWN_TRUST_ID | |
| {"UNKNOWN_TRUST_ID", ERR_LIB_X509, X509_R_UNKNOWN_TRUST_ID}, | |
| #else | |
| {"UNKNOWN_TRUST_ID", 11, 120}, | |
| #endif | |
| #ifdef X509_R_UNSUPPORTED_ALGORITHM | |
| {"UNSUPPORTED_ALGORITHM", ERR_LIB_X509, X509_R_UNSUPPORTED_ALGORITHM}, | |
| #else | |
| {"UNSUPPORTED_ALGORITHM", 11, 111}, | |
| #endif | |
| #ifdef X509_R_UNSUPPORTED_VERSION | |
| {"UNSUPPORTED_VERSION", ERR_LIB_X509, X509_R_UNSUPPORTED_VERSION}, | |
| #else | |
| {"UNSUPPORTED_VERSION", 11, 145}, | |
| #endif | |
| #ifdef X509_R_WRONG_LOOKUP_TYPE | |
| {"WRONG_LOOKUP_TYPE", ERR_LIB_X509, X509_R_WRONG_LOOKUP_TYPE}, | |
| #else | |
| {"WRONG_LOOKUP_TYPE", 11, 112}, | |
| #endif | |
| #ifdef X509_R_WRONG_TYPE | |
| {"WRONG_TYPE", ERR_LIB_X509, X509_R_WRONG_TYPE}, | |
| #else | |
| {"WRONG_TYPE", 11, 122}, | |
| #endif | |
| {NULL, 0, 0} /* sentinel */ | |
| }; | |
| /* | |
| * Interface to the ncurses panel library | |
| * | |
| * Original version by Thomas Gellekum | |
| */ | |
| /* Release Number */ | |
| static const char PyCursesVersion[] = "2.1"; | |
| /* Includes */ | |
| // clinic/_curses_panel.c.h uses internal pycore_modsupport.h API | |
| #ifndef Py_BUILD_CORE_BUILTIN | |
| # define Py_BUILD_CORE_MODULE 1 | |
| #endif | |
| #include "Python.h" | |
| #define CURSES_PANEL_MODULE | |
| #include "py_curses.h" | |
| #if defined(HAVE_NCURSESW_PANEL_H) | |
| # include <ncursesw/panel.h> | |
| #elif defined(HAVE_NCURSES_PANEL_H) | |
| # include <ncurses/panel.h> | |
| #elif defined(HAVE_PANEL_H) | |
| # include <panel.h> | |
| #endif | |
| typedef struct { | |
| PyObject *error; | |
| PyTypeObject *PyCursesPanel_Type; | |
| } _curses_panel_state; | |
| typedef struct PyCursesPanelObject PyCursesPanelObject; | |
| static inline _curses_panel_state * | |
| get_curses_panel_state(PyObject *module) | |
| { | |
| void *state = PyModule_GetState(module); | |
| assert(state != NULL); | |
| return (_curses_panel_state *)state; | |
| } | |
| static inline _curses_panel_state * | |
| get_curses_panel_state_by_panel(PyCursesPanelObject *panel) | |
| { | |
| /* | |
| * Note: 'state' may be NULL if Py_TYPE(panel) is not a heap | |
| * type associated with this module, but the compiler would | |
| * have likely already complained with an "invalid pointer | |
| * type" at compile-time. | |
| * | |
| * To make it more robust, all functions recovering a module's | |
| * state from an object should expect to return NULL with an | |
| * exception set (in contrast to functions recovering a module's | |
| * state from a module itself). | |
| */ | |
| void *state = PyType_GetModuleState(Py_TYPE(panel)); | |
| assert(state != NULL); | |
| return (_curses_panel_state *)state; | |
| } | |
| static int | |
| _curses_panel_clear(PyObject *mod) | |
| { | |
| _curses_panel_state *state = get_curses_panel_state(mod); | |
| Py_CLEAR(state->error); | |
| Py_CLEAR(state->PyCursesPanel_Type); | |
| return 0; | |
| } | |
| static int | |
| _curses_panel_traverse(PyObject *mod, visitproc visit, void *arg) | |
| { | |
| Py_VISIT(Py_TYPE(mod)); | |
| _curses_panel_state *state = get_curses_panel_state(mod); | |
| Py_VISIT(state->error); | |
| Py_VISIT(state->PyCursesPanel_Type); | |
| return 0; | |
| } | |
| static void | |
| _curses_panel_free(void *mod) | |
| { | |
| (void)_curses_panel_clear((PyObject *)mod); | |
| } | |
| /* Utility Error Procedures | |
| * | |
| * The naming and implementations are identical to those in _cursesmodule.c. | |
| * Functions that are not yet needed (for instance, reporting an ERR value | |
| * from a module-wide function, namely curses_panel_set_error()) are | |
| * omitted and should only be added if needed. | |
| */ | |
| static void | |
| _curses_panel_format_error(_curses_panel_state *state, | |
| const char *curses_funcname, | |
| const char *python_funcname, | |
| const char *return_value, | |
| const char *default_message) | |
| { | |
| assert(!PyErr_Occurred()); | |
| if (python_funcname == NULL && curses_funcname == NULL) { | |
| PyErr_SetString(state->error, default_message); | |
| } | |
| else if (python_funcname == NULL) { | |
| (void)PyErr_Format(state->error, CURSES_ERROR_FORMAT, | |
| curses_funcname, return_value); | |
| } | |
| else { | |
| assert(python_funcname != NULL); | |
| (void)PyErr_Format(state->error, CURSES_ERROR_VERBOSE_FORMAT, | |
| curses_funcname, python_funcname, return_value); | |
| } | |
| } | |
| /* | |
| * Format a curses error for a function that returned ERR. | |
| * | |
| * Specify a non-NULL 'python_funcname' when the latter differs from | |
| * 'curses_funcname'. If both names are NULL, uses the 'catchall_ERR' | |
| * message instead. | |
| */ | |
| static void | |
| _curses_panel_set_error(_curses_panel_state *state, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| _curses_panel_format_error(state, curses_funcname, python_funcname, | |
| "ERR", catchall_ERR); | |
| } | |
| /* | |
| * Format a curses error for a function that returned NULL. | |
| * | |
| * Specify a non-NULL 'python_funcname' when the latter differs from | |
| * 'curses_funcname'. If both names are NULL, uses the 'catchall_NULL' | |
| * message instead. | |
| */ | |
| static void | |
| _curses_panel_set_null_error(_curses_panel_state *state, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| _curses_panel_format_error(state, curses_funcname, python_funcname, | |
| "NULL", catchall_NULL); | |
| } | |
| /* Same as _curses_panel_set_null_error() for a module object. */ | |
| static void | |
| curses_panel_set_null_error(PyObject *module, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| _curses_panel_state *state = get_curses_panel_state(module); | |
| _curses_panel_set_null_error(state, curses_funcname, python_funcname); | |
| } | |
| /* Same as _curses_panel_set_error() for a panel object. */ | |
| static void | |
| curses_panel_panel_set_error(PyCursesPanelObject *panel, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| _curses_panel_state *state = get_curses_panel_state_by_panel(panel); | |
| _curses_panel_set_error(state, curses_funcname, python_funcname); | |
| } | |
| /* Same as _curses_panel_set_null_error() for a panel object. */ | |
| static void | |
| curses_panel_panel_set_null_error(PyCursesPanelObject *panel, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| _curses_panel_state *state = get_curses_panel_state_by_panel(panel); | |
| _curses_panel_set_null_error(state, curses_funcname, python_funcname); | |
| } | |
| /* | |
| * Indicate that a panel object couldn't be found. | |
| * | |
| * Use it for the following constructions: | |
| * | |
| * PROC caller_funcname: | |
| * pan = called_funcname() | |
| * find_po(panel) | |
| * | |
| * PROC caller_funcname: | |
| * find_po(self->pan) | |
| */ | |
| static void | |
| curses_panel_notfound_error(const char *called_funcname, | |
| const char *caller_funcname) | |
| { | |
| assert(!(called_funcname == NULL && caller_funcname == NULL)); | |
| if (caller_funcname == NULL) { | |
| (void)PyErr_Format(PyExc_RuntimeError, | |
| "%s(): cannot find panel object", | |
| called_funcname); | |
| } | |
| else { | |
| (void)PyErr_Format(PyExc_RuntimeError, | |
| "%s() (called by %s()): cannot find panel object", | |
| called_funcname, caller_funcname); | |
| } | |
| } | |
| /* Utility Functions */ | |
| /* | |
| * Check the return code from a curses function, returning None | |
| * on success and setting an exception on error. | |
| */ | |
| /* | |
| * Return None if 'code' is different from ERR (implementation-defined). | |
| * Otherwise, set an exception using curses_panel_panel_set_error() and | |
| * the remaining arguments, and return NULL. | |
| */ | |
| static PyObject * | |
| curses_panel_panel_check_err(PyCursesPanelObject *panel, int code, | |
| const char *curses_funcname, | |
| const char *python_funcname) | |
| { | |
| if (code != ERR) { | |
| Py_RETURN_NONE; | |
| } | |
| curses_panel_panel_set_error(panel, curses_funcname, python_funcname); | |
| return NULL; | |
| } | |
| /***************************************************************************** | |
| The Panel Object | |
| ******************************************************************************/ | |
| /* Definition of the panel object and panel type */ | |
| typedef struct PyCursesPanelObject { | |
| PyObject_HEAD | |
| PANEL *pan; | |
| PyCursesWindowObject *wo; /* for reference counts */ | |
| } PyCursesPanelObject; | |
| #define _PyCursesPanelObject_CAST(op) ((PyCursesPanelObject *)(op)) | |
| /* Some helper functions. The problem is that there's always a window | |
| associated with a panel. To ensure that Python's GC doesn't pull | |
| this window from under our feet we need to keep track of references | |
| to the corresponding window object within Python. We can't use | |
| dupwin(oldwin) to keep a copy of the curses WINDOW because the | |
| contents of oldwin is copied only once; code like | |
| win = newwin(...) | |
| pan = win.panel() | |
| win.addstr(some_string) | |
| pan.window().addstr(other_string) | |
| will fail. */ | |
| /* We keep a linked list of PyCursesPanelObjects, lop. A list should | |
| suffice, I don't expect more than a handful or at most a few | |
| dozens of panel objects within a typical program. */ | |
| typedef struct _list_of_panels { | |
| PyCursesPanelObject *po; | |
| struct _list_of_panels *next; | |
| } list_of_panels; | |
| /* list anchor */ | |
| static list_of_panels *lop; | |
| /* Insert a new panel object into lop */ | |
| static int | |
| insert_lop(PyCursesPanelObject *po) | |
| { | |
| list_of_panels *new; | |
| if ((new = (list_of_panels *)PyMem_Malloc(sizeof(list_of_panels))) == NULL) { | |
| PyErr_NoMemory(); | |
| return -1; | |
| } | |
| new->po = po; | |
| new->next = lop; | |
| lop = new; | |
| return 0; | |
| } | |
| /* Remove the panel object from lop. | |
| * | |
| * Return -1 on error but do NOT set an exception; otherwise return 0. | |
| */ | |
| static int | |
| remove_lop(PyCursesPanelObject *po) | |
| { | |
| list_of_panels *temp, *n; | |
| temp = lop; | |
| if (temp->po == po) { | |
| lop = temp->next; | |
| PyMem_Free(temp); | |
| return 0; | |
| } | |
| while (temp->next == NULL || temp->next->po != po) { | |
| if (temp->next == NULL) { | |
| return -1; | |
| } | |
| temp = temp->next; | |
| } | |
| n = temp->next->next; | |
| PyMem_Free(temp->next); | |
| temp->next = n; | |
| return 0; | |
| } | |
| /* Return the panel object that corresponds to pan */ | |
| static PyCursesPanelObject * | |
| find_po_impl(PANEL *pan) | |
| { | |
| list_of_panels *temp; | |
| for (temp = lop; temp->po->pan != pan; temp = temp->next) | |
| if (temp->next == NULL) return NULL; /* not found!? */ | |
| return temp->po; | |
| } | |
| /* Same as find_po_impl() but with caller context information. */ | |
| static PyCursesPanelObject * | |
| find_po(PANEL *pan, const char *called_funcname, const char *caller_funcname) | |
| { | |
| PyCursesPanelObject *res = find_po_impl(pan); | |
| if (res == NULL) { | |
| curses_panel_notfound_error(called_funcname, caller_funcname); | |
| } | |
| return res; | |
| } | |
| /*[clinic input] | |
| module _curses_panel | |
| class _curses_panel.panel "PyCursesPanelObject *" "&PyCursesPanel_Type" | |
| [clinic start generated code]*/ | |
| /*[clinic end generated code: output=da39a3ee5e6b4b0d input=2f4ef263ca850a31]*/ | |
| #include "clinic/_curses_panel.c.h" | |
| /* ------------- PANEL routines --------------- */ | |
| /*[clinic input] | |
| _curses_panel.panel.bottom | |
| Push the panel to the bottom of the stack. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_bottom_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=7aa7d14d7e1d1ce6 input=b6c920c071b61e2e]*/ | |
| { | |
| int rtn = bottom_panel(self->pan); | |
| return curses_panel_panel_check_err(self, rtn, "bottom_panel", "bottom"); | |
| } | |
| /*[clinic input] | |
| @permit_long_docstring_body | |
| _curses_panel.panel.hide | |
| Hide the panel. | |
| This does not delete the object, it just makes the window on screen invisible. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_hide_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=a7bbbd523e1eab49 input=9071b463a39a1a6a]*/ | |
| { | |
| int rtn = hide_panel(self->pan); | |
| return curses_panel_panel_check_err(self, rtn, "hide_panel", "hide"); | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.show | |
| Display the panel (which might have been hidden). | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_show_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=6b4553ab45c97769 input=57b167bbefaa3755]*/ | |
| { | |
| int rtn = show_panel(self->pan); | |
| return curses_panel_panel_check_err(self, rtn, "show_panel", "show"); | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.top | |
| Push panel to the top of the stack. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_top_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=0f5f2f8cdd2d1777 input=be33975ec3ca0e9a]*/ | |
| { | |
| int rtn = top_panel(self->pan); | |
| return curses_panel_panel_check_err(self, rtn, "top_panel", "top"); | |
| } | |
| /* Allocation and deallocation of Panel Objects */ | |
| static PyObject * | |
| PyCursesPanel_New(_curses_panel_state *state, PANEL *pan, | |
| PyCursesWindowObject *wo) | |
| { | |
| assert(state != NULL); | |
| PyTypeObject *type = state->PyCursesPanel_Type; | |
| assert(type != NULL); | |
| assert(type->tp_alloc != NULL); | |
| PyCursesPanelObject *po = (PyCursesPanelObject *)type->tp_alloc(type, 0); | |
| if (po == NULL) { | |
| return NULL; | |
| } | |
| po->pan = pan; | |
| if (insert_lop(po) < 0) { | |
| po->wo = NULL; | |
| Py_DECREF(po); | |
| return NULL; | |
| } | |
| po->wo = (PyCursesWindowObject*)Py_NewRef(wo); | |
| return (PyObject *)po; | |
| } | |
| static int | |
| PyCursesPanel_Clear(PyObject *op) | |
| { | |
| PyCursesPanelObject *self = _PyCursesPanelObject_CAST(op); | |
| PyObject *extra = (PyObject *)panel_userptr(self->pan); | |
| if (extra != NULL) { | |
| Py_DECREF(extra); | |
| if (set_panel_userptr(self->pan, NULL) == ERR) { | |
| curses_panel_panel_set_error(self, "set_panel_userptr", NULL); | |
| return -1; | |
| } | |
| } | |
| // self->wo should not be cleared because an associated WINDOW may exist | |
| return 0; | |
| } | |
| static void | |
| PyCursesPanel_Dealloc(PyObject *self) | |
| { | |
| PyTypeObject *tp = Py_TYPE(self); | |
| PyObject_GC_UnTrack(self); | |
| PyCursesPanelObject *po = _PyCursesPanelObject_CAST(self); | |
| if (PyCursesPanel_Clear(self) < 0) { | |
| PyErr_FormatUnraisable("Exception ignored in PyCursesPanel_Dealloc()"); | |
| } | |
| if (del_panel(po->pan) == ERR && !PyErr_Occurred()) { | |
| curses_panel_panel_set_error(po, "del_panel", "__del__"); | |
| PyErr_FormatUnraisable("Exception ignored in PyCursesPanel_Dealloc()"); | |
| } | |
| if (po->wo != NULL) { | |
| Py_DECREF(po->wo); | |
| if (remove_lop(po) < 0) { | |
| PyErr_SetString(PyExc_RuntimeError, "__del__: no panel object to delete"); | |
| PyErr_FormatUnraisable("Exception ignored in PyCursesPanel_Dealloc()"); | |
| } | |
| } | |
| tp->tp_free(po); | |
| Py_DECREF(tp); | |
| } | |
| static int | |
| PyCursesPanel_Traverse(PyObject *op, visitproc visit, void *arg) | |
| { | |
| PyCursesPanelObject *self = _PyCursesPanelObject_CAST(op); | |
| Py_VISIT(Py_TYPE(op)); | |
| Py_VISIT(panel_userptr(self->pan)); | |
| Py_VISIT(self->wo); | |
| return 0; | |
| } | |
| /* panel_above(NULL) returns the bottom panel in the stack. To get | |
| this behaviour we use curses.panel.bottom_panel(). */ | |
| /*[clinic input] | |
| _curses_panel.panel.above | |
| Return the panel above the current panel. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_above_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=70ac06d25fd3b4da input=c059994022976788]*/ | |
| { | |
| PANEL *pan; | |
| PyCursesPanelObject *po; | |
| pan = panel_above(self->pan); | |
| if (pan == NULL) { /* valid output: it means no panel exists yet */ | |
| Py_RETURN_NONE; | |
| } | |
| po = find_po(pan, "panel_above", "above"); | |
| return Py_XNewRef(po); | |
| } | |
| /* panel_below(NULL) returns the top panel in the stack. To get | |
| this behaviour we use curses.panel.top_panel(). */ | |
| /*[clinic input] | |
| _curses_panel.panel.below | |
| Return the panel below the current panel. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_below_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=282861122e06e3de input=cc08f61936d297c6]*/ | |
| { | |
| PANEL *pan; | |
| PyCursesPanelObject *po; | |
| pan = panel_below(self->pan); | |
| if (pan == NULL) { /* valid output: it means no panel exists yet */ | |
| Py_RETURN_NONE; | |
| } | |
| po = find_po(pan, "panel_below", "below"); | |
| return Py_XNewRef(po); | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.hidden | |
| Return True if the panel is hidden (not visible), False otherwise. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_hidden_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=66eebd1ab4501a71 input=453d4b4fce25e21a]*/ | |
| { | |
| if (panel_hidden(self->pan)) | |
| Py_RETURN_TRUE; | |
| else | |
| Py_RETURN_FALSE; | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.move | |
| y: int | |
| x: int | |
| / | |
| Move the panel to the screen coordinates (y, x). | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_move_impl(PyCursesPanelObject *self, int y, int x) | |
| /*[clinic end generated code: output=d867535a89777415 input=e0b36b78acc03fba]*/ | |
| { | |
| int rtn = move_panel(self->pan, y, x); | |
| return curses_panel_panel_check_err(self, rtn, "move_panel", "move"); | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.window | |
| Return the window object associated with the panel. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_window_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=5f05940d4106b4cb input=6067353d2c307901]*/ | |
| { | |
| return Py_NewRef(self->wo); | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.replace | |
| win: object(type="PyCursesWindowObject *", subclass_of="&PyCursesWindow_Type") | |
| / | |
| Change the window associated with the panel to the window win. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_replace_impl(PyCursesPanelObject *self, | |
| PyCursesWindowObject *win) | |
| /*[clinic end generated code: output=2253a95f7b287255 input=4b1c4283987d9dfa]*/ | |
| { | |
| PyCursesPanelObject *po = find_po(self->pan, "replace", NULL); | |
| if (po == NULL) { | |
| return NULL; | |
| } | |
| int rtn = replace_panel(self->pan, win->win); | |
| if (rtn == ERR) { | |
| curses_panel_panel_set_error(self, "replace_panel", "replace"); | |
| return NULL; | |
| } | |
| Py_SETREF(po->wo, (PyCursesWindowObject*)Py_NewRef(win)); | |
| Py_RETURN_NONE; | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.set_userptr | |
| obj: object | |
| / | |
| Set the panel's user pointer to obj. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_set_userptr_impl(PyCursesPanelObject *self, | |
| PyObject *obj) | |
| /*[clinic end generated code: output=7fa1fd23f69db71e input=d2c6a9dbefabbf39]*/ | |
| { | |
| PyCursesInitialised; | |
| Py_INCREF(obj); | |
| PyObject *oldobj = (PyObject *) panel_userptr(self->pan); | |
| int rc = set_panel_userptr(self->pan, (void*)obj); | |
| if (rc == ERR) { | |
| /* In case of an ncurses error, decref the new object again */ | |
| Py_DECREF(obj); | |
| curses_panel_panel_set_error(self, "set_panel_userptr", "set_userptr"); | |
| return NULL; | |
| } | |
| Py_XDECREF(oldobj); | |
| Py_RETURN_NONE; | |
| } | |
| /*[clinic input] | |
| _curses_panel.panel.userptr | |
| Return the user pointer for the panel. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_panel_userptr_impl(PyCursesPanelObject *self) | |
| /*[clinic end generated code: output=e849c307b5dc9237 input=f78b7a47aef0fd50]*/ | |
| { | |
| PyCursesInitialised; | |
| PyObject *obj = (PyObject *) panel_userptr(self->pan); | |
| if (obj == NULL) { | |
| curses_panel_panel_set_null_error(self, "panel_userptr", "userptr"); | |
| return NULL; | |
| } | |
| return Py_NewRef(obj); | |
| } | |
| /* Module interface */ | |
| static PyMethodDef PyCursesPanel_Methods[] = { | |
| _CURSES_PANEL_PANEL_ABOVE_METHODDEF | |
| _CURSES_PANEL_PANEL_BELOW_METHODDEF | |
| _CURSES_PANEL_PANEL_BOTTOM_METHODDEF | |
| _CURSES_PANEL_PANEL_HIDDEN_METHODDEF | |
| _CURSES_PANEL_PANEL_HIDE_METHODDEF | |
| _CURSES_PANEL_PANEL_MOVE_METHODDEF | |
| _CURSES_PANEL_PANEL_REPLACE_METHODDEF | |
| _CURSES_PANEL_PANEL_SET_USERPTR_METHODDEF | |
| _CURSES_PANEL_PANEL_SHOW_METHODDEF | |
| _CURSES_PANEL_PANEL_TOP_METHODDEF | |
| _CURSES_PANEL_PANEL_USERPTR_METHODDEF | |
| _CURSES_PANEL_PANEL_WINDOW_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| /* -------------------------------------------------------*/ | |
| static PyType_Slot PyCursesPanel_Type_slots[] = { | |
| {Py_tp_clear, PyCursesPanel_Clear}, | |
| {Py_tp_dealloc, PyCursesPanel_Dealloc}, | |
| {Py_tp_traverse, PyCursesPanel_Traverse}, | |
| {Py_tp_methods, PyCursesPanel_Methods}, | |
| {0, 0}, | |
| }; | |
| static PyType_Spec PyCursesPanel_Type_spec = { | |
| .name = "_curses_panel.panel", | |
| .basicsize = sizeof(PyCursesPanelObject), | |
| .flags = ( | |
| Py_TPFLAGS_DEFAULT | |
| | Py_TPFLAGS_DISALLOW_INSTANTIATION | |
| | Py_TPFLAGS_IMMUTABLETYPE | |
| | Py_TPFLAGS_HAVE_GC | |
| ), | |
| .slots = PyCursesPanel_Type_slots | |
| }; | |
| /* Wrapper for panel_above(NULL). This function returns the bottom | |
| panel of the stack, so it's renamed to bottom_panel(). | |
| panel.above() *requires* a panel object in the first place which | |
| may be undesirable. */ | |
| /*[clinic input] | |
| _curses_panel.bottom_panel | |
| Return the bottom panel in the panel stack. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_bottom_panel_impl(PyObject *module) | |
| /*[clinic end generated code: output=3aba9f985f4c2bd0 input=634c2a8078b3d7e4]*/ | |
| { | |
| PANEL *pan; | |
| PyCursesPanelObject *po; | |
| PyCursesInitialised; | |
| pan = panel_above(NULL); | |
| if (pan == NULL) { /* valid output: it means no panel exists yet */ | |
| Py_RETURN_NONE; | |
| } | |
| po = find_po(pan, "panel_above", "bottom_panel"); | |
| return Py_XNewRef(po); | |
| } | |
| /*[clinic input] | |
| _curses_panel.new_panel | |
| win: object(type="PyCursesWindowObject *", subclass_of="&PyCursesWindow_Type") | |
| / | |
| Return a panel object, associating it with the given window win. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_new_panel_impl(PyObject *module, PyCursesWindowObject *win) | |
| /*[clinic end generated code: output=45e948e0176a9bd2 input=74d4754e0ebe4800]*/ | |
| { | |
| PANEL *pan = new_panel(win->win); | |
| if (pan == NULL) { | |
| curses_panel_set_null_error(module, "new_panel", NULL); | |
| return NULL; | |
| } | |
| _curses_panel_state *state = get_curses_panel_state(module); | |
| return PyCursesPanel_New(state, pan, win); | |
| } | |
| /* Wrapper for panel_below(NULL). This function returns the top panel | |
| of the stack, so it's renamed to top_panel(). panel.below() | |
| *requires* a panel object in the first place which may be | |
| undesirable. */ | |
| /*[clinic input] | |
| _curses_panel.top_panel | |
| Return the top panel in the panel stack. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_top_panel_impl(PyObject *module) | |
| /*[clinic end generated code: output=86704988bea8508e input=e62d6278dba39e79]*/ | |
| { | |
| PANEL *pan; | |
| PyCursesPanelObject *po; | |
| PyCursesInitialised; | |
| pan = panel_below(NULL); | |
| if (pan == NULL) { /* valid output: it means no panel exists yet */ | |
| Py_RETURN_NONE; | |
| } | |
| po = find_po(pan, "panel_below", "top_panel"); | |
| return Py_XNewRef(po); | |
| } | |
| /*[clinic input] | |
| _curses_panel.update_panels | |
| Updates the virtual screen after changes in the panel stack. | |
| This does not call curses.doupdate(), so you'll have to do this yourself. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _curses_panel_update_panels_impl(PyObject *module) | |
| /*[clinic end generated code: output=2f3b4c2e03d90ded input=5299624c9a708621]*/ | |
| { | |
| PyCursesInitialised; | |
| update_panels(); | |
| Py_RETURN_NONE; | |
| } | |
| /* List of functions defined in the module */ | |
| static PyMethodDef PyCurses_methods[] = { | |
| _CURSES_PANEL_BOTTOM_PANEL_METHODDEF | |
| _CURSES_PANEL_NEW_PANEL_METHODDEF | |
| _CURSES_PANEL_TOP_PANEL_METHODDEF | |
| _CURSES_PANEL_UPDATE_PANELS_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| /* Initialization function for the module */ | |
| static int | |
| _curses_panel_exec(PyObject *mod) | |
| { | |
| _curses_panel_state *state = get_curses_panel_state(mod); | |
| /* Initialize object type */ | |
| state->PyCursesPanel_Type = (PyTypeObject *)PyType_FromModuleAndSpec( | |
| mod, &PyCursesPanel_Type_spec, NULL); | |
| if (state->PyCursesPanel_Type == NULL) { | |
| return -1; | |
| } | |
| if (PyModule_AddType(mod, state->PyCursesPanel_Type) < 0) { | |
| return -1; | |
| } | |
| import_curses(); | |
| if (PyErr_Occurred()) { | |
| return -1; | |
| } | |
| /* For exception _curses_panel.error */ | |
| state->error = PyErr_NewException( | |
| "_curses_panel.error", NULL, NULL); | |
| if (PyModule_AddObjectRef(mod, "error", state->error) < 0) { | |
| return -1; | |
| } | |
| /* Make the version available */ | |
| PyObject *v = PyUnicode_FromString(PyCursesVersion); | |
| if (v == NULL) { | |
| return -1; | |
| } | |
| PyObject *d = PyModule_GetDict(mod); | |
| if (PyDict_SetItemString(d, "version", v) < 0) { | |
| Py_DECREF(v); | |
| return -1; | |
| } | |
| if (PyDict_SetItemString(d, "__version__", v) < 0) { | |
| Py_DECREF(v); | |
| return -1; | |
| } | |
| Py_DECREF(v); | |
| return 0; | |
| } | |
| static PyModuleDef_Slot _curses_slots[] = { | |
| {Py_mod_exec, _curses_panel_exec}, | |
| // XXX gh-103092: fix isolation. | |
| {Py_mod_multiple_interpreters, Py_MOD_MULTIPLE_INTERPRETERS_NOT_SUPPORTED}, | |
| //{Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| static struct PyModuleDef _curses_panelmodule = { | |
| PyModuleDef_HEAD_INIT, | |
| .m_name = "_curses_panel", | |
| .m_size = sizeof(_curses_panel_state), | |
| .m_methods = PyCurses_methods, | |
| .m_slots = _curses_slots, | |
| .m_traverse = _curses_panel_traverse, | |
| .m_clear = _curses_panel_clear, | |
| .m_free = _curses_panel_free | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit__curses_panel(void) | |
| { | |
| return PyModuleDef_Init(&_curses_panelmodule); | |
| } | |
| /* fcntl module */ | |
| // Argument Clinic uses the internal C API | |
| #ifndef Py_BUILD_CORE_BUILTIN | |
| # define Py_BUILD_CORE_MODULE 1 | |
| #endif | |
| #include "Python.h" | |
| #include <errno.h> // EINTR | |
| #include <fcntl.h> // fcntl() | |
| #include <string.h> // memcpy() | |
| #include <sys/ioctl.h> // ioctl() | |
| #ifdef HAVE_SYS_FILE_H | |
| # include <sys/file.h> // flock() | |
| #endif | |
| #ifdef HAVE_LINUX_FS_H | |
| # include <linux/fs.h> | |
| #endif | |
| #ifdef HAVE_STROPTS_H | |
| # include <stropts.h> // I_FLUSHBAND | |
| #endif | |
| #define GUARDSZ 8 | |
| // NUL followed by random bytes. | |
| static const char guard[GUARDSZ] _Py_NONSTRING = "\x00\xfa\x69\xc4\x67\xa3\x6c\x58"; | |
| /*[clinic input] | |
| module fcntl | |
| [clinic start generated code]*/ | |
| /*[clinic end generated code: output=da39a3ee5e6b4b0d input=124b58387c158179]*/ | |
| #include "clinic/fcntlmodule.c.h" | |
| /*[clinic input] | |
| fcntl.fcntl | |
| fd: fildes | |
| cmd as code: int | |
| arg: object(c_default='NULL') = 0 | |
| / | |
| Perform the operation cmd on file descriptor fd. | |
| The values used for cmd are operating system dependent, and are | |
| available as constants in the fcntl module, using the same names as used | |
| in the relevant C header files. The argument arg is optional, and | |
| defaults to 0; it may be an integer, a bytes-like object or a string. | |
| If arg is given as a string, it will be encoded to binary using the | |
| UTF-8 encoding. | |
| If the arg given is an integer or if none is specified, the result value | |
| is an integer corresponding to the return value of the fcntl() call in | |
| the C code. | |
| If arg is given as a bytes-like object, the return value of fcntl() is a | |
| bytes object of that length, containing the resulting value put in the | |
| arg buffer by the operating system. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| fcntl_fcntl_impl(PyObject *module, int fd, int code, PyObject *arg) | |
| /*[clinic end generated code: output=888fc93b51c295bd input=77340720f11665da]*/ | |
| { | |
| int ret; | |
| int async_err = 0; | |
| if (PySys_Audit("fcntl.fcntl", "iiO", fd, code, arg ? arg : Py_None) < 0) { | |
| return NULL; | |
| } | |
| if (arg == NULL || PyIndex_Check(arg)) { | |
| unsigned int int_arg = 0; | |
| if (arg != NULL) { | |
| if (!PyArg_Parse(arg, "I", &int_arg)) { | |
| return NULL; | |
| } | |
| } | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = fcntl(fd, code, (int)int_arg); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| return PyLong_FromLong(ret); | |
| } | |
| if (PyUnicode_Check(arg) || PyObject_CheckBuffer(arg)) { | |
| Py_buffer view; | |
| #define FCNTL_BUFSZ 1024 | |
| /* argument plus NUL byte plus guard to detect a buffer overflow */ | |
| char buf[FCNTL_BUFSZ+GUARDSZ]; | |
| if (!PyArg_Parse(arg, "s*", &view)) { | |
| return NULL; | |
| } | |
| Py_ssize_t len = view.len; | |
| if (len <= FCNTL_BUFSZ) { | |
| memcpy(buf, view.buf, len); | |
| memcpy(buf + len, guard, GUARDSZ); | |
| PyBuffer_Release(&view); | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = fcntl(fd, code, buf); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| if (memcmp(buf + len, guard, GUARDSZ) != 0) { | |
| PyErr_SetString(PyExc_SystemError, "buffer overflow"); | |
| return NULL; | |
| } | |
| return PyBytes_FromStringAndSize(buf, len); | |
| } | |
| else { | |
| PyBytesWriter *writer = PyBytesWriter_Create(len); | |
| if (writer == NULL) { | |
| PyBuffer_Release(&view); | |
| return NULL; | |
| } | |
| char *ptr = PyBytesWriter_GetData(writer); | |
| memcpy(ptr, view.buf, len); | |
| PyBuffer_Release(&view); | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = fcntl(fd, code, ptr); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| if (!async_err) { | |
| PyErr_SetFromErrno(PyExc_OSError); | |
| } | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| if (ptr[len] != '\0') { | |
| PyErr_SetString(PyExc_SystemError, "buffer overflow"); | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| return PyBytesWriter_Finish(writer); | |
| } | |
| #undef FCNTL_BUFSZ | |
| } | |
| PyErr_Format(PyExc_TypeError, | |
| "fcntl() argument 3 must be an integer, " | |
| "a bytes-like object, or a string, not %T", | |
| arg); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| fcntl.ioctl | |
| fd: fildes | |
| request as code: unsigned_long(bitwise=True) | |
| arg: object(c_default='NULL') = 0 | |
| mutate_flag as mutate_arg: bool = True | |
| / | |
| Perform the operation request on file descriptor fd. | |
| The values used for request are operating system dependent, and are | |
| available as constants in the fcntl or termios library modules, using | |
| the same names as used in the relevant C header files. | |
| The argument arg is optional, and defaults to 0; it may be an integer, a | |
| bytes-like object or a string. If arg is given as a string, it will be | |
| encoded to binary using the UTF-8 encoding. | |
| If the arg given is an integer or if none is specified, the result value | |
| is an integer corresponding to the return value of the ioctl() call in | |
| the C code. | |
| If the argument is a mutable buffer (such as a bytearray) and the | |
| mutate_flag argument is true (default) then the buffer is (in effect) | |
| passed to the operating system and changes made by the OS will be | |
| reflected in the contents of the buffer after the call has returned. | |
| The return value is the integer returned by the ioctl() system call. | |
| If the argument is a mutable buffer and the mutable_flag argument is | |
| false, the behavior is as if an immutable buffer had been passed. | |
| If the argument is an immutable buffer then a copy of the buffer is | |
| passed to the operating system and the return value is a bytes object of | |
| the same length containing whatever the operating system put in the | |
| buffer. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| fcntl_ioctl_impl(PyObject *module, int fd, unsigned long code, PyObject *arg, | |
| int mutate_arg) | |
| /*[clinic end generated code: output=f72baba2454d7a62 input=954fe75c208cc492]*/ | |
| { | |
| /* We use the unsigned non-checked 'I' format for the 'code' parameter | |
| because the system expects it to be a 32bit bit field value | |
| regardless of it being passed as an int or unsigned long on | |
| various platforms. See the termios.TIOCSWINSZ constant across | |
| platforms for an example of this. | |
| If any of the 64bit platforms ever decide to use more than 32bits | |
| in their unsigned long ioctl codes this will break and need | |
| special casing based on the platform being built on. | |
| */ | |
| int ret; | |
| int async_err = 0; | |
| if (PySys_Audit("fcntl.ioctl", "ikO", fd, code, arg ? arg : Py_None) < 0) { | |
| return NULL; | |
| } | |
| if (arg == NULL || PyIndex_Check(arg)) { | |
| int int_arg = 0; | |
| if (arg != NULL) { | |
| if (!PyArg_Parse(arg, "i", &int_arg)) { | |
| return NULL; | |
| } | |
| } | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = ioctl(fd, code, int_arg); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| return PyLong_FromLong(ret); | |
| } | |
| if (PyUnicode_Check(arg) || PyObject_CheckBuffer(arg)) { | |
| Py_buffer view; | |
| #define IOCTL_BUFSZ 1024 | |
| /* argument plus NUL byte plus guard to detect a buffer overflow */ | |
| char buf[IOCTL_BUFSZ+GUARDSZ]; | |
| if (mutate_arg && !PyBytes_Check(arg) && !PyUnicode_Check(arg)) { | |
| if (PyObject_GetBuffer(arg, &view, PyBUF_WRITABLE) == 0) { | |
| Py_ssize_t len = view.len; | |
| void *ptr = view.buf; | |
| if (len <= IOCTL_BUFSZ) { | |
| memcpy(buf, ptr, len); | |
| memcpy(buf + len, guard, GUARDSZ); | |
| ptr = buf; | |
| } | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = ioctl(fd, code, ptr); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| if (!async_err) { | |
| PyErr_SetFromErrno(PyExc_OSError); | |
| } | |
| PyBuffer_Release(&view); | |
| return NULL; | |
| } | |
| if (ptr == buf) { | |
| memcpy(view.buf, buf, len); | |
| } | |
| PyBuffer_Release(&view); | |
| if (ptr == buf && memcmp(buf + len, guard, GUARDSZ) != 0) { | |
| PyErr_SetString(PyExc_SystemError, "buffer overflow"); | |
| return NULL; | |
| } | |
| return PyLong_FromLong(ret); | |
| } | |
| if (!PyErr_ExceptionMatches(PyExc_BufferError)) { | |
| return NULL; | |
| } | |
| PyErr_Clear(); | |
| } | |
| if (!PyArg_Parse(arg, "s*", &view)) { | |
| return NULL; | |
| } | |
| Py_ssize_t len = view.len; | |
| if (len <= IOCTL_BUFSZ) { | |
| memcpy(buf, view.buf, len); | |
| memcpy(buf + len, guard, GUARDSZ); | |
| PyBuffer_Release(&view); | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = ioctl(fd, code, buf); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| if (memcmp(buf + len, guard, GUARDSZ) != 0) { | |
| PyErr_SetString(PyExc_SystemError, "buffer overflow"); | |
| return NULL; | |
| } | |
| return PyBytes_FromStringAndSize(buf, len); | |
| } | |
| else { | |
| PyBytesWriter *writer = PyBytesWriter_Create(len); | |
| if (writer == NULL) { | |
| PyBuffer_Release(&view); | |
| return NULL; | |
| } | |
| char *ptr = PyBytesWriter_GetData(writer); | |
| memcpy(ptr, view.buf, len); | |
| PyBuffer_Release(&view); | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = ioctl(fd, code, ptr); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| if (ret < 0) { | |
| if (!async_err) { | |
| PyErr_SetFromErrno(PyExc_OSError); | |
| } | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| if (ptr[len] != '\0') { | |
| PyErr_SetString(PyExc_SystemError, "buffer overflow"); | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| return PyBytesWriter_Finish(writer); | |
| } | |
| #undef IOCTL_BUFSZ | |
| } | |
| PyErr_Format(PyExc_TypeError, | |
| "ioctl() argument 3 must be an integer, " | |
| "a bytes-like object, or a string, not %T", | |
| arg); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| fcntl.flock | |
| fd: fildes | |
| operation as code: int | |
| / | |
| Perform the lock operation on file descriptor fd. | |
| See the Unix manual page for flock(2) for details (On some systems, this | |
| function is emulated using fcntl()). | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| fcntl_flock_impl(PyObject *module, int fd, int code) | |
| /*[clinic end generated code: output=84059e2b37d2fc64 input=ade68943e8599f0a]*/ | |
| { | |
| int ret; | |
| int async_err = 0; | |
| if (PySys_Audit("fcntl.flock", "ii", fd, code) < 0) { | |
| return NULL; | |
| } | |
| #ifdef HAVE_FLOCK | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = flock(fd, code); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| #else | |
| #ifndef LOCK_SH | |
| #define LOCK_SH 1 /* shared lock */ | |
| #define LOCK_EX 2 /* exclusive lock */ | |
| #define LOCK_NB 4 /* don't block when locking */ | |
| #define LOCK_UN 8 /* unlock */ | |
| #endif | |
| { | |
| struct flock l; | |
| if (code == LOCK_UN) | |
| l.l_type = F_UNLCK; | |
| else if (code & LOCK_SH) | |
| l.l_type = F_RDLCK; | |
| else if (code & LOCK_EX) | |
| l.l_type = F_WRLCK; | |
| else { | |
| PyErr_SetString(PyExc_ValueError, | |
| "unrecognized flock argument"); | |
| return NULL; | |
| } | |
| l.l_whence = l.l_start = l.l_len = 0; | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = fcntl(fd, (code & LOCK_NB) ? F_SETLK : F_SETLKW, &l); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| } | |
| #endif /* HAVE_FLOCK */ | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| Py_RETURN_NONE; | |
| } | |
| /*[clinic input] | |
| fcntl.lockf | |
| fd: fildes | |
| cmd as code: int | |
| len as lenobj: object(c_default='NULL') = 0 | |
| start as startobj: object(c_default='NULL') = 0 | |
| whence: int = 0 | |
| / | |
| A wrapper around the fcntl() locking calls. | |
| fd is the file descriptor of the file to lock or unlock, and operation | |
| is one of the following values: | |
| LOCK_UN - unlock | |
| LOCK_SH - acquire a shared lock | |
| LOCK_EX - acquire an exclusive lock | |
| When operation is LOCK_SH or LOCK_EX, it can also be bitwise ORed with | |
| LOCK_NB to avoid blocking on lock acquisition. If LOCK_NB is used and | |
| the lock cannot be acquired, an OSError will be raised and the exception | |
| will have an errno attribute set to EACCES or EAGAIN (depending on the | |
| operating system -- for portability, check for either value). | |
| len is the number of bytes to lock, with the default meaning to lock to | |
| EOF. start is the byte offset, relative to whence, to that the lock | |
| starts. whence is as with fileobj.seek(), specifically: | |
| 0 - relative to the start of the file (SEEK_SET) | |
| 1 - relative to the current buffer position (SEEK_CUR) | |
| 2 - relative to the end of the file (SEEK_END) | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| fcntl_lockf_impl(PyObject *module, int fd, int code, PyObject *lenobj, | |
| PyObject *startobj, int whence) | |
| /*[clinic end generated code: output=4985e7a172e7461a input=369bef4d7a1c5ff4]*/ | |
| { | |
| int ret; | |
| int async_err = 0; | |
| if (PySys_Audit("fcntl.lockf", "iiOOi", fd, code, lenobj ? lenobj : Py_None, | |
| startobj ? startobj : Py_None, whence) < 0) { | |
| return NULL; | |
| } | |
| #ifndef LOCK_SH | |
| #define LOCK_SH 1 /* shared lock */ | |
| #define LOCK_EX 2 /* exclusive lock */ | |
| #define LOCK_NB 4 /* don't block when locking */ | |
| #define LOCK_UN 8 /* unlock */ | |
| #endif /* LOCK_SH */ | |
| { | |
| struct flock l; | |
| if (code == LOCK_UN) | |
| l.l_type = F_UNLCK; | |
| else if (code & LOCK_SH) | |
| l.l_type = F_RDLCK; | |
| else if (code & LOCK_EX) | |
| l.l_type = F_WRLCK; | |
| else { | |
| PyErr_SetString(PyExc_ValueError, | |
| "unrecognized lockf argument"); | |
| return NULL; | |
| } | |
| l.l_start = l.l_len = 0; | |
| if (startobj != NULL) { | |
| #if !defined(HAVE_LARGEFILE_SUPPORT) | |
| l.l_start = PyLong_AsLong(startobj); | |
| #else | |
| l.l_start = PyLong_Check(startobj) ? | |
| PyLong_AsLongLong(startobj) : | |
| PyLong_AsLong(startobj); | |
| #endif | |
| if (PyErr_Occurred()) | |
| return NULL; | |
| } | |
| if (lenobj != NULL) { | |
| #if !defined(HAVE_LARGEFILE_SUPPORT) | |
| l.l_len = PyLong_AsLong(lenobj); | |
| #else | |
| l.l_len = PyLong_Check(lenobj) ? | |
| PyLong_AsLongLong(lenobj) : | |
| PyLong_AsLong(lenobj); | |
| #endif | |
| if (PyErr_Occurred()) | |
| return NULL; | |
| } | |
| l.l_whence = whence; | |
| do { | |
| Py_BEGIN_ALLOW_THREADS | |
| ret = fcntl(fd, (code & LOCK_NB) ? F_SETLK : F_SETLKW, &l); | |
| Py_END_ALLOW_THREADS | |
| } while (ret == -1 && errno == EINTR && !(async_err = PyErr_CheckSignals())); | |
| } | |
| if (ret < 0) { | |
| return !async_err ? PyErr_SetFromErrno(PyExc_OSError) : NULL; | |
| } | |
| Py_RETURN_NONE; | |
| } | |
| /* List of functions */ | |
| static PyMethodDef fcntl_methods[] = { | |
| FCNTL_FCNTL_METHODDEF | |
| FCNTL_IOCTL_METHODDEF | |
| FCNTL_FLOCK_METHODDEF | |
| FCNTL_LOCKF_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| PyDoc_STRVAR(module_doc, | |
| "This module performs file control and I/O control on file\n\ | |
| descriptors. It is an interface to the fcntl() and ioctl() Unix\n\ | |
| routines. File descriptors can be obtained with the fileno() method of\n\ | |
| a file or socket object."); | |
| /* Module initialisation */ | |
| static int | |
| all_ins(PyObject* m) | |
| { | |
| if (PyModule_AddIntMacro(m, LOCK_SH)) return -1; | |
| if (PyModule_AddIntMacro(m, LOCK_EX)) return -1; | |
| if (PyModule_AddIntMacro(m, LOCK_NB)) return -1; | |
| if (PyModule_AddIntMacro(m, LOCK_UN)) return -1; | |
| /* GNU extensions, as of glibc 2.2.4 */ | |
| #ifdef LOCK_MAND | |
| if (PyModule_AddIntMacro(m, LOCK_MAND)) return -1; | |
| #endif | |
| #ifdef LOCK_READ | |
| if (PyModule_AddIntMacro(m, LOCK_READ)) return -1; | |
| #endif | |
| #ifdef LOCK_WRITE | |
| if (PyModule_AddIntMacro(m, LOCK_WRITE)) return -1; | |
| #endif | |
| #ifdef LOCK_RW | |
| if (PyModule_AddIntMacro(m, LOCK_RW)) return -1; | |
| #endif | |
| #ifdef F_DUPFD | |
| if (PyModule_AddIntMacro(m, F_DUPFD)) return -1; | |
| #endif | |
| #ifdef F_DUPFD_CLOEXEC | |
| if (PyModule_AddIntMacro(m, F_DUPFD_CLOEXEC)) return -1; | |
| #endif | |
| #ifdef F_GETFD | |
| if (PyModule_AddIntMacro(m, F_GETFD)) return -1; | |
| #endif | |
| #ifdef F_SETFD | |
| if (PyModule_AddIntMacro(m, F_SETFD)) return -1; | |
| #endif | |
| #ifdef F_GETFL | |
| if (PyModule_AddIntMacro(m, F_GETFL)) return -1; | |
| #endif | |
| #ifdef F_SETFL | |
| if (PyModule_AddIntMacro(m, F_SETFL)) return -1; | |
| #endif | |
| #ifdef F_GETLK | |
| if (PyModule_AddIntMacro(m, F_GETLK)) return -1; | |
| #endif | |
| #ifdef F_SETLK | |
| if (PyModule_AddIntMacro(m, F_SETLK)) return -1; | |
| #endif | |
| #ifdef F_SETLKW | |
| if (PyModule_AddIntMacro(m, F_SETLKW)) return -1; | |
| #endif | |
| #ifdef F_OFD_GETLK | |
| if (PyModule_AddIntMacro(m, F_OFD_GETLK)) return -1; | |
| #endif | |
| #ifdef F_OFD_SETLK | |
| if (PyModule_AddIntMacro(m, F_OFD_SETLK)) return -1; | |
| #endif | |
| #ifdef F_OFD_SETLKW | |
| if (PyModule_AddIntMacro(m, F_OFD_SETLKW)) return -1; | |
| #endif | |
| #ifdef F_GETOWN | |
| if (PyModule_AddIntMacro(m, F_GETOWN)) return -1; | |
| #endif | |
| #ifdef F_SETOWN | |
| if (PyModule_AddIntMacro(m, F_SETOWN)) return -1; | |
| #endif | |
| #ifdef F_GETPATH | |
| if (PyModule_AddIntMacro(m, F_GETPATH)) return -1; | |
| #endif | |
| #ifdef F_GETSIG | |
| if (PyModule_AddIntMacro(m, F_GETSIG)) return -1; | |
| #endif | |
| #ifdef F_SETSIG | |
| if (PyModule_AddIntMacro(m, F_SETSIG)) return -1; | |
| #endif | |
| #ifdef F_RDLCK | |
| if (PyModule_AddIntMacro(m, F_RDLCK)) return -1; | |
| #endif | |
| #ifdef F_WRLCK | |
| if (PyModule_AddIntMacro(m, F_WRLCK)) return -1; | |
| #endif | |
| #ifdef F_UNLCK | |
| if (PyModule_AddIntMacro(m, F_UNLCK)) return -1; | |
| #endif | |
| /* LFS constants */ | |
| #ifdef F_GETLK64 | |
| if (PyModule_AddIntMacro(m, F_GETLK64)) return -1; | |
| #endif | |
| #ifdef F_SETLK64 | |
| if (PyModule_AddIntMacro(m, F_SETLK64)) return -1; | |
| #endif | |
| #ifdef F_SETLKW64 | |
| if (PyModule_AddIntMacro(m, F_SETLKW64)) return -1; | |
| #endif | |
| /* GNU extensions, as of glibc 2.2.4. */ | |
| #ifdef FASYNC | |
| if (PyModule_AddIntMacro(m, FASYNC)) return -1; | |
| #endif | |
| #ifdef F_SETLEASE | |
| if (PyModule_AddIntMacro(m, F_SETLEASE)) return -1; | |
| #endif | |
| #ifdef F_GETLEASE | |
| if (PyModule_AddIntMacro(m, F_GETLEASE)) return -1; | |
| #endif | |
| #ifdef F_NOTIFY | |
| if (PyModule_AddIntMacro(m, F_NOTIFY)) return -1; | |
| #endif | |
| #ifdef F_DUPFD_QUERY | |
| if (PyModule_AddIntMacro(m, F_DUPFD_QUERY)) return -1; | |
| #endif | |
| /* Old BSD flock(). */ | |
| #ifdef F_EXLCK | |
| if (PyModule_AddIntMacro(m, F_EXLCK)) return -1; | |
| #endif | |
| #ifdef F_SHLCK | |
| if (PyModule_AddIntMacro(m, F_SHLCK)) return -1; | |
| #endif | |
| /* Linux specifics */ | |
| #ifdef F_SETPIPE_SZ | |
| if (PyModule_AddIntMacro(m, F_SETPIPE_SZ)) return -1; | |
| #endif | |
| #ifdef F_GETPIPE_SZ | |
| if (PyModule_AddIntMacro(m, F_GETPIPE_SZ)) return -1; | |
| #endif | |
| /* On Android, FICLONE is blocked by SELinux. */ | |
| #ifndef __ANDROID__ | |
| #ifdef FICLONE | |
| if (PyModule_AddIntMacro(m, FICLONE)) return -1; | |
| #endif | |
| #ifdef FICLONERANGE | |
| if (PyModule_AddIntMacro(m, FICLONERANGE)) return -1; | |
| #endif | |
| #endif | |
| #ifdef F_GETOWN_EX | |
| // since Linux 2.6.32 | |
| if (PyModule_AddIntMacro(m, F_GETOWN_EX)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SETOWN_EX)) return -1; | |
| if (PyModule_AddIntMacro(m, F_OWNER_TID)) return -1; | |
| if (PyModule_AddIntMacro(m, F_OWNER_PID)) return -1; | |
| if (PyModule_AddIntMacro(m, F_OWNER_PGRP)) return -1; | |
| #endif | |
| #ifdef F_GET_RW_HINT | |
| // since Linux 4.13 | |
| if (PyModule_AddIntMacro(m, F_GET_RW_HINT)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SET_RW_HINT)) return -1; | |
| if (PyModule_AddIntMacro(m, F_GET_FILE_RW_HINT)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SET_FILE_RW_HINT)) return -1; | |
| #ifndef RWH_WRITE_LIFE_NOT_SET // typo in Linux < 5.5 | |
| # define RWH_WRITE_LIFE_NOT_SET RWF_WRITE_LIFE_NOT_SET | |
| #endif | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_NOT_SET)) return -1; | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_NONE)) return -1; | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_SHORT)) return -1; | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_MEDIUM)) return -1; | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_LONG)) return -1; | |
| if (PyModule_AddIntMacro(m, RWH_WRITE_LIFE_EXTREME)) return -1; | |
| #endif | |
| /* OS X specifics */ | |
| #ifdef F_FULLFSYNC | |
| if (PyModule_AddIntMacro(m, F_FULLFSYNC)) return -1; | |
| #endif | |
| #ifdef F_NOCACHE | |
| if (PyModule_AddIntMacro(m, F_NOCACHE)) return -1; | |
| #endif | |
| /* FreeBSD specifics */ | |
| #ifdef F_DUP2FD | |
| if (PyModule_AddIntMacro(m, F_DUP2FD)) return -1; | |
| #endif | |
| #ifdef F_DUP2FD_CLOEXEC | |
| if (PyModule_AddIntMacro(m, F_DUP2FD_CLOEXEC)) return -1; | |
| #endif | |
| #ifdef F_READAHEAD | |
| if (PyModule_AddIntMacro(m, F_READAHEAD)) return -1; | |
| #endif | |
| #ifdef F_RDAHEAD | |
| if (PyModule_AddIntMacro(m, F_RDAHEAD)) return -1; | |
| #endif | |
| #ifdef F_ISUNIONSTACK | |
| if (PyModule_AddIntMacro(m, F_ISUNIONSTACK)) return -1; | |
| #endif | |
| #ifdef F_KINFO | |
| if (PyModule_AddIntMacro(m, F_KINFO)) return -1; | |
| #endif | |
| /* NetBSD specifics */ | |
| #ifdef F_CLOSEM | |
| if (PyModule_AddIntMacro(m, F_CLOSEM)) return -1; | |
| #endif | |
| #ifdef F_MAXFD | |
| if (PyModule_AddIntMacro(m, F_MAXFD)) return -1; | |
| #endif | |
| #ifdef F_GETNOSIGPIPE | |
| if (PyModule_AddIntMacro(m, F_GETNOSIGPIPE)) return -1; | |
| #endif | |
| #ifdef F_SETNOSIGPIPE | |
| if (PyModule_AddIntMacro(m, F_SETNOSIGPIPE)) return -1; | |
| #endif | |
| /* For F_{GET|SET}FL */ | |
| #ifdef FD_CLOEXEC | |
| if (PyModule_AddIntMacro(m, FD_CLOEXEC)) return -1; | |
| #endif | |
| /* For F_NOTIFY */ | |
| #ifdef DN_ACCESS | |
| if (PyModule_AddIntMacro(m, DN_ACCESS)) return -1; | |
| #endif | |
| #ifdef DN_MODIFY | |
| if (PyModule_AddIntMacro(m, DN_MODIFY)) return -1; | |
| #endif | |
| #ifdef DN_CREATE | |
| if (PyModule_AddIntMacro(m, DN_CREATE)) return -1; | |
| #endif | |
| #ifdef DN_DELETE | |
| if (PyModule_AddIntMacro(m, DN_DELETE)) return -1; | |
| #endif | |
| #ifdef DN_RENAME | |
| if (PyModule_AddIntMacro(m, DN_RENAME)) return -1; | |
| #endif | |
| #ifdef DN_ATTRIB | |
| if (PyModule_AddIntMacro(m, DN_ATTRIB)) return -1; | |
| #endif | |
| #ifdef DN_MULTISHOT | |
| if (PyModule_AddIntMacro(m, DN_MULTISHOT)) return -1; | |
| #endif | |
| #ifdef HAVE_STROPTS_H | |
| /* Unix 98 guarantees that these are in stropts.h. */ | |
| if (PyModule_AddIntMacro(m, I_PUSH)) return -1; | |
| if (PyModule_AddIntMacro(m, I_POP)) return -1; | |
| if (PyModule_AddIntMacro(m, I_LOOK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_FLUSH)) return -1; | |
| if (PyModule_AddIntMacro(m, I_FLUSHBAND)) return -1; | |
| if (PyModule_AddIntMacro(m, I_SETSIG)) return -1; | |
| if (PyModule_AddIntMacro(m, I_GETSIG)) return -1; | |
| if (PyModule_AddIntMacro(m, I_FIND)) return -1; | |
| if (PyModule_AddIntMacro(m, I_PEEK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_SRDOPT)) return -1; | |
| if (PyModule_AddIntMacro(m, I_GRDOPT)) return -1; | |
| if (PyModule_AddIntMacro(m, I_NREAD)) return -1; | |
| if (PyModule_AddIntMacro(m, I_FDINSERT)) return -1; | |
| if (PyModule_AddIntMacro(m, I_STR)) return -1; | |
| if (PyModule_AddIntMacro(m, I_SWROPT)) return -1; | |
| #ifdef I_GWROPT | |
| /* despite the comment above, old-ish glibcs miss a couple... */ | |
| if (PyModule_AddIntMacro(m, I_GWROPT)) return -1; | |
| #endif | |
| if (PyModule_AddIntMacro(m, I_SENDFD)) return -1; | |
| if (PyModule_AddIntMacro(m, I_RECVFD)) return -1; | |
| if (PyModule_AddIntMacro(m, I_LIST)) return -1; | |
| if (PyModule_AddIntMacro(m, I_ATMARK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_CKBAND)) return -1; | |
| if (PyModule_AddIntMacro(m, I_GETBAND)) return -1; | |
| if (PyModule_AddIntMacro(m, I_CANPUT)) return -1; | |
| if (PyModule_AddIntMacro(m, I_SETCLTIME)) return -1; | |
| #ifdef I_GETCLTIME | |
| if (PyModule_AddIntMacro(m, I_GETCLTIME)) return -1; | |
| #endif | |
| if (PyModule_AddIntMacro(m, I_LINK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_UNLINK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_PLINK)) return -1; | |
| if (PyModule_AddIntMacro(m, I_PUNLINK)) return -1; | |
| #endif | |
| #ifdef F_ADD_SEALS | |
| /* Linux: file sealing for memfd_create() */ | |
| if (PyModule_AddIntMacro(m, F_ADD_SEALS)) return -1; | |
| if (PyModule_AddIntMacro(m, F_GET_SEALS)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SEAL_SEAL)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SEAL_SHRINK)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SEAL_GROW)) return -1; | |
| if (PyModule_AddIntMacro(m, F_SEAL_WRITE)) return -1; | |
| #ifdef F_SEAL_FUTURE_WRITE | |
| if (PyModule_AddIntMacro(m, F_SEAL_FUTURE_WRITE)) return -1; | |
| #endif | |
| #endif | |
| return 0; | |
| } | |
| static int | |
| fcntl_exec(PyObject *module) | |
| { | |
| if (all_ins(module) < 0) { | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static PyModuleDef_Slot fcntl_slots[] = { | |
| {Py_mod_exec, fcntl_exec}, | |
| {Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| static struct PyModuleDef fcntlmodule = { | |
| PyModuleDef_HEAD_INIT, | |
| .m_name = "fcntl", | |
| .m_doc = module_doc, | |
| .m_size = 0, | |
| .m_methods = fcntl_methods, | |
| .m_slots = fcntl_slots, | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit_fcntl(void) | |
| { | |
| return PyModuleDef_Init(&fcntlmodule); | |
| } | |
| /* Module that wraps all OpenSSL hash algorithms */ | |
| /* | |
| * Copyright (C) 2005-2010 Gregory P. Smith (greg@krypto.org) | |
| * Licensed to PSF under a Contributor Agreement. | |
| * | |
| * Derived from a skeleton of shamodule.c containing work performed by: | |
| * | |
| * Andrew Kuchling (amk@amk.ca) | |
| * Greg Stein (gstein@lyra.org) | |
| * | |
| */ | |
| /* Don't warn about deprecated functions, */ | |
| #ifndef OPENSSL_API_COMPAT | |
| // 0x10101000L == 1.1.1, 30000 == 3.0.0 | |
| #define OPENSSL_API_COMPAT 0x10101000L | |
| #endif | |
| #define OPENSSL_NO_DEPRECATED 1 | |
| #ifndef Py_BUILD_CORE_BUILTIN | |
| # define Py_BUILD_CORE_MODULE 1 | |
| #endif | |
| #include "Python.h" | |
| #include "pycore_hashtable.h" | |
| #include "pycore_strhex.h" // _Py_strhex() | |
| #include "pycore_pyatomic_ft_wrappers.h" // FT_ATOMIC_LOAD_PTR_RELAXED | |
| #include "hashlib.h" | |
| /* EVP is the preferred interface to hashing in OpenSSL */ | |
| #include <openssl/evp.h> | |
| #include <openssl/crypto.h> // FIPS_mode() | |
| /* We use the object interface to discover what hashes OpenSSL supports. */ | |
| #include <openssl/objects.h> | |
| #include <openssl/err.h> | |
| #include <stdbool.h> | |
| #if OPENSSL_VERSION_NUMBER >= 0x30000000L | |
| # define Py_HAS_OPENSSL3_SUPPORT | |
| # include <openssl/core_names.h> // OSSL_MAC_PARAM_DIGEST | |
| # include <openssl/params.h> // OSSL_PARAM_*() | |
| #else | |
| # include <openssl/hmac.h> // HMAC() | |
| #endif | |
| #ifndef OPENSSL_THREADS | |
| # error "OPENSSL_THREADS is not defined, Python requires thread-safe OpenSSL" | |
| #endif | |
| #define MUNCH_SIZE INT_MAX | |
| #if defined(NID_sha3_224) && defined(NID_sha3_256) && defined(NID_sha3_384) && defined(NID_sha3_512) | |
| #define PY_OPENSSL_HAS_SHA3 1 | |
| #endif | |
| #if defined(NID_shake128) || defined(NID_shake256) | |
| #define PY_OPENSSL_HAS_SHAKE 1 | |
| #endif | |
| #if defined(NID_blake2s256) || defined(NID_blake2b512) | |
| #define PY_OPENSSL_HAS_BLAKE2 1 | |
| #endif | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| #define PY_EVP_MD EVP_MD | |
| #define PY_EVP_MD_fetch(algorithm, properties) EVP_MD_fetch(NULL, algorithm, properties) | |
| #define PY_EVP_MD_up_ref(md) EVP_MD_up_ref(md) | |
| #define PY_EVP_MD_free(md) EVP_MD_free(md) | |
| #define PY_EVP_MD_CTX_md(CTX) EVP_MD_CTX_get0_md(CTX) | |
| #define PY_HMAC_CTX_TYPE EVP_MAC_CTX | |
| #define PY_HMAC_CTX_free EVP_MAC_CTX_free | |
| #define PY_HMAC_update EVP_MAC_update | |
| #else | |
| #define PY_EVP_MD const EVP_MD | |
| #define PY_EVP_MD_fetch(algorithm, properties) EVP_get_digestbyname(algorithm) | |
| #define PY_EVP_MD_up_ref(md) do {} while(0) | |
| #define PY_EVP_MD_free(md) do {} while(0) | |
| #define PY_EVP_MD_CTX_md(CTX) EVP_MD_CTX_md(CTX) | |
| #define PY_HMAC_CTX_TYPE HMAC_CTX | |
| #define PY_HMAC_CTX_free HMAC_CTX_free | |
| #define PY_HMAC_update HMAC_Update | |
| #endif | |
| /* | |
| * Return 1 if *md* is an extendable-output Function (XOF) and 0 otherwise. | |
| * SHAKE128 and SHAKE256 are XOF functions but not BLAKE2B algorithms. | |
| * | |
| * This is a backport of the EVP_MD_xof() helper added in OpenSSL 3.4. | |
| */ | |
| static inline int | |
| PY_EVP_MD_xof(PY_EVP_MD *md) | |
| { | |
| return md != NULL && ((EVP_MD_flags(md) & EVP_MD_FLAG_XOF) != 0); | |
| } | |
| /* hash alias map and fast lookup | |
| * | |
| * Map between Python's preferred names and OpenSSL internal names. Maintain | |
| * cache of fetched EVP MD objects. The EVP_get_digestbyname() and | |
| * EVP_MD_fetch() API calls have a performance impact. | |
| * | |
| * The py_hashentry_t items are stored in a _Py_hashtable_t with py_name and | |
| * py_alias as keys. | |
| */ | |
| typedef enum Py_hash_type { | |
| Py_ht_evp, // usedforsecurity=True / default | |
| Py_ht_evp_nosecurity, // usedforsecurity=False | |
| Py_ht_mac, // HMAC | |
| Py_ht_pbkdf2, // PKBDF2 | |
| } Py_hash_type; | |
| typedef struct { | |
| const char *py_name; | |
| const char *py_alias; | |
| const char *ossl_name; | |
| int ossl_nid; | |
| int refcnt; | |
| PY_EVP_MD *evp; | |
| PY_EVP_MD *evp_nosecurity; | |
| } py_hashentry_t; | |
| // Fundamental to TLS, assumed always present in any libcrypto: | |
| #define Py_hash_md5 "md5" | |
| #define Py_hash_sha1 "sha1" | |
| #define Py_hash_sha224 "sha224" | |
| #define Py_hash_sha256 "sha256" | |
| #define Py_hash_sha384 "sha384" | |
| #define Py_hash_sha512 "sha512" | |
| // Not all OpenSSL-like libcrypto libraries provide these: | |
| #if defined(NID_sha512_224) | |
| # define Py_hash_sha512_224 "sha512_224" | |
| #endif | |
| #if defined(NID_sha512_256) | |
| # define Py_hash_sha512_256 "sha512_256" | |
| #endif | |
| #if defined(NID_sha3_224) | |
| # define Py_hash_sha3_224 "sha3_224" | |
| #endif | |
| #if defined(NID_sha3_256) | |
| # define Py_hash_sha3_256 "sha3_256" | |
| #endif | |
| #if defined(NID_sha3_384) | |
| # define Py_hash_sha3_384 "sha3_384" | |
| #endif | |
| #if defined(NID_sha3_512) | |
| # define Py_hash_sha3_512 "sha3_512" | |
| #endif | |
| #if defined(NID_shake128) | |
| # define Py_hash_shake_128 "shake_128" | |
| #endif | |
| #if defined(NID_shake256) | |
| # define Py_hash_shake_256 "shake_256" | |
| #endif | |
| #if defined(NID_blake2s256) | |
| # define Py_hash_blake2s "blake2s" | |
| #endif | |
| #if defined(NID_blake2b512) | |
| # define Py_hash_blake2b "blake2b" | |
| #endif | |
| #define PY_HASH_ENTRY(py_name, py_alias, ossl_name, ossl_nid) \ | |
| {py_name, py_alias, ossl_name, ossl_nid, 0, NULL, NULL} | |
| static const py_hashentry_t py_hashes[] = { | |
| /* md5 */ | |
| PY_HASH_ENTRY(Py_hash_md5, "MD5", SN_md5, NID_md5), | |
| /* sha1 */ | |
| PY_HASH_ENTRY(Py_hash_sha1, "SHA1", SN_sha1, NID_sha1), | |
| /* sha2 family */ | |
| PY_HASH_ENTRY(Py_hash_sha224, "SHA224", SN_sha224, NID_sha224), | |
| PY_HASH_ENTRY(Py_hash_sha256, "SHA256", SN_sha256, NID_sha256), | |
| PY_HASH_ENTRY(Py_hash_sha384, "SHA384", SN_sha384, NID_sha384), | |
| PY_HASH_ENTRY(Py_hash_sha512, "SHA512", SN_sha512, NID_sha512), | |
| /* truncated sha2 */ | |
| #ifdef Py_hash_sha512_224 | |
| PY_HASH_ENTRY(Py_hash_sha512_224, "SHA512_224", SN_sha512_224, NID_sha512_224), | |
| #endif | |
| #ifdef Py_hash_sha512_256 | |
| PY_HASH_ENTRY(Py_hash_sha512_256, "SHA512_256", SN_sha512_256, NID_sha512_256), | |
| #endif | |
| /* sha3 */ | |
| #ifdef Py_hash_sha3_224 | |
| PY_HASH_ENTRY(Py_hash_sha3_224, NULL, SN_sha3_224, NID_sha3_224), | |
| #endif | |
| #ifdef Py_hash_sha3_256 | |
| PY_HASH_ENTRY(Py_hash_sha3_256, NULL, SN_sha3_256, NID_sha3_256), | |
| #endif | |
| #ifdef Py_hash_sha3_384 | |
| PY_HASH_ENTRY(Py_hash_sha3_384, NULL, SN_sha3_384, NID_sha3_384), | |
| #endif | |
| #ifdef Py_hash_sha3_512 | |
| PY_HASH_ENTRY(Py_hash_sha3_512, NULL, SN_sha3_512, NID_sha3_512), | |
| #endif | |
| /* sha3 shake */ | |
| #ifdef Py_hash_shake_128 | |
| PY_HASH_ENTRY(Py_hash_shake_128, NULL, SN_shake128, NID_shake128), | |
| #endif | |
| #ifdef Py_hash_shake_256 | |
| PY_HASH_ENTRY(Py_hash_shake_256, NULL, SN_shake256, NID_shake256), | |
| #endif | |
| /* blake2 digest */ | |
| #ifdef Py_hash_blake2s | |
| PY_HASH_ENTRY(Py_hash_blake2s, "blake2s256", SN_blake2s256, NID_blake2s256), | |
| #endif | |
| #ifdef Py_hash_blake2b | |
| PY_HASH_ENTRY(Py_hash_blake2b, "blake2b512", SN_blake2b512, NID_blake2b512), | |
| #endif | |
| PY_HASH_ENTRY(NULL, NULL, NULL, 0), | |
| }; | |
| static Py_uhash_t | |
| py_hashentry_t_hash_name(const void *key) { | |
| return Py_HashBuffer(key, strlen((const char *)key)); | |
| } | |
| static int | |
| py_hashentry_t_compare_name(const void *key1, const void *key2) { | |
| return strcmp((const char *)key1, (const char *)key2) == 0; | |
| } | |
| static void | |
| py_hashentry_t_destroy_value(void *entry) { | |
| py_hashentry_t *h = (py_hashentry_t *)entry; | |
| if (--(h->refcnt) == 0) { | |
| if (h->evp != NULL) { | |
| PY_EVP_MD_free(h->evp); | |
| h->evp = NULL; | |
| } | |
| if (h->evp_nosecurity != NULL) { | |
| PY_EVP_MD_free(h->evp_nosecurity); | |
| h->evp_nosecurity = NULL; | |
| } | |
| PyMem_Free(entry); | |
| } | |
| } | |
| static _Py_hashtable_t * | |
| py_hashentry_table_new(void) { | |
| _Py_hashtable_t *ht = _Py_hashtable_new_full( | |
| py_hashentry_t_hash_name, | |
| py_hashentry_t_compare_name, | |
| NULL, | |
| py_hashentry_t_destroy_value, | |
| NULL | |
| ); | |
| if (ht == NULL) { | |
| return NULL; | |
| } | |
| for (const py_hashentry_t *h = py_hashes; h->py_name != NULL; h++) { | |
| py_hashentry_t *entry = (py_hashentry_t *)PyMem_Malloc(sizeof(py_hashentry_t)); | |
| if (entry == NULL) { | |
| goto error; | |
| } | |
| memcpy(entry, h, sizeof(py_hashentry_t)); | |
| if (_Py_hashtable_set(ht, (const void*)entry->py_name, (void*)entry) < 0) { | |
| PyMem_Free(entry); | |
| goto error; | |
| } | |
| entry->refcnt = 1; | |
| if (h->py_alias != NULL) { | |
| if (_Py_hashtable_set(ht, (const void*)entry->py_alias, (void*)entry) < 0) { | |
| PyMem_Free(entry); | |
| goto error; | |
| } | |
| entry->refcnt++; | |
| } | |
| } | |
| return ht; | |
| error: | |
| _Py_hashtable_destroy(ht); | |
| return NULL; | |
| } | |
| // --- Module state ----------------------------------------------------------- | |
| static PyModuleDef _hashlibmodule; | |
| typedef struct { | |
| PyTypeObject *HASH_type; // based on EVP_MD | |
| PyTypeObject *HMAC_type; | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| PyTypeObject *HASHXOF_type; // based on EVP_MD | |
| #endif | |
| PyObject *constructs; | |
| PyObject *unsupported_digestmod_error; | |
| _Py_hashtable_t *hashtable; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| EVP_MAC *evp_hmac; | |
| #endif | |
| } _hashlibstate; | |
| static inline _hashlibstate* | |
| get_hashlib_state(PyObject *module) | |
| { | |
| void *state = PyModule_GetState(module); | |
| assert(state != NULL); | |
| return (_hashlibstate *)state; | |
| } | |
| // --- Module objects --------------------------------------------------------- | |
| typedef struct { | |
| HASHLIB_OBJECT_HEAD | |
| EVP_MD_CTX *ctx; /* OpenSSL message digest context */ | |
| } HASHobject; | |
| #define HASHobject_CAST(op) ((HASHobject *)(op)) | |
| typedef struct { | |
| HASHLIB_OBJECT_HEAD | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| EVP_MAC_CTX *ctx; /* OpenSSL HMAC EVP-based context */ | |
| int evp_md_nid; /* needed to find the message digest name */ | |
| #else | |
| HMAC_CTX *ctx; /* OpenSSL HMAC plain context */ | |
| #endif | |
| } HMACobject; | |
| #define HMACobject_CAST(op) ((HMACobject *)(op)) | |
| // --- Module clinic configuration -------------------------------------------- | |
| /*[clinic input] | |
| module _hashlib | |
| class _hashlib.HASH "HASHobject *" "&PyType_Type" | |
| class _hashlib.HASHXOF "HASHobject *" "&PyType_Type" | |
| class _hashlib.HMAC "HMACobject *" "&PyType_Type" | |
| [clinic start generated code]*/ | |
| /*[clinic end generated code: output=da39a3ee5e6b4b0d input=6b5c9ce5c28bdc58]*/ | |
| #include "clinic/_hashopenssl.c.h" | |
| /* LCOV_EXCL_START */ | |
| /* Thin wrapper around ERR_reason_error_string() returning non-NULL text. */ | |
| static const char * | |
| py_wrapper_ERR_reason_error_string(unsigned long errcode) | |
| { | |
| const char *reason = ERR_reason_error_string(errcode); | |
| return reason ? reason : "no reason"; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| /* | |
| * Set an exception with additional information. | |
| * | |
| * This is only useful in OpenSSL 3.0 and later as the default reason | |
| * usually lacks information and function locations are no longer encoded | |
| * in the error code. | |
| */ | |
| static void | |
| set_exception_with_ssl_errinfo(PyObject *exc_type, PyObject *exc_text, | |
| const char *lib, const char *reason) | |
| { | |
| assert(exc_type != NULL); | |
| assert(exc_text != NULL); | |
| if (lib && reason) { | |
| PyErr_Format(exc_type, "[%s] %U (reason: %s)", lib, exc_text, reason); | |
| } | |
| else if (lib) { | |
| PyErr_Format(exc_type, "[%s] %U", lib, exc_text); | |
| } | |
| else if (reason) { | |
| PyErr_Format(exc_type, "%U (reason: %s)", exc_text, reason); | |
| } | |
| else { | |
| PyErr_SetObject(exc_type, exc_text); | |
| } | |
| } | |
| #endif | |
| /* Set an exception of given type using the given OpenSSL error code. */ | |
| static void | |
| set_ssl_exception_from_errcode(PyObject *exc_type, unsigned long errcode) | |
| { | |
| assert(exc_type != NULL); | |
| assert(errcode != 0); | |
| /* ERR_ERROR_STRING(3) ensures that the messages below are ASCII */ | |
| const char *lib = ERR_lib_error_string(errcode); | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| // Since OpenSSL 3.0, ERR_func_error_string() always returns NULL. | |
| const char *func = NULL; | |
| #else | |
| const char *func = ERR_func_error_string(errcode); | |
| #endif | |
| const char *reason = py_wrapper_ERR_reason_error_string(errcode); | |
| if (lib && func) { | |
| PyErr_Format(exc_type, "[%s: %s] %s", lib, func, reason); | |
| } | |
| else if (lib) { | |
| PyErr_Format(exc_type, "[%s] %s", lib, reason); | |
| } | |
| else { | |
| PyErr_SetString(exc_type, reason); | |
| } | |
| } | |
| /* | |
| * Get an appropriate exception type for the given OpenSSL error code. | |
| * | |
| * The exception type depends on the error code reason. | |
| */ | |
| static PyObject * | |
| get_smart_ssl_exception_type(unsigned long errcode, PyObject *default_exc_type) | |
| { | |
| switch (ERR_GET_REASON(errcode)) { | |
| case ERR_R_MALLOC_FAILURE: | |
| return PyExc_MemoryError; | |
| default: | |
| return default_exc_type; | |
| } | |
| } | |
| /* | |
| * Set an exception of given type. | |
| * | |
| * By default, the exception's message is constructed by using the last SSL | |
| * error that occurred. If no error occurred, the 'fallback_message' is used | |
| * to create an exception message. | |
| */ | |
| static void | |
| raise_ssl_error(PyObject *exc_type, const char *fallback_message) | |
| { | |
| assert(fallback_message != NULL); | |
| unsigned long errcode = ERR_peek_last_error(); | |
| if (errcode) { | |
| ERR_clear_error(); | |
| set_ssl_exception_from_errcode(exc_type, errcode); | |
| } | |
| else { | |
| PyErr_SetString(exc_type, fallback_message); | |
| } | |
| } | |
| /* Same as raise_ssl_error() but with a C-style formatted message. */ | |
| static void | |
| raise_ssl_error_f(PyObject *exc_type, const char *fallback_format, ...) | |
| { | |
| assert(fallback_format != NULL); | |
| unsigned long errcode = ERR_peek_last_error(); | |
| if (errcode) { | |
| ERR_clear_error(); | |
| set_ssl_exception_from_errcode(exc_type, errcode); | |
| } | |
| else { | |
| va_list vargs; | |
| va_start(vargs, fallback_format); | |
| PyErr_FormatV(exc_type, fallback_format, vargs); | |
| va_end(vargs); | |
| } | |
| } | |
| /* Same as raise_ssl_error_f() with smart exception types. */ | |
| static void | |
| raise_smart_ssl_error_f(PyObject *exc_type, const char *fallback_format, ...) | |
| { | |
| unsigned long errcode = ERR_peek_last_error(); | |
| if (errcode) { | |
| ERR_clear_error(); | |
| exc_type = get_smart_ssl_exception_type(errcode, exc_type); | |
| set_ssl_exception_from_errcode(exc_type, errcode); | |
| } | |
| else { | |
| va_list vargs; | |
| va_start(vargs, fallback_format); | |
| PyErr_FormatV(exc_type, fallback_format, vargs); | |
| va_end(vargs); | |
| } | |
| } | |
| /* | |
| * Raise a ValueError with a default message after an error occurred. | |
| * It can also be used without previous calls to SSL built-in functions. | |
| */ | |
| static inline void | |
| notify_ssl_error_occurred(const char *message) | |
| { | |
| raise_ssl_error(PyExc_ValueError, message); | |
| } | |
| /* Same as notify_ssl_error_occurred() for failed OpenSSL functions. */ | |
| static inline void | |
| notify_ssl_error_occurred_in(const char *funcname) | |
| { | |
| raise_ssl_error_f(PyExc_ValueError, | |
| "error in OpenSSL function %s()", funcname); | |
| } | |
| /* Same as notify_ssl_error_occurred_in() with smart exception types. */ | |
| static inline void | |
| notify_smart_ssl_error_occurred_in(const char *funcname) | |
| { | |
| raise_smart_ssl_error_f(PyExc_ValueError, | |
| "error in OpenSSL function %s()", funcname); | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| static void | |
| raise_unsupported_algorithm_impl(PyObject *exc_type, | |
| const char *fallback_format, | |
| const void *format_arg) | |
| { | |
| // Since OpenSSL 3.0, if the algorithm is not supported or fetching fails, | |
| // the reason lacks the algorithm name. | |
| int errcode = ERR_peek_last_error(); | |
| switch (ERR_GET_REASON(errcode)) { | |
| case ERR_R_UNSUPPORTED: { | |
| PyObject *text = PyUnicode_FromFormat(fallback_format, format_arg); | |
| if (text != NULL) { | |
| const char *lib = ERR_lib_error_string(errcode); | |
| set_exception_with_ssl_errinfo(exc_type, text, lib, NULL); | |
| Py_DECREF(text); | |
| } | |
| break; | |
| } | |
| case ERR_R_FETCH_FAILED: { | |
| PyObject *text = PyUnicode_FromFormat(fallback_format, format_arg); | |
| if (text != NULL) { | |
| const char *lib = ERR_lib_error_string(errcode); | |
| const char *reason = ERR_reason_error_string(errcode); | |
| set_exception_with_ssl_errinfo(exc_type, text, lib, reason); | |
| Py_DECREF(text); | |
| } | |
| break; | |
| } | |
| default: | |
| raise_ssl_error_f(exc_type, fallback_format, format_arg); | |
| break; | |
| } | |
| assert(PyErr_Occurred()); | |
| } | |
| #else | |
| /* Before OpenSSL 3.0, error messages included enough information. */ | |
| #define raise_unsupported_algorithm_impl raise_ssl_error_f | |
| #endif | |
| static inline void | |
| raise_unsupported_algorithm_error(_hashlibstate *state, PyObject *digestmod) | |
| { | |
| raise_unsupported_algorithm_impl( | |
| state->unsupported_digestmod_error, | |
| HASHLIB_UNSUPPORTED_ALGORITHM, | |
| digestmod | |
| ); | |
| } | |
| static inline void | |
| raise_unsupported_str_algorithm_error(_hashlibstate *state, const char *name) | |
| { | |
| raise_unsupported_algorithm_impl( | |
| state->unsupported_digestmod_error, | |
| HASHLIB_UNSUPPORTED_STR_ALGORITHM, | |
| name | |
| ); | |
| } | |
| #undef raise_unsupported_algorithm_impl | |
| /* LCOV_EXCL_STOP */ | |
| /* | |
| * OpenSSL provides a way to go from NIDs to digest names for hash functions | |
| * but lacks this granularity for MAC objects where it is not possible to get | |
| * the underlying digest name (only the block size and digest size are allowed | |
| * to be recovered). | |
| * | |
| * In addition, OpenSSL aliases pollute the list of known digest names | |
| * as OpenSSL appears to have its own definition of alias. In particular, | |
| * the resulting list still contains duplicate and alternate names for several | |
| * algorithms. | |
| * | |
| * Therefore, digest names, whether they are used by hash functions or HMAC, | |
| * are handled through EVP_MD objects or directly by using some NID. | |
| */ | |
| /* Get a cached entry by OpenSSL NID. */ | |
| static const py_hashentry_t * | |
| get_hashentry_by_nid(int nid) | |
| { | |
| for (const py_hashentry_t *h = py_hashes; h->py_name != NULL; h++) { | |
| if (h->ossl_nid == nid) { | |
| return h; | |
| } | |
| } | |
| return NULL; | |
| } | |
| /* | |
| * Convert the NID to a string via OBJ_nid2*() functions. | |
| * | |
| * If 'nid' cannot be resolved, set an exception and return NULL. | |
| */ | |
| static const char * | |
| get_asn1_utf8name_by_nid(int nid) | |
| { | |
| const char *name = OBJ_nid2ln(nid); | |
| if (name == NULL) { | |
| /* In OpenSSL 3.0 and later, OBJ_nid*() are thread-safe and may raise. | |
| * However, not all versions of OpenSSL set a last error, so we simply | |
| * ignore the last error if none exists. | |
| * | |
| * See https://github.com/python/cpython/issues/142451. | |
| */ | |
| unsigned long errcode = ERR_peek_last_error(); | |
| if (errcode && ERR_GET_REASON(errcode) != OBJ_R_UNKNOWN_NID) { | |
| goto error; | |
| } | |
| // fallback to short name and unconditionally propagate errors | |
| name = OBJ_nid2sn(nid); | |
| if (name == NULL) { | |
| goto error; | |
| } | |
| } | |
| return name; | |
| error: | |
| raise_ssl_error_f(PyExc_ValueError, "cannot resolve NID %d", nid); | |
| return NULL; | |
| } | |
| /* | |
| * Convert the NID to an OpenSSL digest name. | |
| * | |
| * On error, set an exception and return NULL. | |
| */ | |
| static const char * | |
| get_hashlib_utf8name_by_nid(int nid) | |
| { | |
| const py_hashentry_t *e = get_hashentry_by_nid(nid); | |
| return e ? e->py_name : get_asn1_utf8name_by_nid(nid); | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| /* | |
| * Convert the NID to an OpenSSL "canonical" cached, SN_* or LN_* digest name. | |
| * | |
| * On error, set an exception and return NULL. | |
| */ | |
| static const char * | |
| get_openssl_utf8name_by_nid(int nid) | |
| { | |
| const py_hashentry_t *e = get_hashentry_by_nid(nid); | |
| return e ? e->ossl_name : get_asn1_utf8name_by_nid(nid); | |
| } | |
| #endif | |
| /* Same as get_hashlib_utf8name_by_nid() but using an EVP_MD object. */ | |
| static const char * | |
| get_hashlib_utf8name_by_evp_md(const EVP_MD *md) | |
| { | |
| assert(md != NULL); | |
| return get_hashlib_utf8name_by_nid(EVP_MD_nid(md)); | |
| } | |
| /* | |
| * Return 1 if the property query clause [1] must be "-fips" and 0 otherwise. | |
| * | |
| * [1] https://docs.openssl.org/master/man7/property | |
| */ | |
| static inline int | |
| disable_fips_property(Py_hash_type py_ht) | |
| { | |
| switch (py_ht) { | |
| case Py_ht_evp: | |
| case Py_ht_mac: | |
| case Py_ht_pbkdf2: | |
| return 0; | |
| case Py_ht_evp_nosecurity: | |
| return 1; | |
| default: | |
| Py_FatalError("unsupported hash type"); | |
| } | |
| } | |
| /* | |
| * Get a new reference to an EVP_MD object described by name and purpose. | |
| * | |
| * If 'name' is an OpenSSL indexed name, the return value is cached. | |
| */ | |
| static PY_EVP_MD * | |
| get_openssl_evp_md_by_utf8name(_hashlibstate *state, const char *name, | |
| Py_hash_type py_ht) | |
| { | |
| PY_EVP_MD *digest = NULL, *other_digest = NULL; | |
| py_hashentry_t *entry = _Py_hashtable_get(state->hashtable, name); | |
| if (entry != NULL) { | |
| if (!disable_fips_property(py_ht)) { | |
| digest = FT_ATOMIC_LOAD_PTR_RELAXED(entry->evp); | |
| if (digest == NULL) { | |
| digest = PY_EVP_MD_fetch(entry->ossl_name, NULL); | |
| #ifdef Py_GIL_DISABLED | |
| // exchange just in case another thread did same thing at same time | |
| other_digest = _Py_atomic_exchange_ptr(&entry->evp, (void *)digest); | |
| #else | |
| entry->evp = digest; | |
| #endif | |
| } | |
| } | |
| else { | |
| digest = FT_ATOMIC_LOAD_PTR_RELAXED(entry->evp_nosecurity); | |
| if (digest == NULL) { | |
| digest = PY_EVP_MD_fetch(entry->ossl_name, "-fips"); | |
| #ifdef Py_GIL_DISABLED | |
| // exchange just in case another thread did same thing at same time | |
| other_digest = _Py_atomic_exchange_ptr(&entry->evp_nosecurity, (void *)digest); | |
| #else | |
| entry->evp_nosecurity = digest; | |
| #endif | |
| } | |
| } | |
| // if another thread same thing at same time make sure we got same ptr | |
| assert(other_digest == NULL || other_digest == digest); | |
| if (digest != NULL && other_digest == NULL) { | |
| PY_EVP_MD_up_ref(digest); | |
| } | |
| } | |
| else { | |
| // Fall back for looking up an unindexed OpenSSL specific name. | |
| const char *props = disable_fips_property(py_ht) ? "-fips" : NULL; | |
| (void)props; // will only be used in OpenSSL 3.0 and later | |
| digest = PY_EVP_MD_fetch(name, props); | |
| } | |
| if (digest == NULL) { | |
| raise_unsupported_str_algorithm_error(state, name); | |
| return NULL; | |
| } | |
| return digest; | |
| } | |
| /* | |
| * Get a new reference to an EVP_MD described by 'digestmod' and purpose. | |
| * | |
| * On error, set an exception and return NULL. | |
| * | |
| * Parameters | |
| * | |
| * digestmod A digest name or a _hashopenssl builtin function | |
| * py_ht The message digest purpose. | |
| */ | |
| static PY_EVP_MD * | |
| get_openssl_evp_md(_hashlibstate *state, PyObject *digestmod, Py_hash_type py_ht) | |
| { | |
| const char *name; | |
| if (PyUnicode_Check(digestmod)) { | |
| name = PyUnicode_AsUTF8(digestmod); | |
| } | |
| else { | |
| PyObject *dict = state->constructs; | |
| assert(dict != NULL); | |
| PyObject *borrowed_ref = PyDict_GetItemWithError(dict, digestmod); | |
| name = borrowed_ref == NULL ? NULL : PyUnicode_AsUTF8(borrowed_ref); | |
| } | |
| if (name == NULL) { | |
| if (!PyErr_Occurred()) { | |
| raise_unsupported_algorithm_error(state, digestmod); | |
| } | |
| return NULL; | |
| } | |
| return get_openssl_evp_md_by_utf8name(state, name, py_ht); | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| /* | |
| * Get the "canonical" name of an EVP_MD described by 'digestmod' and purpose. | |
| * | |
| * On error, set an exception and return NULL. | |
| * | |
| * This function should not be used to construct the exposed Python name, | |
| * but rather to invoke OpenSSL EVP_* functions. | |
| */ | |
| static const char * | |
| get_openssl_digest_name(_hashlibstate *state, | |
| PyObject *digestmod, Py_hash_type py_ht, | |
| EVP_MD **evp_md) | |
| { | |
| PY_EVP_MD *md = get_openssl_evp_md(state, digestmod, py_ht); | |
| if (md == NULL) { | |
| if (evp_md != NULL) { | |
| *evp_md = NULL; | |
| } | |
| return NULL; | |
| } | |
| int nid = EVP_MD_nid(md); | |
| const char *name = get_openssl_utf8name_by_nid(nid); | |
| if (name == NULL) { | |
| if (evp_md != NULL) { | |
| *evp_md = NULL; | |
| } | |
| PY_EVP_MD_free(md); | |
| raise_unsupported_algorithm_error(state, digestmod); | |
| return NULL; | |
| } | |
| if (evp_md != NULL) { | |
| *evp_md = md; | |
| } | |
| else { | |
| PY_EVP_MD_free(md); | |
| } | |
| return name; | |
| } | |
| #endif | |
| // --- OpenSSL HASH wrappers -------------------------------------------------- | |
| /* Thin wrapper around EVP_MD_CTX_new() which sets an exception on failure. */ | |
| static EVP_MD_CTX * | |
| py_wrapper_EVP_MD_CTX_new(void) | |
| { | |
| EVP_MD_CTX *ctx = EVP_MD_CTX_new(); | |
| if (ctx == NULL) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| return ctx; | |
| } | |
| // --- HASH interface --------------------------------------------------------- | |
| static HASHobject * | |
| new_hash_object(PyTypeObject *type) | |
| { | |
| HASHobject *retval = PyObject_New(HASHobject, type); | |
| if (retval == NULL) { | |
| return NULL; | |
| } | |
| HASHLIB_INIT_MUTEX(retval); | |
| retval->ctx = py_wrapper_EVP_MD_CTX_new(); | |
| if (retval->ctx == NULL) { | |
| Py_DECREF(retval); | |
| return NULL; | |
| } | |
| return retval; | |
| } | |
| static int | |
| _hashlib_HASH_hash(HASHobject *self, const void *vp, Py_ssize_t len) | |
| { | |
| unsigned int process; | |
| const unsigned char *cp = (const unsigned char *)vp; | |
| while (0 < len) { | |
| if (len > (Py_ssize_t)MUNCH_SIZE) | |
| process = MUNCH_SIZE; | |
| else | |
| process = Py_SAFE_DOWNCAST(len, Py_ssize_t, unsigned int); | |
| if (!EVP_DigestUpdate(self->ctx, (const void*)cp, process)) { | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_DigestUpdate)); | |
| return -1; | |
| } | |
| len -= process; | |
| cp += process; | |
| } | |
| return 0; | |
| } | |
| /* Internal methods for a hash object */ | |
| static void | |
| _hashlib_HASH_dealloc(PyObject *op) | |
| { | |
| HASHobject *self = HASHobject_CAST(op); | |
| PyTypeObject *tp = Py_TYPE(self); | |
| EVP_MD_CTX_free(self->ctx); | |
| PyObject_Free(self); | |
| Py_DECREF(tp); | |
| } | |
| static int | |
| _hashlib_HASH_copy_locked(HASHobject *self, EVP_MD_CTX *new_ctx_p) | |
| { | |
| int result; | |
| HASHLIB_ACQUIRE_LOCK(self); | |
| result = EVP_MD_CTX_copy(new_ctx_p, self->ctx); | |
| HASHLIB_RELEASE_LOCK(self); | |
| if (result == 0) { | |
| notify_smart_ssl_error_occurred_in(Py_STRINGIFY(EVP_MD_CTX_copy)); | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| /* External methods for a hash object */ | |
| /*[clinic input] | |
| _hashlib.HASH.copy | |
| Return a copy of the hash object. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASH_copy_impl(HASHobject *self) | |
| /*[clinic end generated code: output=2545541af18d53d7 input=814b19202cd08a26]*/ | |
| { | |
| HASHobject *newobj; | |
| if ((newobj = new_hash_object(Py_TYPE(self))) == NULL) | |
| return NULL; | |
| if (_hashlib_HASH_copy_locked(self, newobj->ctx) < 0) { | |
| Py_DECREF(newobj); | |
| return NULL; | |
| } | |
| return (PyObject *)newobj; | |
| } | |
| static Py_ssize_t | |
| _hashlib_HASH_digest_compute(HASHobject *self, unsigned char *digest) | |
| { | |
| EVP_MD_CTX *ctx = py_wrapper_EVP_MD_CTX_new(); | |
| if (ctx == NULL) { | |
| return -1; | |
| } | |
| if (_hashlib_HASH_copy_locked(self, ctx) < 0) { | |
| goto error; | |
| } | |
| Py_ssize_t digest_size = EVP_MD_CTX_size(ctx); | |
| if (!EVP_DigestFinal(ctx, digest, NULL)) { | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_DigestFinal)); | |
| goto error; | |
| } | |
| EVP_MD_CTX_free(ctx); | |
| return digest_size; | |
| error: | |
| EVP_MD_CTX_free(ctx); | |
| return -1; | |
| } | |
| /*[clinic input] | |
| _hashlib.HASH.digest | |
| Return the digest value as a bytes object. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASH_digest_impl(HASHobject *self) | |
| /*[clinic end generated code: output=3fc6f9671d712850 input=d8d528d6e50af0de]*/ | |
| { | |
| unsigned char digest[EVP_MAX_MD_SIZE]; | |
| Py_ssize_t n = _hashlib_HASH_digest_compute(self, digest); | |
| return n < 0 ? NULL : PyBytes_FromStringAndSize((const char *)digest, n); | |
| } | |
| /*[clinic input] | |
| _hashlib.HASH.hexdigest | |
| Return the digest value as a string of hexadecimal digits. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASH_hexdigest_impl(HASHobject *self) | |
| /*[clinic end generated code: output=1b8e60d9711e7f4d input=ae7553f78f8372d8]*/ | |
| { | |
| unsigned char digest[EVP_MAX_MD_SIZE]; | |
| Py_ssize_t n = _hashlib_HASH_digest_compute(self, digest); | |
| return n < 0 ? NULL : _Py_strhex((const char *)digest, n); | |
| } | |
| /*[clinic input] | |
| _hashlib.HASH.update | |
| obj: object | |
| / | |
| Update this hash object's state with the provided string. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASH_update_impl(HASHobject *self, PyObject *obj) | |
| /*[clinic end generated code: output=62ad989754946b86 input=aa1ce20e3f92ceb6]*/ | |
| { | |
| int result; | |
| Py_buffer view; | |
| GET_BUFFER_VIEW_OR_ERROUT(obj, &view); | |
| HASHLIB_EXTERNAL_INSTRUCTIONS_LOCKED( | |
| self, view.len, | |
| result = _hashlib_HASH_hash(self, view.buf, view.len) | |
| ); | |
| PyBuffer_Release(&view); | |
| return result < 0 ? NULL : Py_None; | |
| } | |
| static PyMethodDef HASH_methods[] = { | |
| _HASHLIB_HASH_COPY_METHODDEF | |
| _HASHLIB_HASH_DIGEST_METHODDEF | |
| _HASHLIB_HASH_HEXDIGEST_METHODDEF | |
| _HASHLIB_HASH_UPDATE_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| static PyObject * | |
| _hashlib_HASH_get_blocksize(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HASHobject *self = HASHobject_CAST(op); | |
| long block_size = EVP_MD_CTX_block_size(self->ctx); | |
| return PyLong_FromLong(block_size); | |
| } | |
| static PyObject * | |
| _hashlib_HASH_get_digestsize(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HASHobject *self = HASHobject_CAST(op); | |
| long size = EVP_MD_CTX_size(self->ctx); | |
| return PyLong_FromLong(size); | |
| } | |
| static PyObject * | |
| _hashlib_HASH_get_name(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HASHobject *self = HASHobject_CAST(op); | |
| const EVP_MD *md = PY_EVP_MD_CTX_md(self->ctx); | |
| if (md == NULL) { | |
| notify_ssl_error_occurred("missing EVP_MD for HASH context"); | |
| return NULL; | |
| } | |
| const char *name = get_hashlib_utf8name_by_evp_md(md); | |
| assert(name != NULL || PyErr_Occurred()); | |
| return name == NULL ? NULL : PyUnicode_FromString(name); | |
| } | |
| static PyGetSetDef HASH_getsets[] = { | |
| {"digest_size", _hashlib_HASH_get_digestsize, NULL, NULL, NULL}, | |
| {"block_size", _hashlib_HASH_get_blocksize, NULL, NULL, NULL}, | |
| {"name", _hashlib_HASH_get_name, NULL, NULL, PyDoc_STR("algorithm name.")}, | |
| {NULL} /* Sentinel */ | |
| }; | |
| static PyObject * | |
| _hashlib_HASH_repr(PyObject *self) | |
| { | |
| PyObject *name = _hashlib_HASH_get_name(self, NULL); | |
| if (name == NULL) { | |
| return NULL; | |
| } | |
| PyObject *repr = PyUnicode_FromFormat("<%U %T object @ %p>", | |
| name, self, self); | |
| Py_DECREF(name); | |
| return repr; | |
| } | |
| PyDoc_STRVAR(HASHobject_type_doc, | |
| "HASH(name, string=b\'\')\n" | |
| "--\n" | |
| "\n" | |
| "A hash is an object used to calculate a checksum of a string of information.\n" | |
| "\n" | |
| "Methods:\n" | |
| "\n" | |
| "update() -- updates the current digest with an additional string\n" | |
| "digest() -- return the current digest value\n" | |
| "hexdigest() -- return the current digest as a string of hexadecimal digits\n" | |
| "copy() -- return a copy of the current hash object\n" | |
| "\n" | |
| "Attributes:\n" | |
| "\n" | |
| "name -- the hash algorithm being used by this object\n" | |
| "digest_size -- number of bytes in this hashes output"); | |
| static PyType_Slot HASHobject_type_slots[] = { | |
| {Py_tp_dealloc, _hashlib_HASH_dealloc}, | |
| {Py_tp_repr, _hashlib_HASH_repr}, | |
| {Py_tp_doc, (char *)HASHobject_type_doc}, | |
| {Py_tp_methods, HASH_methods}, | |
| {Py_tp_getset, HASH_getsets}, | |
| {0, 0}, | |
| }; | |
| static PyType_Spec HASHobject_type_spec = { | |
| .name = "_hashlib.HASH", | |
| .basicsize = sizeof(HASHobject), | |
| .flags = ( | |
| Py_TPFLAGS_DEFAULT | |
| | Py_TPFLAGS_BASETYPE | |
| | Py_TPFLAGS_DISALLOW_INSTANTIATION | |
| | Py_TPFLAGS_IMMUTABLETYPE | |
| ), | |
| .slots = HASHobject_type_slots | |
| }; | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| /*[clinic input] | |
| _hashlib.HASHXOF.digest | |
| length: Py_ssize_t(allow_negative=False) | |
| Return the digest value as a bytes object. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASHXOF_digest_impl(HASHobject *self, Py_ssize_t length) | |
| /*[clinic end generated code: output=dcb09335dd2fe908 input=224d047da2c12a42]*/ | |
| { | |
| EVP_MD_CTX *temp_ctx; | |
| if (length == 0) { | |
| return Py_GetConstant(Py_CONSTANT_EMPTY_BYTES); | |
| } | |
| PyBytesWriter *writer = PyBytesWriter_Create(length); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| temp_ctx = py_wrapper_EVP_MD_CTX_new(); | |
| if (temp_ctx == NULL) { | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| if (_hashlib_HASH_copy_locked(self, temp_ctx) < 0) { | |
| goto error; | |
| } | |
| if (!EVP_DigestFinalXOF(temp_ctx, | |
| (unsigned char*)PyBytesWriter_GetData(writer), | |
| length)) | |
| { | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_DigestFinalXOF)); | |
| goto error; | |
| } | |
| EVP_MD_CTX_free(temp_ctx); | |
| return PyBytesWriter_Finish(writer); | |
| error: | |
| PyBytesWriter_Discard(writer); | |
| EVP_MD_CTX_free(temp_ctx); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| _hashlib.HASHXOF.hexdigest | |
| length: Py_ssize_t(allow_negative=False) | |
| Return the digest value as a string of hexadecimal digits. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASHXOF_hexdigest_impl(HASHobject *self, Py_ssize_t length) | |
| /*[clinic end generated code: output=519431cafa014f39 input=4a41b8ab5d3bfee2]*/ | |
| { | |
| unsigned char *digest; | |
| EVP_MD_CTX *temp_ctx; | |
| PyObject *retval; | |
| if (length == 0) { | |
| return Py_GetConstant(Py_CONSTANT_EMPTY_STR); | |
| } | |
| digest = (unsigned char*)PyMem_Malloc(length); | |
| if (digest == NULL) { | |
| (void)PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| temp_ctx = py_wrapper_EVP_MD_CTX_new(); | |
| if (temp_ctx == NULL) { | |
| PyMem_Free(digest); | |
| return NULL; | |
| } | |
| /* Get the raw (binary) digest value */ | |
| if (_hashlib_HASH_copy_locked(self, temp_ctx) < 0) { | |
| goto error; | |
| } | |
| if (!EVP_DigestFinalXOF(temp_ctx, digest, length)) { | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_DigestFinalXOF)); | |
| goto error; | |
| } | |
| EVP_MD_CTX_free(temp_ctx); | |
| retval = _Py_strhex((const char *)digest, length); | |
| PyMem_Free(digest); | |
| return retval; | |
| error: | |
| PyMem_Free(digest); | |
| EVP_MD_CTX_free(temp_ctx); | |
| return NULL; | |
| } | |
| static PyMethodDef HASHXOFobject_methods[] = { | |
| _HASHLIB_HASHXOF_DIGEST_METHODDEF | |
| _HASHLIB_HASHXOF_HEXDIGEST_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| static PyObject * | |
| _hashlib_HASHXOF_digest_size(PyObject *Py_UNUSED(self), | |
| void *Py_UNUSED(closure)) | |
| { | |
| return PyLong_FromLong(0); | |
| } | |
| static PyGetSetDef HASHXOFobject_getsets[] = { | |
| {"digest_size", _hashlib_HASHXOF_digest_size, NULL, NULL, NULL}, | |
| {NULL} /* Sentinel */ | |
| }; | |
| PyDoc_STRVAR(HASHXOFobject_type_doc, | |
| "HASHXOF(name, string=b\'\')\n" | |
| "--\n" | |
| "\n" | |
| "A hash is an object used to calculate a checksum of a string of information.\n" | |
| "\n" | |
| "Methods:\n" | |
| "\n" | |
| "update() -- updates the current digest with an additional string\n" | |
| "digest(length) -- return the current digest value\n" | |
| "hexdigest(length) -- return the current digest as a string of hexadecimal digits\n" | |
| "copy() -- return a copy of the current hash object\n" | |
| "\n" | |
| "Attributes:\n" | |
| "\n" | |
| "name -- the hash algorithm being used by this object\n" | |
| "digest_size -- number of bytes in this hashes output"); | |
| static PyType_Slot HASHXOFobject_type_slots[] = { | |
| {Py_tp_doc, (char *)HASHXOFobject_type_doc}, | |
| {Py_tp_methods, HASHXOFobject_methods}, | |
| {Py_tp_getset, HASHXOFobject_getsets}, | |
| {0, 0}, | |
| }; | |
| static PyType_Spec HASHXOFobject_type_spec = { | |
| .name = "_hashlib.HASHXOF", | |
| .basicsize = sizeof(HASHobject), | |
| .flags = ( | |
| Py_TPFLAGS_DEFAULT | |
| | Py_TPFLAGS_BASETYPE | |
| | Py_TPFLAGS_DISALLOW_INSTANTIATION | |
| | Py_TPFLAGS_IMMUTABLETYPE | |
| ), | |
| .slots = HASHXOFobject_type_slots | |
| }; | |
| #endif | |
| static PyObject * | |
| _hashlib_HASH(_hashlibstate *state, const char *digestname, PyObject *data_obj, | |
| int usedforsecurity) | |
| { | |
| Py_buffer view = { 0 }; | |
| PY_EVP_MD *digest = NULL; | |
| PyTypeObject *type; | |
| HASHobject *self = NULL; | |
| if (data_obj != NULL) { | |
| GET_BUFFER_VIEW_OR_ERROUT(data_obj, &view); | |
| } | |
| Py_hash_type purpose = usedforsecurity ? Py_ht_evp : Py_ht_evp_nosecurity; | |
| digest = get_openssl_evp_md_by_utf8name(state, digestname, purpose); | |
| if (digest == NULL) { | |
| goto exit; | |
| } | |
| type = PY_EVP_MD_xof(digest) ? state->HASHXOF_type : state->HASH_type; | |
| self = new_hash_object(type); | |
| if (self == NULL) { | |
| goto exit; | |
| } | |
| #if defined(EVP_MD_CTX_FLAG_NON_FIPS_ALLOW) && OPENSSL_VERSION_NUMBER < 0x30000000L | |
| // In OpenSSL 1.1.1 the non FIPS allowed flag is context specific while | |
| // in 3.0.0 it is a different EVP_MD provider. | |
| if (!usedforsecurity) { | |
| EVP_MD_CTX_set_flags(self->ctx, EVP_MD_CTX_FLAG_NON_FIPS_ALLOW); | |
| } | |
| #endif | |
| int result = EVP_DigestInit_ex(self->ctx, digest, NULL); | |
| if (!result) { | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_DigestInit_ex)); | |
| Py_CLEAR(self); | |
| goto exit; | |
| } | |
| if (view.buf && view.len) { | |
| /* Do not use self->mutex here as this is the constructor | |
| * where it is not yet possible to have concurrent access. */ | |
| HASHLIB_EXTERNAL_INSTRUCTIONS_UNLOCKED( | |
| view.len, | |
| result = _hashlib_HASH_hash(self, view.buf, view.len) | |
| ); | |
| if (result == -1) { | |
| assert(PyErr_Occurred()); | |
| Py_CLEAR(self); | |
| goto exit; | |
| } | |
| } | |
| exit: | |
| if (data_obj != NULL) { | |
| PyBuffer_Release(&view); | |
| } | |
| if (digest != NULL) { | |
| PY_EVP_MD_free(digest); | |
| } | |
| return (PyObject *)self; | |
| } | |
| // In Python 3.19, we can remove the "STRING" argument and would also be able | |
| // to remove the macro (or keep it as an alias for better naming) since calls | |
| // to _hashlib_HASH_new_impl() would fit on 80 characters. | |
| #define CALL_HASHLIB_NEW(MODULE, NAME, DATA, STRING, USEDFORSECURITY) \ | |
| return _hashlib_HASH_new_impl(MODULE, NAME, DATA, USEDFORSECURITY, STRING) | |
| /* The module-level function: new() */ | |
| /*[clinic input] | |
| _hashlib.new as _hashlib_HASH_new | |
| name: str | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Return a new hash object using the named algorithm. | |
| An optional string argument may be provided and will be | |
| automatically hashed. | |
| The MD5 and SHA1 algorithms are always supported. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HASH_new_impl(PyObject *module, const char *name, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=b905aaf9840c1bbd input=c34af6c6e696d44e]*/ | |
| { | |
| PyObject *data_obj; | |
| if (_Py_hashlib_data_argument(&data_obj, data, string) < 0) { | |
| return NULL; | |
| } | |
| _hashlibstate *state = get_hashlib_state(module); | |
| return _hashlib_HASH(state, name, data_obj, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_md5 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a md5 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_md5_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=ca8cf184d90f7432 input=e7c0adbd6a867db1]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_md5, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha1 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha1 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha1_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=1736fb7b310d64be input=f7e5bb1711e952d8]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha1, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha224 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha224 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha224_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=0d6ff57be5e5c140 input=3820fff7ed3a53b8]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha224, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha256 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha256 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha256_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=412ea7111555b6e7 input=9a2f115cf1f7e0eb]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha256, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha384 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha384 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha384_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=2e0dc395b59ed726 input=1ea48f6f01e77cfb]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha384, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha512 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha512 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha512_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=4bdd760388dbfc0f input=3cf56903e07d1f5c]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha512, data, string, usedforsecurity); | |
| } | |
| #ifdef PY_OPENSSL_HAS_SHA3 | |
| /*[clinic input] | |
| _hashlib.openssl_sha3_224 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha3-224 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha3_224_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=6d8dc2a924f3ba35 input=7f14f16a9f6a3158]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha3_224, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha3_256 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha3-256 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha3_256_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=9e520f537b3a4622 input=7987150939d5e352]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha3_256, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha3_384 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha3-384 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha3_384_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=d239ba0463fd6138 input=fc943401f67e3b81]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha3_384, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| _hashlib.openssl_sha3_512 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a sha3-512 hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_sha3_512_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=17662f21038c2278 input=6601ddd2c6c1516d]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_sha3_512, data, string, usedforsecurity); | |
| } | |
| #endif /* PY_OPENSSL_HAS_SHA3 */ | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| /*[clinic input] | |
| @permit_long_summary | |
| _hashlib.openssl_shake_128 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a shake-128 variable hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_shake_128_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=4e6afed8d18980ad input=0d2803af1158b23c]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_shake_128, data, string, usedforsecurity); | |
| } | |
| /*[clinic input] | |
| @permit_long_summary | |
| _hashlib.openssl_shake_256 | |
| data: object(c_default="NULL") = b'' | |
| * | |
| usedforsecurity: bool = True | |
| string: object(c_default="NULL") = None | |
| Returns a shake-256 variable hash object; optionally initialized with a string | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_openssl_shake_256_impl(PyObject *module, PyObject *data, | |
| int usedforsecurity, PyObject *string) | |
| /*[clinic end generated code: output=62481bce4a77d16c input=f27b98d9c749f55d]*/ | |
| { | |
| CALL_HASHLIB_NEW(module, Py_hash_shake_256, data, string, usedforsecurity); | |
| } | |
| #endif /* PY_OPENSSL_HAS_SHAKE */ | |
| #undef CALL_HASHLIB_NEW | |
| /*[clinic input] | |
| @permit_long_summary | |
| _hashlib.pbkdf2_hmac as pbkdf2_hmac | |
| hash_name: str | |
| password: Py_buffer | |
| salt: Py_buffer | |
| iterations: long | |
| dklen as dklen_obj: object = None | |
| Password based key derivation function 2 (PKCS #5 v2.0) with HMAC as pseudorandom function. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| pbkdf2_hmac_impl(PyObject *module, const char *hash_name, | |
| Py_buffer *password, Py_buffer *salt, long iterations, | |
| PyObject *dklen_obj) | |
| /*[clinic end generated code: output=144b76005416599b input=83417fbd9ec2b8a3]*/ | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| PyObject *key_obj = NULL; | |
| long dklen; | |
| int retval; | |
| PY_EVP_MD *digest = get_openssl_evp_md_by_utf8name(state, hash_name, | |
| Py_ht_pbkdf2); | |
| if (digest == NULL) { | |
| goto end; | |
| } | |
| if (password->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "password is too long."); | |
| goto end; | |
| } | |
| if (salt->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "salt is too long."); | |
| goto end; | |
| } | |
| if (iterations < 1) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "iteration value must be greater than 0."); | |
| goto end; | |
| } | |
| if (iterations > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "iteration value is too great."); | |
| goto end; | |
| } | |
| if (dklen_obj == Py_None) { | |
| dklen = EVP_MD_size(digest); | |
| } else { | |
| dklen = PyLong_AsLong(dklen_obj); | |
| if ((dklen == -1) && PyErr_Occurred()) { | |
| goto end; | |
| } | |
| } | |
| if (dklen < 1) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "key length must be greater than 0."); | |
| goto end; | |
| } | |
| if (dklen > INT_MAX) { | |
| /* INT_MAX is always smaller than dkLen max (2^32 - 1) * hLen */ | |
| PyErr_SetString(PyExc_OverflowError, | |
| "key length is too great."); | |
| goto end; | |
| } | |
| PyBytesWriter *writer = PyBytesWriter_Create(dklen); | |
| if (writer == NULL) { | |
| goto end; | |
| } | |
| Py_BEGIN_ALLOW_THREADS | |
| retval = PKCS5_PBKDF2_HMAC((const char *)password->buf, (int)password->len, | |
| (const unsigned char *)salt->buf, (int)salt->len, | |
| iterations, digest, dklen, | |
| (unsigned char *)PyBytesWriter_GetData(writer)); | |
| Py_END_ALLOW_THREADS | |
| if (!retval) { | |
| PyBytesWriter_Discard(writer); | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(PKCS5_PBKDF2_HMAC)); | |
| goto end; | |
| } | |
| key_obj = PyBytesWriter_Finish(writer); | |
| end: | |
| if (digest != NULL) { | |
| PY_EVP_MD_free(digest); | |
| } | |
| return key_obj; | |
| } | |
| // --- PBKDF: scrypt (RFC 7914) ----------------------------------------------- | |
| /* | |
| * By default, OpenSSL 1.1.0 restricts 'maxmem' in EVP_PBE_scrypt() | |
| * to 32 MiB (1024 * 1024 * 32) but only if 'maxmem = 0' and allows | |
| * for an arbitrary large limit fitting on an uint64_t otherwise. | |
| * | |
| * For legacy reasons, we limited 'maxmem' to be at most INTMAX, | |
| * but if users need a more relaxed value, we will revisit this | |
| * limit in the future. | |
| */ | |
| #define HASHLIB_SCRYPT_MAX_MAXMEM INT_MAX | |
| /* | |
| * Limit 'dklen' to INT_MAX even if it can be at most (32 * UINT32_MAX). | |
| * | |
| * See https://datatracker.ietf.org/doc/html/rfc7914.html for details. | |
| */ | |
| #define HASHLIB_SCRYPT_MAX_DKLEN INT_MAX | |
| /*[clinic input] | |
| _hashlib.scrypt | |
| password: Py_buffer | |
| * | |
| salt: Py_buffer | |
| n: unsigned_long | |
| r: unsigned_long | |
| p: unsigned_long | |
| maxmem: long = 0 | |
| dklen: long = 64 | |
| scrypt password-based key derivation function. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_scrypt_impl(PyObject *module, Py_buffer *password, Py_buffer *salt, | |
| unsigned long n, unsigned long r, unsigned long p, | |
| long maxmem, long dklen) | |
| /*[clinic end generated code: output=d424bc3e8c6b9654 input=bdeac9628d07f7a1]*/ | |
| { | |
| int retval; | |
| if (password->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, "password is too long"); | |
| return NULL; | |
| } | |
| if (salt->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, "salt is too long"); | |
| return NULL; | |
| } | |
| if (n < 2 || n & (n - 1)) { | |
| PyErr_SetString(PyExc_ValueError, "n must be a power of 2"); | |
| return NULL; | |
| } | |
| if (maxmem < 0 || maxmem > HASHLIB_SCRYPT_MAX_MAXMEM) { | |
| PyErr_Format(PyExc_ValueError, | |
| "maxmem must be positive and at most %d", | |
| HASHLIB_SCRYPT_MAX_MAXMEM); | |
| return NULL; | |
| } | |
| if (dklen < 1 || dklen > HASHLIB_SCRYPT_MAX_DKLEN) { | |
| PyErr_Format(PyExc_ValueError, | |
| "dklen must be at least 1 and at most %d", | |
| HASHLIB_SCRYPT_MAX_DKLEN); | |
| return NULL; | |
| } | |
| /* let OpenSSL validate the rest */ | |
| retval = EVP_PBE_scrypt(NULL, 0, NULL, 0, n, r, p, | |
| (uint64_t)maxmem, NULL, 0); | |
| if (!retval) { | |
| notify_ssl_error_occurred("invalid parameter combination for " | |
| "n, r, p, and maxmem"); | |
| return NULL; | |
| } | |
| PyBytesWriter *writer = PyBytesWriter_Create(dklen); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| Py_BEGIN_ALLOW_THREADS | |
| retval = EVP_PBE_scrypt( | |
| (const char *)password->buf, (size_t)password->len, | |
| (const unsigned char *)salt->buf, (size_t)salt->len, | |
| (uint64_t)n, (uint64_t)r, (uint64_t)p, (uint64_t)maxmem, | |
| (unsigned char *)PyBytesWriter_GetData(writer), (size_t)dklen | |
| ); | |
| Py_END_ALLOW_THREADS | |
| if (!retval) { | |
| PyBytesWriter_Discard(writer); | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_PBE_scrypt)); | |
| return NULL; | |
| } | |
| return PyBytesWriter_Finish(writer); | |
| } | |
| #undef HASHLIB_SCRYPT_MAX_DKLEN | |
| #undef HASHLIB_SCRYPT_MAX_MAXMEM | |
| // --- OpenSSL HMAC interface ------------------------------------------------- | |
| /* | |
| * Functions prefixed by hashlib_openssl_HMAC_* are wrappers around OpenSSL | |
| * and implement "atomic" operations (e.g., "free"). These functions are used | |
| * by those prefixed by _hashlib_HMAC_* that are methods for HMAC objects, or | |
| * other (local) helper functions prefixed by hashlib_HMAC_*. | |
| */ | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| /* EVP_MAC_CTX array of parameters specifying the "digest" */ | |
| #define HASHLIB_HMAC_OSSL_PARAMS(DIGEST) \ | |
| (const OSSL_PARAM []) { \ | |
| OSSL_PARAM_utf8_string(OSSL_MAC_PARAM_DIGEST, \ | |
| (char *)DIGEST, strlen(DIGEST)), \ | |
| OSSL_PARAM_END \ | |
| } | |
| #endif | |
| // --- One-shot HMAC interface ------------------------------------------------ | |
| /*[clinic input] | |
| _hashlib.hmac_digest as _hashlib_hmac_singleshot | |
| key: Py_buffer | |
| msg: Py_buffer | |
| digest: object | |
| Single-shot HMAC. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_hmac_singleshot_impl(PyObject *module, Py_buffer *key, | |
| Py_buffer *msg, PyObject *digest) | |
| /*[clinic end generated code: output=82f19965d12706ac input=0a0790cc3db45c2e]*/ | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| unsigned char md[EVP_MAX_MD_SIZE] = {0}; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| size_t md_len = 0; | |
| const char *digest_name = NULL; | |
| #else | |
| unsigned int md_len = 0; | |
| #endif | |
| unsigned char *result = NULL; | |
| PY_EVP_MD *evp = NULL; | |
| int is_xof; | |
| if (key->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "key is too long."); | |
| return NULL; | |
| } | |
| if (msg->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "msg is too long."); | |
| return NULL; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| digest_name = get_openssl_digest_name(state, digest, Py_ht_mac, &evp); | |
| if (digest_name == NULL) { | |
| assert(evp == NULL); | |
| return NULL; | |
| } | |
| assert(evp != NULL); | |
| is_xof = PY_EVP_MD_xof(evp); | |
| Py_BEGIN_ALLOW_THREADS | |
| result = EVP_Q_mac( | |
| NULL, OSSL_MAC_NAME_HMAC, NULL, NULL, | |
| HASHLIB_HMAC_OSSL_PARAMS(digest_name), | |
| (const void *)key->buf, (size_t)key->len, | |
| (const unsigned char *)msg->buf, (size_t)msg->len, | |
| md, sizeof(md), &md_len | |
| ); | |
| Py_END_ALLOW_THREADS | |
| PY_EVP_MD_free(evp); | |
| assert(md_len < (size_t)PY_SSIZE_T_MAX); | |
| #else | |
| evp = get_openssl_evp_md(state, digest, Py_ht_mac); | |
| if (evp == NULL) { | |
| return NULL; | |
| } | |
| is_xof = PY_EVP_MD_xof(evp); | |
| Py_BEGIN_ALLOW_THREADS | |
| result = HMAC( | |
| evp, | |
| (const void *)key->buf, (int)key->len, | |
| (const unsigned char *)msg->buf, (size_t)msg->len, | |
| md, &md_len | |
| ); | |
| Py_END_ALLOW_THREADS | |
| PY_EVP_MD_free(evp); | |
| #endif | |
| if (result == NULL) { | |
| if (is_xof) { | |
| /* use a better default error message if an XOF is used */ | |
| raise_unsupported_algorithm_error(state, digest); | |
| } | |
| else { | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_Q_mac)); | |
| #else | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(HMAC)); | |
| #endif | |
| } | |
| return NULL; | |
| } | |
| return PyBytes_FromStringAndSize((const char*)md, md_len); | |
| } | |
| // --- HMAC Object ------------------------------------------------------------ | |
| #ifndef Py_HAS_OPENSSL3_SUPPORT | |
| /* Thin wrapper around HMAC_CTX_new() which sets an exception on failure. */ | |
| static HMAC_CTX * | |
| py_openssl_wrapper_HMAC_CTX_new(void) | |
| { | |
| HMAC_CTX *ctx = HMAC_CTX_new(); | |
| if (ctx == NULL) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| return ctx; | |
| } | |
| #endif | |
| static int _hmac_update(HMACobject*, PyObject*); | |
| #ifndef Py_HAS_OPENSSL3_SUPPORT | |
| static const EVP_MD * | |
| _hashlib_hmac_get_md(HMACobject *self) | |
| { | |
| assert(self->ctx != NULL); | |
| const EVP_MD *md = HMAC_CTX_get_md(self->ctx); | |
| if (md == NULL) { | |
| notify_ssl_error_occurred("missing EVP_MD for HMAC context"); | |
| } | |
| return md; | |
| } | |
| #endif | |
| static const char * | |
| hashlib_HMAC_get_hashlib_digest_name(HMACobject *self) | |
| { | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| return get_hashlib_utf8name_by_nid(self->evp_md_nid); | |
| #else | |
| const EVP_MD *md = _hashlib_hmac_get_md(self); | |
| return md == NULL ? NULL : get_hashlib_utf8name_by_evp_md(md); | |
| #endif | |
| } | |
| static int | |
| hashlib_openssl_HMAC_update_once(PY_HMAC_CTX_TYPE *ctx, const Py_buffer *v) | |
| { | |
| if (!PY_HMAC_update(ctx, (const unsigned char *)v->buf, (size_t)v->len)) { | |
| notify_smart_ssl_error_occurred_in(Py_STRINGIFY(PY_HMAC_update)); | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| /* Thin wrapper around PY_HMAC_CTX_free that allows to pass a NULL 'ctx'. */ | |
| static inline void | |
| hashlib_openssl_HMAC_CTX_free(PY_HMAC_CTX_TYPE *ctx) | |
| { | |
| /* The NULL check was not present in every OpenSSL versions. */ | |
| if (ctx) { | |
| PY_HMAC_CTX_free(ctx); | |
| } | |
| } | |
| static PY_HMAC_CTX_TYPE * | |
| hashlib_openssl_HMAC_ctx_copy_with_lock(HMACobject *self) | |
| { | |
| PY_HMAC_CTX_TYPE *ctx = NULL; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| HASHLIB_ACQUIRE_LOCK(self); | |
| ctx = EVP_MAC_CTX_dup(self->ctx); | |
| HASHLIB_RELEASE_LOCK(self); | |
| if (ctx == NULL) { | |
| notify_smart_ssl_error_occurred_in(Py_STRINGIFY(EVP_MAC_CTX_dup)); | |
| goto error; | |
| } | |
| #else | |
| int r; | |
| ctx = py_openssl_wrapper_HMAC_CTX_new(); | |
| if (ctx == NULL) { | |
| return NULL; | |
| } | |
| HASHLIB_ACQUIRE_LOCK(self); | |
| r = HMAC_CTX_copy(ctx, self->ctx); | |
| HASHLIB_RELEASE_LOCK(self); | |
| if (r == 0) { | |
| notify_smart_ssl_error_occurred_in(Py_STRINGIFY(HMAC_CTX_copy)); | |
| goto error; | |
| } | |
| #endif | |
| return ctx; | |
| error: | |
| hashlib_openssl_HMAC_CTX_free(ctx); | |
| return NULL; | |
| } | |
| static PY_HMAC_CTX_TYPE * | |
| hashlib_HMAC_CTX_new_from_digestmod(_hashlibstate *state, | |
| Py_buffer *key, PyObject *digestmod, | |
| int *nid) | |
| { | |
| PY_HMAC_CTX_TYPE *ctx = NULL; | |
| PY_EVP_MD *md = NULL; | |
| int is_xof, r; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| const char *digest = NULL; | |
| #endif | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| /* | |
| * OpenSSL 3.0 does not provide a way to extract the NID from an EVP_MAC | |
| * object and does not expose the underlying digest name. The reason is | |
| * that OpenSSL 3.0 treats HMAC objects as being the "same", differing | |
| * only by their *context* parameters. While it is *required* to set | |
| * the digest name when constructing EVP_MAC_CTX objects, that name | |
| * is unfortunately not recoverable through EVP_MAC_CTX_get_params(). | |
| * | |
| * On the other hand, the (deprecated) interface based on HMAC_CTX is | |
| * based on EVP_MD, which allows to treat HMAC objects as if they were | |
| * hash functions when querying the digest name. | |
| * | |
| * Since HMAC objects are constructed from DIGESTMOD values and since | |
| * we have a way to map DIGESTMOD to EVP_MD objects, and then to NIDs, | |
| * HMAC objects based on EVP_MAC will store the NID of the EVP_MD we | |
| * used to deduce the digest name to pass to EVP_MAC_CTX_set_params(). | |
| */ | |
| assert(nid != NULL); | |
| digest = get_openssl_digest_name(state, digestmod, Py_ht_mac, &md); | |
| assert((digest == NULL && md == NULL) || (digest != NULL && md != NULL)); | |
| if (digest == NULL) { | |
| *nid = NID_undef; | |
| return NULL; | |
| } | |
| *nid = EVP_MD_nid(md); | |
| is_xof = PY_EVP_MD_xof(md); | |
| PY_EVP_MD_free(md); | |
| /* | |
| * OpenSSL is responsible for managing the EVP_MAC object's ref. count | |
| * by calling EVP_MAC_up_ref() and EVP_MAC_free() in EVP_MAC_CTX_new() | |
| * and EVP_MAC_CTX_free() respectively. | |
| */ | |
| ctx = EVP_MAC_CTX_new(state->evp_hmac); | |
| if (ctx == NULL) { | |
| /* EVP_MAC_CTX_new() may also set an ERR_R_EVP_LIB error */ | |
| notify_smart_ssl_error_occurred_in(Py_STRINGIFY(EVP_MAC_CTX_new)); | |
| return NULL; | |
| } | |
| r = EVP_MAC_init( | |
| ctx, | |
| (const unsigned char *)key->buf, | |
| (size_t)key->len, | |
| HASHLIB_HMAC_OSSL_PARAMS(digest) | |
| ); | |
| #else | |
| assert(nid == NULL); | |
| md = get_openssl_evp_md(state, digestmod, Py_ht_mac); | |
| if (md == NULL) { | |
| return NULL; | |
| } | |
| is_xof = PY_EVP_MD_xof(md); | |
| ctx = py_openssl_wrapper_HMAC_CTX_new(); | |
| if (ctx == NULL) { | |
| PY_EVP_MD_free(md); | |
| return NULL; | |
| } | |
| r = HMAC_Init_ex(ctx, key->buf, (int)key->len, md, NULL /* impl */); | |
| PY_EVP_MD_free(md); | |
| #endif | |
| if (r == 0) { | |
| if (is_xof) { | |
| /* use a better default error message if an XOF is used */ | |
| raise_unsupported_algorithm_error(state, digestmod); | |
| } | |
| else { | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_MAC_init)); | |
| #else | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(HMAC_Init_ex)); | |
| #endif | |
| } | |
| return NULL; | |
| } | |
| return ctx; | |
| } | |
| /*[clinic input] | |
| _hashlib.hmac_new | |
| key: Py_buffer | |
| msg as msg_obj: object(c_default="NULL") = b'' | |
| digestmod: object(c_default="NULL") = None | |
| Return a new hmac object. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_hmac_new_impl(PyObject *module, Py_buffer *key, PyObject *msg_obj, | |
| PyObject *digestmod) | |
| /*[clinic end generated code: output=c20d9e4d9ed6d219 input=5f4071dcc7f34362]*/ | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| PY_HMAC_CTX_TYPE *ctx = NULL; | |
| HMACobject *self = NULL; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| int nid; | |
| #endif | |
| if (key->len > INT_MAX) { | |
| PyErr_SetString(PyExc_OverflowError, | |
| "key is too long."); | |
| return NULL; | |
| } | |
| if (digestmod == NULL) { | |
| PyErr_SetString(PyExc_TypeError, | |
| "Missing required parameter 'digestmod'."); | |
| return NULL; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| ctx = hashlib_HMAC_CTX_new_from_digestmod(state, key, digestmod, &nid); | |
| #else | |
| ctx = hashlib_HMAC_CTX_new_from_digestmod(state, key, digestmod, NULL); | |
| #endif | |
| if (ctx == NULL) { | |
| assert(PyErr_Occurred()); | |
| return NULL; | |
| } | |
| self = PyObject_New(HMACobject, state->HMAC_type); | |
| if (self == NULL) { | |
| goto error; | |
| } | |
| self->ctx = ctx; | |
| ctx = NULL; // 'ctx' is now owned by 'self' | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| assert(nid != NID_undef); | |
| self->evp_md_nid = nid; | |
| #endif | |
| HASHLIB_INIT_MUTEX(self); | |
| /* feed initial data */ | |
| if ((msg_obj != NULL) && (msg_obj != Py_None)) { | |
| if (_hmac_update(self, msg_obj) < 0) { | |
| goto error; | |
| } | |
| } | |
| return (PyObject *)self; | |
| error: | |
| hashlib_openssl_HMAC_CTX_free(ctx); | |
| Py_XDECREF(self); | |
| return NULL; | |
| } | |
| /* helper functions */ | |
| #define BAD_DIGEST_SIZE 0 | |
| /* | |
| * Return the digest size in bytes. | |
| * | |
| * On error, set an exception and return BAD_DIGEST_SIZE. | |
| */ | |
| static unsigned int | |
| _hashlib_hmac_digest_size(HMACobject *self) | |
| { | |
| assert(EVP_MAX_MD_SIZE < INT_MAX); | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| assert(self->ctx != NULL); | |
| size_t digest_size = EVP_MAC_CTX_get_mac_size(self->ctx); | |
| assert(digest_size <= (size_t)EVP_MAX_MD_SIZE); | |
| #else | |
| const EVP_MD *md = _hashlib_hmac_get_md(self); | |
| if (md == NULL) { | |
| return BAD_DIGEST_SIZE; | |
| } | |
| int digest_size = EVP_MD_size(md); | |
| /* digest_size < 0 iff EVP_MD context is NULL (which is impossible here) */ | |
| assert(digest_size >= 0); | |
| assert(digest_size <= (int)EVP_MAX_MD_SIZE); | |
| #endif | |
| /* digest_size == 0 means that the context is not entirely initialized */ | |
| if (digest_size == 0) { | |
| raise_ssl_error(PyExc_ValueError, "missing digest size"); | |
| return BAD_DIGEST_SIZE; | |
| } | |
| return (unsigned int)digest_size; | |
| } | |
| static int | |
| _hmac_update(HMACobject *self, PyObject *obj) | |
| { | |
| int r; | |
| Py_buffer view = {0}; | |
| GET_BUFFER_VIEW_OR_ERROR(obj, &view, return -1); | |
| HASHLIB_EXTERNAL_INSTRUCTIONS_LOCKED( | |
| self, view.len, | |
| r = hashlib_openssl_HMAC_update_once(self->ctx, &view) | |
| ); | |
| PyBuffer_Release(&view); | |
| return r; | |
| } | |
| /*[clinic input] | |
| _hashlib.HMAC.copy | |
| Return a copy ("clone") of the HMAC object. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HMAC_copy_impl(HMACobject *self) | |
| /*[clinic end generated code: output=29aa28b452833127 input=e2fa6a05db61a4d6]*/ | |
| { | |
| HMACobject *retval; | |
| PY_HMAC_CTX_TYPE *ctx = hashlib_openssl_HMAC_ctx_copy_with_lock(self); | |
| if (ctx == NULL) { | |
| return NULL; | |
| } | |
| retval = PyObject_New(HMACobject, Py_TYPE(self)); | |
| if (retval == NULL) { | |
| PY_HMAC_CTX_free(ctx); | |
| return NULL; | |
| } | |
| retval->ctx = ctx; | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| retval->evp_md_nid = self->evp_md_nid; | |
| #endif | |
| HASHLIB_INIT_MUTEX(retval); | |
| return (PyObject *)retval; | |
| } | |
| static void | |
| _hmac_dealloc(PyObject *op) | |
| { | |
| HMACobject *self = HMACobject_CAST(op); | |
| PyTypeObject *tp = Py_TYPE(self); | |
| if (self->ctx != NULL) { | |
| PY_HMAC_CTX_free(self->ctx); | |
| self->ctx = NULL; | |
| } | |
| PyObject_Free(self); | |
| Py_DECREF(tp); | |
| } | |
| static PyObject * | |
| _hmac_repr(PyObject *op) | |
| { | |
| HMACobject *self = HMACobject_CAST(op); | |
| const char *digest_name = hashlib_HMAC_get_hashlib_digest_name(self); | |
| if (digest_name == NULL) { | |
| assert(PyErr_Occurred()); | |
| return NULL; | |
| } | |
| return PyUnicode_FromFormat("<%s HMAC object @ %p>", digest_name, self); | |
| } | |
| /*[clinic input] | |
| _hashlib.HMAC.update | |
| msg: object | |
| Update the HMAC object with msg. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HMAC_update_impl(HMACobject *self, PyObject *msg) | |
| /*[clinic end generated code: output=f31f0ace8c625b00 input=1829173bb3cfd4e6]*/ | |
| { | |
| if (_hmac_update(self, msg) < 0) { | |
| return NULL; | |
| } | |
| Py_RETURN_NONE; | |
| } | |
| /* | |
| * Extract the MAC value to 'buf' and return the digest size. | |
| * | |
| * The buffer 'buf' must have at least _hashlib_hmac_digest_size(self) | |
| * bytes. Smaller buffers lead to undefined behaviors. | |
| * | |
| * On error, set an exception and return -1. | |
| */ | |
| static Py_ssize_t | |
| _hmac_digest(HMACobject *self, unsigned char *buf) | |
| { | |
| unsigned int digest_size = _hashlib_hmac_digest_size(self); | |
| assert(digest_size <= EVP_MAX_MD_SIZE); | |
| if (digest_size == BAD_DIGEST_SIZE) { | |
| assert(PyErr_Occurred()); | |
| return -1; | |
| } | |
| PY_HMAC_CTX_TYPE *ctx = hashlib_openssl_HMAC_ctx_copy_with_lock(self); | |
| if (ctx == NULL) { | |
| return -1; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| int r = EVP_MAC_final(ctx, buf, NULL, digest_size); | |
| #else | |
| int r = HMAC_Final(ctx, buf, NULL); | |
| #endif | |
| PY_HMAC_CTX_free(ctx); | |
| if (r == 0) { | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(EVP_MAC_final)); | |
| #else | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(HMAC_Final)); | |
| #endif | |
| return -1; | |
| } | |
| return digest_size; | |
| } | |
| /*[clinic input] | |
| _hashlib.HMAC.digest | |
| Return the digest of the bytes passed to the update() method so far. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HMAC_digest_impl(HMACobject *self) | |
| /*[clinic end generated code: output=1b1424355af7a41e input=bff07f74da318fb4]*/ | |
| { | |
| unsigned char buf[EVP_MAX_MD_SIZE]; | |
| Py_ssize_t n = _hmac_digest(self, buf); | |
| return n < 0 ? NULL : PyBytes_FromStringAndSize((const char *)buf, n); | |
| } | |
| /*[clinic input] | |
| @permit_long_summary | |
| @permit_long_docstring_body | |
| _hashlib.HMAC.hexdigest | |
| Return hexadecimal digest of the bytes passed to the update() method so far. | |
| This may be used to exchange the value safely in email or other non-binary | |
| environments. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_HMAC_hexdigest_impl(HMACobject *self) | |
| /*[clinic end generated code: output=80d825be1eaae6a7 input=5e48db83ab1a4d19]*/ | |
| { | |
| unsigned char buf[EVP_MAX_MD_SIZE]; | |
| Py_ssize_t n = _hmac_digest(self, buf); | |
| return n < 0 ? NULL : _Py_strhex((const char *)buf, n); | |
| } | |
| static PyObject * | |
| _hashlib_hmac_get_digest_size(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HMACobject *self = HMACobject_CAST(op); | |
| unsigned int size = _hashlib_hmac_digest_size(self); | |
| return size == BAD_DIGEST_SIZE ? NULL : PyLong_FromLong(size); | |
| } | |
| static PyObject * | |
| _hashlib_hmac_get_block_size(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HMACobject *self = HMACobject_CAST(op); | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| assert(self->ctx != NULL); | |
| return PyLong_FromSize_t(EVP_MAC_CTX_get_block_size(self->ctx)); | |
| #else | |
| const EVP_MD *md = _hashlib_hmac_get_md(self); | |
| return md == NULL ? NULL : PyLong_FromLong(EVP_MD_block_size(md)); | |
| #endif | |
| } | |
| static PyObject * | |
| _hashlib_hmac_get_name(PyObject *op, void *Py_UNUSED(closure)) | |
| { | |
| HMACobject *self = HMACobject_CAST(op); | |
| const char *digest_name = hashlib_HMAC_get_hashlib_digest_name(self); | |
| if (digest_name == NULL) { | |
| assert(PyErr_Occurred()); | |
| return NULL; | |
| } | |
| return PyUnicode_FromFormat("hmac-%s", digest_name); | |
| } | |
| static PyMethodDef HMAC_methods[] = { | |
| _HASHLIB_HMAC_UPDATE_METHODDEF | |
| _HASHLIB_HMAC_DIGEST_METHODDEF | |
| _HASHLIB_HMAC_HEXDIGEST_METHODDEF | |
| _HASHLIB_HMAC_COPY_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| static PyGetSetDef HMAC_getset[] = { | |
| {"digest_size", _hashlib_hmac_get_digest_size, NULL, NULL, NULL}, | |
| {"block_size", _hashlib_hmac_get_block_size, NULL, NULL, NULL}, | |
| {"name", _hashlib_hmac_get_name, NULL, NULL, NULL}, | |
| {NULL} /* Sentinel */ | |
| }; | |
| PyDoc_STRVAR(hmactype_doc, | |
| "The object used to calculate HMAC of a message.\n\ | |
| \n\ | |
| Methods:\n\ | |
| \n\ | |
| update() -- updates the current digest with an additional string\n\ | |
| digest() -- return the current digest value\n\ | |
| hexdigest() -- return the current digest as a string of hexadecimal digits\n\ | |
| copy() -- return a copy of the current hash object\n\ | |
| \n\ | |
| Attributes:\n\ | |
| \n\ | |
| name -- the name, including the hash algorithm used by this object\n\ | |
| digest_size -- number of bytes in digest() output\n"); | |
| static PyType_Slot HMACtype_slots[] = { | |
| {Py_tp_doc, (char *)hmactype_doc}, | |
| {Py_tp_repr, _hmac_repr}, | |
| {Py_tp_dealloc, _hmac_dealloc}, | |
| {Py_tp_methods, HMAC_methods}, | |
| {Py_tp_getset, HMAC_getset}, | |
| {0, NULL} | |
| }; | |
| PyType_Spec HMACtype_spec = { | |
| "_hashlib.HMAC", /* name */ | |
| sizeof(HMACobject), /* basicsize */ | |
| .flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_DISALLOW_INSTANTIATION | Py_TPFLAGS_IMMUTABLETYPE, | |
| .slots = HMACtype_slots, | |
| }; | |
| /* State for our callback function so that it can accumulate a result. */ | |
| typedef struct _internal_name_mapper_state { | |
| PyObject *set; | |
| int error; | |
| } _InternalNameMapperState; | |
| /* A callback function to pass to OpenSSL's OBJ_NAME_do_all(...) */ | |
| static void | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| _openssl_hash_name_mapper(EVP_MD *md, void *arg) | |
| #else | |
| _openssl_hash_name_mapper(const EVP_MD *md, const char *from, | |
| const char *to, void *arg) | |
| #endif | |
| { | |
| _InternalNameMapperState *state = (_InternalNameMapperState *)arg; | |
| PyObject *py_name; | |
| assert(state != NULL); | |
| // ignore all undefined providers | |
| if ((md == NULL) || (EVP_MD_nid(md) == NID_undef)) { | |
| return; | |
| } | |
| const char *name = get_hashlib_utf8name_by_evp_md(md); | |
| assert(name != NULL || PyErr_Occurred()); | |
| py_name = name == NULL ? NULL : PyUnicode_FromString(name); | |
| if (py_name == NULL) { | |
| state->error = 1; | |
| } else { | |
| if (PySet_Add(state->set, py_name) != 0) { | |
| state->error = 1; | |
| } | |
| Py_DECREF(py_name); | |
| } | |
| } | |
| /* Ask OpenSSL for a list of supported ciphers, filling in a Python set. */ | |
| static int | |
| hashlib_md_meth_names(PyObject *module) | |
| { | |
| _InternalNameMapperState state = { | |
| .set = PyFrozenSet_New(NULL), | |
| .error = 0 | |
| }; | |
| if (state.set == NULL) { | |
| return -1; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| // get algorithms from all activated providers in default context | |
| EVP_MD_do_all_provided(NULL, &_openssl_hash_name_mapper, &state); | |
| #else | |
| EVP_MD_do_all(&_openssl_hash_name_mapper, &state); | |
| #endif | |
| if (state.error) { | |
| Py_DECREF(state.set); | |
| return -1; | |
| } | |
| return PyModule_Add(module, "openssl_md_meth_names", state.set); | |
| } | |
| /*[clinic input] | |
| _hashlib.get_fips_mode -> int | |
| Determine the OpenSSL FIPS mode of operation. | |
| For OpenSSL 3.0.0 and newer it returns the state of the default provider | |
| in the default OSSL context. It's not quite the same as FIPS_mode() but good | |
| enough for unittests. | |
| Effectively any non-zero return value indicates FIPS mode; | |
| values other than 1 may have additional significance. | |
| [clinic start generated code]*/ | |
| static int | |
| _hashlib_get_fips_mode_impl(PyObject *module) | |
| /*[clinic end generated code: output=87eece1bab4d3fa9 input=2db61538c41c6fef]*/ | |
| { | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| return EVP_default_properties_is_fips_enabled(NULL); | |
| #else | |
| ERR_clear_error(); | |
| int result = FIPS_mode(); | |
| if (result == 0 && ERR_peek_last_error()) { | |
| // "If the library was built without support of the FIPS Object Module, | |
| // then the function will return 0 with an error code of | |
| // CRYPTO_R_FIPS_MODE_NOT_SUPPORTED (0x0f06d065)." | |
| // But 0 is also a valid result value. | |
| notify_ssl_error_occurred_in(Py_STRINGIFY(FIPS_mode)); | |
| return -1; | |
| } | |
| return result; | |
| #endif | |
| } | |
| static int | |
| _tscmp(const unsigned char *a, const unsigned char *b, | |
| Py_ssize_t len_a, Py_ssize_t len_b) | |
| { | |
| /* loop count depends on length of b. Might leak very little timing | |
| * information if sizes are different. | |
| */ | |
| Py_ssize_t length = len_b; | |
| const void *left = a; | |
| const void *right = b; | |
| int result = 0; | |
| if (len_a != length) { | |
| left = b; | |
| result = 1; | |
| } | |
| result |= CRYPTO_memcmp(left, right, length); | |
| return (result == 0); | |
| } | |
| /* NOTE: Keep in sync with _operator.c implementation. */ | |
| /*[clinic input] | |
| _hashlib.compare_digest | |
| a: object | |
| b: object | |
| / | |
| Return 'a == b'. | |
| This function uses an approach designed to prevent | |
| timing analysis, making it appropriate for cryptography. | |
| a and b must both be of the same type: either str (ASCII only), | |
| or any bytes-like object. | |
| Note: If a and b are of different lengths, or if an error occurs, | |
| a timing attack could theoretically reveal information about the | |
| types and lengths of a and b--but not their values. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| _hashlib_compare_digest_impl(PyObject *module, PyObject *a, PyObject *b) | |
| /*[clinic end generated code: output=6f1c13927480aed9 input=9c40c6e566ca12f5]*/ | |
| { | |
| int rc; | |
| /* ASCII unicode string */ | |
| if(PyUnicode_Check(a) && PyUnicode_Check(b)) { | |
| if (!PyUnicode_IS_ASCII(a) || !PyUnicode_IS_ASCII(b)) { | |
| PyErr_SetString(PyExc_TypeError, | |
| "comparing strings with non-ASCII characters is " | |
| "not supported"); | |
| return NULL; | |
| } | |
| rc = _tscmp(PyUnicode_DATA(a), | |
| PyUnicode_DATA(b), | |
| PyUnicode_GET_LENGTH(a), | |
| PyUnicode_GET_LENGTH(b)); | |
| } | |
| /* fallback to buffer interface for bytes, bytearray and other */ | |
| else { | |
| Py_buffer view_a; | |
| Py_buffer view_b; | |
| if (PyObject_CheckBuffer(a) == 0 && PyObject_CheckBuffer(b) == 0) { | |
| PyErr_Format(PyExc_TypeError, | |
| "unsupported operand types(s) or combination of types: " | |
| "'%.100s' and '%.100s'", | |
| Py_TYPE(a)->tp_name, Py_TYPE(b)->tp_name); | |
| return NULL; | |
| } | |
| if (PyObject_GetBuffer(a, &view_a, PyBUF_SIMPLE) == -1) { | |
| return NULL; | |
| } | |
| if (view_a.ndim > 1) { | |
| PyErr_SetString(PyExc_BufferError, | |
| "Buffer must be single dimension"); | |
| PyBuffer_Release(&view_a); | |
| return NULL; | |
| } | |
| if (PyObject_GetBuffer(b, &view_b, PyBUF_SIMPLE) == -1) { | |
| PyBuffer_Release(&view_a); | |
| return NULL; | |
| } | |
| if (view_b.ndim > 1) { | |
| PyErr_SetString(PyExc_BufferError, | |
| "Buffer must be single dimension"); | |
| PyBuffer_Release(&view_a); | |
| PyBuffer_Release(&view_b); | |
| return NULL; | |
| } | |
| rc = _tscmp((const unsigned char*)view_a.buf, | |
| (const unsigned char*)view_b.buf, | |
| view_a.len, | |
| view_b.len); | |
| PyBuffer_Release(&view_a); | |
| PyBuffer_Release(&view_b); | |
| } | |
| return PyBool_FromLong(rc); | |
| } | |
| /* List of functions exported by this module */ | |
| static struct PyMethodDef EVP_functions[] = { | |
| _HASHLIB_HASH_NEW_METHODDEF | |
| PBKDF2_HMAC_METHODDEF | |
| _HASHLIB_SCRYPT_METHODDEF | |
| _HASHLIB_GET_FIPS_MODE_METHODDEF | |
| _HASHLIB_COMPARE_DIGEST_METHODDEF | |
| _HASHLIB_HMAC_SINGLESHOT_METHODDEF | |
| _HASHLIB_HMAC_NEW_METHODDEF | |
| _HASHLIB_OPENSSL_MD5_METHODDEF | |
| _HASHLIB_OPENSSL_SHA1_METHODDEF | |
| _HASHLIB_OPENSSL_SHA224_METHODDEF | |
| _HASHLIB_OPENSSL_SHA256_METHODDEF | |
| _HASHLIB_OPENSSL_SHA384_METHODDEF | |
| _HASHLIB_OPENSSL_SHA512_METHODDEF | |
| _HASHLIB_OPENSSL_SHA3_224_METHODDEF | |
| _HASHLIB_OPENSSL_SHA3_256_METHODDEF | |
| _HASHLIB_OPENSSL_SHA3_384_METHODDEF | |
| _HASHLIB_OPENSSL_SHA3_512_METHODDEF | |
| _HASHLIB_OPENSSL_SHAKE_128_METHODDEF | |
| _HASHLIB_OPENSSL_SHAKE_256_METHODDEF | |
| {NULL, NULL} /* Sentinel */ | |
| }; | |
| /* Initialize this module. */ | |
| static int | |
| hashlib_traverse(PyObject *m, visitproc visit, void *arg) | |
| { | |
| _hashlibstate *state = get_hashlib_state(m); | |
| Py_VISIT(state->HASH_type); | |
| Py_VISIT(state->HMAC_type); | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| Py_VISIT(state->HASHXOF_type); | |
| #endif | |
| Py_VISIT(state->constructs); | |
| Py_VISIT(state->unsupported_digestmod_error); | |
| return 0; | |
| } | |
| static int | |
| hashlib_clear(PyObject *m) | |
| { | |
| _hashlibstate *state = get_hashlib_state(m); | |
| Py_CLEAR(state->HASH_type); | |
| Py_CLEAR(state->HMAC_type); | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| Py_CLEAR(state->HASHXOF_type); | |
| #endif | |
| Py_CLEAR(state->constructs); | |
| Py_CLEAR(state->unsupported_digestmod_error); | |
| if (state->hashtable != NULL) { | |
| _Py_hashtable_destroy(state->hashtable); | |
| state->hashtable = NULL; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| if (state->evp_hmac != NULL) { | |
| EVP_MAC_free(state->evp_hmac); | |
| state->evp_hmac = NULL; | |
| } | |
| #endif | |
| return 0; | |
| } | |
| static void | |
| hashlib_free(void *m) | |
| { | |
| (void)hashlib_clear((PyObject *)m); | |
| } | |
| /* Py_mod_exec functions */ | |
| static int | |
| hashlib_init_hashtable(PyObject *module) | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| state->hashtable = py_hashentry_table_new(); | |
| if (state->hashtable == NULL) { | |
| PyErr_NoMemory(); | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static int | |
| hashlib_init_HASH_type(PyObject *module) | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| state->HASH_type = (PyTypeObject *)PyType_FromSpec(&HASHobject_type_spec); | |
| if (state->HASH_type == NULL) { | |
| return -1; | |
| } | |
| if (PyModule_AddType(module, state->HASH_type) < 0) { | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static int | |
| hashlib_init_HASHXOF_type(PyObject *module) | |
| { | |
| #ifdef PY_OPENSSL_HAS_SHAKE | |
| _hashlibstate *state = get_hashlib_state(module); | |
| if (state->HASH_type == NULL) { | |
| return -1; | |
| } | |
| state->HASHXOF_type = (PyTypeObject *)PyType_FromSpecWithBases( | |
| &HASHXOFobject_type_spec, (PyObject *)state->HASH_type | |
| ); | |
| if (state->HASHXOF_type == NULL) { | |
| return -1; | |
| } | |
| if (PyModule_AddType(module, state->HASHXOF_type) < 0) { | |
| return -1; | |
| } | |
| #endif | |
| return 0; | |
| } | |
| static int | |
| hashlib_init_hmactype(PyObject *module) | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| state->HMAC_type = (PyTypeObject *)PyType_FromSpec(&HMACtype_spec); | |
| if (state->HMAC_type == NULL) { | |
| return -1; | |
| } | |
| if (PyModule_AddType(module, state->HMAC_type) < 0) { | |
| return -1; | |
| } | |
| #ifdef Py_HAS_OPENSSL3_SUPPORT | |
| state->evp_hmac = EVP_MAC_fetch(NULL, "HMAC", NULL); | |
| if (state->evp_hmac == NULL) { | |
| ERR_clear_error(); | |
| PyErr_SetString(PyExc_ImportError, "cannot initialize EVP_MAC HMAC"); | |
| return -1; | |
| } | |
| #endif | |
| return 0; | |
| } | |
| static int | |
| hashlib_init_constructors(PyObject *module) | |
| { | |
| /* Create dict from builtin openssl_hash functions to name | |
| * {_hashlib.openssl_sha256: "sha256", ...} | |
| */ | |
| PyModuleDef *mdef; | |
| PyMethodDef *fdef; | |
| PyObject *func, *name_obj; | |
| _hashlibstate *state = get_hashlib_state(module); | |
| mdef = PyModule_GetDef(module); | |
| if (mdef == NULL) { | |
| return -1; | |
| } | |
| state->constructs = PyDict_New(); | |
| if (state->constructs == NULL) { | |
| return -1; | |
| } | |
| for (fdef = mdef->m_methods; fdef->ml_name != NULL; fdef++) { | |
| if (strncmp(fdef->ml_name, "openssl_", 8)) { | |
| continue; | |
| } | |
| name_obj = PyUnicode_FromString(fdef->ml_name + 8); | |
| if (name_obj == NULL) { | |
| return -1; | |
| } | |
| func = PyObject_GetAttrString(module, fdef->ml_name); | |
| if (func == NULL) { | |
| Py_DECREF(name_obj); | |
| return -1; | |
| } | |
| int rc = PyDict_SetItem(state->constructs, func, name_obj); | |
| Py_DECREF(func); | |
| Py_DECREF(name_obj); | |
| if (rc < 0) { | |
| return -1; | |
| } | |
| } | |
| return PyModule_Add(module, "_constructors", | |
| PyDictProxy_New(state->constructs)); | |
| } | |
| static int | |
| hashlib_exception(PyObject *module) | |
| { | |
| _hashlibstate *state = get_hashlib_state(module); | |
| state->unsupported_digestmod_error = PyErr_NewException( | |
| "_hashlib.UnsupportedDigestmodError", PyExc_ValueError, NULL); | |
| if (state->unsupported_digestmod_error == NULL) { | |
| return -1; | |
| } | |
| if (PyModule_AddObjectRef(module, "UnsupportedDigestmodError", | |
| state->unsupported_digestmod_error) < 0) { | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static int | |
| hashlib_constants(PyObject *module) | |
| { | |
| if (PyModule_AddIntConstant(module, "_GIL_MINSIZE", | |
| HASHLIB_GIL_MINSIZE) < 0) | |
| { | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static PyModuleDef_Slot hashlib_slots[] = { | |
| {Py_mod_exec, hashlib_init_hashtable}, | |
| {Py_mod_exec, hashlib_init_HASH_type}, | |
| {Py_mod_exec, hashlib_init_HASHXOF_type}, | |
| {Py_mod_exec, hashlib_init_hmactype}, | |
| {Py_mod_exec, hashlib_md_meth_names}, | |
| {Py_mod_exec, hashlib_init_constructors}, | |
| {Py_mod_exec, hashlib_exception}, | |
| {Py_mod_exec, hashlib_constants}, | |
| {Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| static struct PyModuleDef _hashlibmodule = { | |
| PyModuleDef_HEAD_INIT, | |
| .m_name = "_hashlib", | |
| .m_doc = "OpenSSL interface for hashlib module", | |
| .m_size = sizeof(_hashlibstate), | |
| .m_methods = EVP_functions, | |
| .m_slots = hashlib_slots, | |
| .m_traverse = hashlib_traverse, | |
| .m_clear = hashlib_clear, | |
| .m_free = hashlib_free | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit__hashlib(void) | |
| { | |
| return PyModuleDef_Init(&_hashlibmodule); | |
| } | |
| /* | |
| ** Routines to represent binary data in ASCII and vice-versa | |
| ** | |
| ** This module currently supports the following encodings: | |
| ** uuencode: | |
| ** each line encodes 45 bytes (except possibly the last) | |
| ** First char encodes (binary) length, rest data | |
| ** each char encodes 6 bits, as follows: | |
| ** binary: 01234567 abcdefgh ijklmnop | |
| ** ascii: 012345 67abcd efghij klmnop | |
| ** ASCII encoding method is "excess-space": 000000 is encoded as ' ', etc. | |
| ** short binary data is zero-extended (so the bits are always in the | |
| ** right place), this does *not* reflect in the length. | |
| ** base64: | |
| ** Line breaks are insignificant, but lines are at most 76 chars | |
| ** each char encodes 6 bits, in similar order as uucode/hqx. Encoding | |
| ** is done via a table. | |
| ** Short binary data is filled (in ASCII) with '='. | |
| ** hqx: | |
| ** File starts with introductory text, real data starts and ends | |
| ** with colons. | |
| ** Data consists of three similar parts: info, datafork, resourcefork. | |
| ** Each part is protected (at the end) with a 16-bit crc | |
| ** The binary data is run-length encoded, and then ascii-fied: | |
| ** binary: 01234567 abcdefgh ijklmnop | |
| ** ascii: 012345 67abcd efghij klmnop | |
| ** ASCII encoding is table-driven, see the code. | |
| ** Short binary data results in the runt ascii-byte being output with | |
| ** the bits in the right place. | |
| ** | |
| ** While I was reading dozens of programs that encode or decode the formats | |
| ** here (documentation? hihi:-) I have formulated Jansen's Observation: | |
| ** | |
| ** Programs that encode binary data in ASCII are written in | |
| ** such a style that they are as unreadable as possible. Devices used | |
| ** include unnecessary global variables, burying important tables | |
| ** in unrelated sourcefiles, putting functions in include files, | |
| ** using seemingly-descriptive variable names for different purposes, | |
| ** calls to empty subroutines and a host of others. | |
| ** | |
| ** I have attempted to break with this tradition, but I guess that that | |
| ** does make the performance sub-optimal. Oh well, too bad... | |
| ** | |
| ** Jack Jansen, CWI, July 1995. | |
| ** | |
| ** Added support for quoted-printable encoding, based on rfc 1521 et al | |
| ** quoted-printable encoding specifies that non printable characters (anything | |
| ** below 32 and above 126) be encoded as =XX where XX is the hexadecimal value | |
| ** of the character. It also specifies some other behavior to enable 8bit data | |
| ** in a mail message with little difficulty (maximum line sizes, protecting | |
| ** some cases of whitespace, etc). | |
| ** | |
| ** Brandon Long, September 2001. | |
| */ | |
| #ifndef Py_BUILD_CORE_BUILTIN | |
| # define Py_BUILD_CORE_MODULE 1 | |
| #endif | |
| #include "Python.h" | |
| #include "pycore_long.h" // _PyLong_DigitValue | |
| #include "pycore_strhex.h" // _Py_strhex_bytes_with_sep() | |
| #ifdef USE_ZLIB_CRC32 | |
| # include "zlib.h" | |
| #endif | |
| typedef struct binascii_state { | |
| PyObject *Error; | |
| PyObject *Incomplete; | |
| } binascii_state; | |
| static inline binascii_state * | |
| get_binascii_state(PyObject *module) | |
| { | |
| return (binascii_state *)PyModule_GetState(module); | |
| } | |
| /* Align to 64 bytes for L1 cache line friendliness */ | |
| static const unsigned char table_a2b_base64[] Py_ALIGNED(64) = { | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,62, -1,-1,-1,63, | |
| 52,53,54,55, 56,57,58,59, 60,61,-1,-1, -1,64,-1,-1, /* PAD->64 detected by fast path */ | |
| -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10, 11,12,13,14, | |
| 15,16,17,18, 19,20,21,22, 23,24,25,-1, -1,-1,-1,-1, | |
| -1,26,27,28, 29,30,31,32, 33,34,35,36, 37,38,39,40, | |
| 41,42,43,44, 45,46,47,48, 49,50,51,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, -1,-1,-1,-1, | |
| }; | |
| #define BASE64_PAD '=' | |
| /* Max binary chunk size; limited only by available memory */ | |
| #define BASE64_MAXBIN ((PY_SSIZE_T_MAX - 3) / 2) | |
| /* | |
| * Fast base64 encoding/decoding helpers. | |
| * | |
| * Process complete groups without loop-carried dependencies. | |
| */ | |
| /* Align to 64 bytes for L1 cache line friendliness */ | |
| static const unsigned char table_b2a_base64[] Py_ALIGNED(64) = | |
| "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; | |
| /* Encode 3 bytes into 4 base64 characters. */ | |
| static inline void | |
| base64_encode_trio(const unsigned char *in, unsigned char *out, | |
| const unsigned char *table) | |
| { | |
| unsigned int combined = ((unsigned int)in[0] << 16) | | |
| ((unsigned int)in[1] << 8) | | |
| (unsigned int)in[2]; | |
| out[0] = table[(combined >> 18) & 0x3f]; | |
| out[1] = table[(combined >> 12) & 0x3f]; | |
| out[2] = table[(combined >> 6) & 0x3f]; | |
| out[3] = table[combined & 0x3f]; | |
| } | |
| /* Encode multiple complete 3-byte groups. | |
| * Returns the number of input bytes processed (always a multiple of 3). | |
| */ | |
| static inline Py_ssize_t | |
| base64_encode_fast(const unsigned char *in, Py_ssize_t in_len, | |
| unsigned char *out, const unsigned char *table) | |
| { | |
| Py_ssize_t n_trios = in_len / 3; | |
| const unsigned char *in_end = in + n_trios * 3; | |
| while (in < in_end) { | |
| base64_encode_trio(in, out, table); | |
| in += 3; | |
| out += 4; | |
| } | |
| return n_trios * 3; | |
| } | |
| /* Decode 4 base64 characters into 3 bytes. | |
| * Returns 1 on success, 0 if any character is invalid. | |
| */ | |
| static inline int | |
| base64_decode_quad(const unsigned char *in, unsigned char *out, | |
| const unsigned char *table) | |
| { | |
| unsigned char v0 = table[in[0]]; | |
| unsigned char v1 = table[in[1]]; | |
| unsigned char v2 = table[in[2]]; | |
| unsigned char v3 = table[in[3]]; | |
| if ((v0 | v1 | v2 | v3) & 0xc0) { | |
| return 0; | |
| } | |
| out[0] = (v0 << 2) | (v1 >> 4); | |
| out[1] = (v1 << 4) | (v2 >> 2); | |
| out[2] = (v2 << 6) | v3; | |
| return 1; | |
| } | |
| /* Decode multiple complete 4-character groups (no padding allowed). | |
| * Returns the number of input characters processed. | |
| * Stops at the first invalid character, padding, or incomplete group. | |
| */ | |
| static inline Py_ssize_t | |
| base64_decode_fast(const unsigned char *in, Py_ssize_t in_len, | |
| unsigned char *out, const unsigned char *table) | |
| { | |
| Py_ssize_t n_quads = in_len / 4; | |
| Py_ssize_t i; | |
| for (i = 0; i < n_quads; i++) { | |
| if (!base64_decode_quad(in + i * 4, out + i * 3, table)) { | |
| break; | |
| } | |
| } | |
| return i * 4; | |
| } | |
| static const unsigned short crctab_hqx[256] = { | |
| 0x0000, 0x1021, 0x2042, 0x3063, 0x4084, 0x50a5, 0x60c6, 0x70e7, | |
| 0x8108, 0x9129, 0xa14a, 0xb16b, 0xc18c, 0xd1ad, 0xe1ce, 0xf1ef, | |
| 0x1231, 0x0210, 0x3273, 0x2252, 0x52b5, 0x4294, 0x72f7, 0x62d6, | |
| 0x9339, 0x8318, 0xb37b, 0xa35a, 0xd3bd, 0xc39c, 0xf3ff, 0xe3de, | |
| 0x2462, 0x3443, 0x0420, 0x1401, 0x64e6, 0x74c7, 0x44a4, 0x5485, | |
| 0xa56a, 0xb54b, 0x8528, 0x9509, 0xe5ee, 0xf5cf, 0xc5ac, 0xd58d, | |
| 0x3653, 0x2672, 0x1611, 0x0630, 0x76d7, 0x66f6, 0x5695, 0x46b4, | |
| 0xb75b, 0xa77a, 0x9719, 0x8738, 0xf7df, 0xe7fe, 0xd79d, 0xc7bc, | |
| 0x48c4, 0x58e5, 0x6886, 0x78a7, 0x0840, 0x1861, 0x2802, 0x3823, | |
| 0xc9cc, 0xd9ed, 0xe98e, 0xf9af, 0x8948, 0x9969, 0xa90a, 0xb92b, | |
| 0x5af5, 0x4ad4, 0x7ab7, 0x6a96, 0x1a71, 0x0a50, 0x3a33, 0x2a12, | |
| 0xdbfd, 0xcbdc, 0xfbbf, 0xeb9e, 0x9b79, 0x8b58, 0xbb3b, 0xab1a, | |
| 0x6ca6, 0x7c87, 0x4ce4, 0x5cc5, 0x2c22, 0x3c03, 0x0c60, 0x1c41, | |
| 0xedae, 0xfd8f, 0xcdec, 0xddcd, 0xad2a, 0xbd0b, 0x8d68, 0x9d49, | |
| 0x7e97, 0x6eb6, 0x5ed5, 0x4ef4, 0x3e13, 0x2e32, 0x1e51, 0x0e70, | |
| 0xff9f, 0xefbe, 0xdfdd, 0xcffc, 0xbf1b, 0xaf3a, 0x9f59, 0x8f78, | |
| 0x9188, 0x81a9, 0xb1ca, 0xa1eb, 0xd10c, 0xc12d, 0xf14e, 0xe16f, | |
| 0x1080, 0x00a1, 0x30c2, 0x20e3, 0x5004, 0x4025, 0x7046, 0x6067, | |
| 0x83b9, 0x9398, 0xa3fb, 0xb3da, 0xc33d, 0xd31c, 0xe37f, 0xf35e, | |
| 0x02b1, 0x1290, 0x22f3, 0x32d2, 0x4235, 0x5214, 0x6277, 0x7256, | |
| 0xb5ea, 0xa5cb, 0x95a8, 0x8589, 0xf56e, 0xe54f, 0xd52c, 0xc50d, | |
| 0x34e2, 0x24c3, 0x14a0, 0x0481, 0x7466, 0x6447, 0x5424, 0x4405, | |
| 0xa7db, 0xb7fa, 0x8799, 0x97b8, 0xe75f, 0xf77e, 0xc71d, 0xd73c, | |
| 0x26d3, 0x36f2, 0x0691, 0x16b0, 0x6657, 0x7676, 0x4615, 0x5634, | |
| 0xd94c, 0xc96d, 0xf90e, 0xe92f, 0x99c8, 0x89e9, 0xb98a, 0xa9ab, | |
| 0x5844, 0x4865, 0x7806, 0x6827, 0x18c0, 0x08e1, 0x3882, 0x28a3, | |
| 0xcb7d, 0xdb5c, 0xeb3f, 0xfb1e, 0x8bf9, 0x9bd8, 0xabbb, 0xbb9a, | |
| 0x4a75, 0x5a54, 0x6a37, 0x7a16, 0x0af1, 0x1ad0, 0x2ab3, 0x3a92, | |
| 0xfd2e, 0xed0f, 0xdd6c, 0xcd4d, 0xbdaa, 0xad8b, 0x9de8, 0x8dc9, | |
| 0x7c26, 0x6c07, 0x5c64, 0x4c45, 0x3ca2, 0x2c83, 0x1ce0, 0x0cc1, | |
| 0xef1f, 0xff3e, 0xcf5d, 0xdf7c, 0xaf9b, 0xbfba, 0x8fd9, 0x9ff8, | |
| 0x6e17, 0x7e36, 0x4e55, 0x5e74, 0x2e93, 0x3eb2, 0x0ed1, 0x1ef0, | |
| }; | |
| /*[clinic input] | |
| module binascii | |
| [clinic start generated code]*/ | |
| /*[clinic end generated code: output=da39a3ee5e6b4b0d input=de89fb46bcaf3fec]*/ | |
| /*[python input] | |
| class ascii_buffer_converter(CConverter): | |
| type = 'Py_buffer' | |
| converter = 'ascii_buffer_converter' | |
| impl_by_reference = True | |
| c_default = "{NULL, NULL}" | |
| def cleanup(self): | |
| name = self.name | |
| return "".join(["if (", name, ".obj)\n PyBuffer_Release(&", name, ");\n"]) | |
| [python start generated code]*/ | |
| /*[python end generated code: output=da39a3ee5e6b4b0d input=3eb7b63610da92cd]*/ | |
| static int | |
| ascii_buffer_converter(PyObject *arg, Py_buffer *buf) | |
| { | |
| if (arg == NULL) { | |
| PyBuffer_Release(buf); | |
| return 1; | |
| } | |
| if (PyUnicode_Check(arg)) { | |
| if (!PyUnicode_IS_ASCII(arg)) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "string argument should contain only ASCII characters"); | |
| return 0; | |
| } | |
| assert(PyUnicode_KIND(arg) == PyUnicode_1BYTE_KIND); | |
| buf->buf = (void *) PyUnicode_1BYTE_DATA(arg); | |
| buf->len = PyUnicode_GET_LENGTH(arg); | |
| buf->obj = NULL; | |
| return 1; | |
| } | |
| if (PyObject_GetBuffer(arg, buf, PyBUF_SIMPLE) != 0) { | |
| PyErr_Format(PyExc_TypeError, | |
| "argument should be bytes, buffer or ASCII string, " | |
| "not '%.100s'", Py_TYPE(arg)->tp_name); | |
| return 0; | |
| } | |
| assert(PyBuffer_IsContiguous(buf, 'C')); | |
| return Py_CLEANUP_SUPPORTED; | |
| } | |
| /* The function inserts '\n' each width characters, moving the data right. | |
| * It assumes that we allocated enough space for all of the newlines in data. | |
| * Returns the size of the data including the newlines. | |
| */ | |
| static Py_ssize_t | |
| wraplines(unsigned char *data, Py_ssize_t size, size_t width) | |
| { | |
| if ((size_t)size <= width) { | |
| return size; | |
| } | |
| unsigned char *src = data + size; | |
| Py_ssize_t newlines = (size - 1) / width; | |
| Py_ssize_t line_len = size - newlines * width; | |
| size += newlines; | |
| unsigned char *dst = data + size; | |
| while ((src -= line_len) != data) { | |
| dst -= line_len; | |
| memmove(dst, src, line_len); | |
| *--dst = '\n'; | |
| line_len = width; | |
| } | |
| assert(dst == data + width); | |
| return size; | |
| } | |
| #include "clinic/binascii.c.h" | |
| /*[clinic input] | |
| binascii.a2b_uu | |
| data: ascii_buffer | |
| / | |
| Decode a line of uuencoded data. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_a2b_uu_impl(PyObject *module, Py_buffer *data) | |
| /*[clinic end generated code: output=e027f8e0b0598742 input=7cafeaf73df63d1c]*/ | |
| { | |
| const unsigned char *ascii_data; | |
| int leftbits = 0; | |
| unsigned char this_ch; | |
| unsigned int leftchar = 0; | |
| Py_ssize_t ascii_len, bin_len; | |
| binascii_state *state; | |
| ascii_data = data->buf; | |
| ascii_len = data->len; | |
| assert(ascii_len >= 0); | |
| /* First byte: binary data length (in bytes) */ | |
| bin_len = (*ascii_data++ - ' ') & 077; | |
| ascii_len--; | |
| /* Allocate the buffer */ | |
| PyBytesWriter *writer = PyBytesWriter_Create(bin_len); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| unsigned char *bin_data = PyBytesWriter_GetData(writer); | |
| for( ; bin_len > 0 ; ascii_len--, ascii_data++ ) { | |
| /* XXX is it really best to add NULs if there's no more data */ | |
| this_ch = (ascii_len > 0) ? *ascii_data : 0; | |
| if ( this_ch == '\n' || this_ch == '\r' || ascii_len <= 0) { | |
| /* | |
| ** Whitespace. Assume some spaces got eaten at | |
| ** end-of-line. (We check this later) | |
| */ | |
| this_ch = 0; | |
| } else { | |
| /* Check the character for legality | |
| ** The 64 in stead of the expected 63 is because | |
| ** there are a few uuencodes out there that use | |
| ** '`' as zero instead of space. | |
| */ | |
| if ( this_ch < ' ' || this_ch > (' ' + 64)) { | |
| state = get_binascii_state(module); | |
| if (state == NULL) { | |
| goto error; | |
| } | |
| PyErr_SetString(state->Error, "Illegal char"); | |
| goto error; | |
| } | |
| this_ch = (this_ch - ' ') & 077; | |
| } | |
| /* | |
| ** Shift it in on the low end, and see if there's | |
| ** a byte ready for output. | |
| */ | |
| leftchar = (leftchar << 6) | (this_ch); | |
| leftbits += 6; | |
| if ( leftbits >= 8 ) { | |
| leftbits -= 8; | |
| *bin_data++ = (leftchar >> leftbits) & 0xff; | |
| leftchar &= ((1 << leftbits) - 1); | |
| bin_len--; | |
| } | |
| } | |
| /* | |
| ** Finally, check that if there's anything left on the line | |
| ** that it's whitespace only. | |
| */ | |
| while( ascii_len-- > 0 ) { | |
| this_ch = *ascii_data++; | |
| /* Extra '`' may be written as padding in some cases */ | |
| if ( this_ch != ' ' && this_ch != ' '+64 && | |
| this_ch != '\n' && this_ch != '\r' ) { | |
| state = get_binascii_state(module); | |
| if (state == NULL) { | |
| goto error; | |
| } | |
| PyErr_SetString(state->Error, "Trailing garbage"); | |
| goto error; | |
| } | |
| } | |
| return PyBytesWriter_Finish(writer); | |
| error: | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| binascii.b2a_uu | |
| data: Py_buffer | |
| / | |
| * | |
| backtick: bool = False | |
| Uuencode line of data. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_b2a_uu_impl(PyObject *module, Py_buffer *data, int backtick) | |
| /*[clinic end generated code: output=b1b99de62d9bbeb8 input=beb27822241095cd]*/ | |
| { | |
| const unsigned char *bin_data; | |
| int leftbits = 0; | |
| unsigned char this_ch; | |
| unsigned int leftchar = 0; | |
| binascii_state *state; | |
| Py_ssize_t bin_len; | |
| bin_data = data->buf; | |
| bin_len = data->len; | |
| if ( bin_len > 45 ) { | |
| /* The 45 is a limit that appears in all uuencode's */ | |
| state = get_binascii_state(module); | |
| if (state == NULL) { | |
| return NULL; | |
| } | |
| PyErr_SetString(state->Error, "At most 45 bytes at once"); | |
| return NULL; | |
| } | |
| /* We're lazy and allocate to much (fixed up later) */ | |
| Py_ssize_t out_len = 2 + (bin_len + 2) / 3 * 4; | |
| PyBytesWriter *writer = PyBytesWriter_Create(out_len); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| unsigned char *ascii_data = PyBytesWriter_GetData(writer); | |
| /* Store the length */ | |
| if (backtick && !bin_len) | |
| *ascii_data++ = '`'; | |
| else | |
| *ascii_data++ = ' ' + (unsigned char)bin_len; | |
| for( ; bin_len > 0 || leftbits != 0 ; bin_len--, bin_data++ ) { | |
| /* Shift the data (or padding) into our buffer */ | |
| if ( bin_len > 0 ) /* Data */ | |
| leftchar = (leftchar << 8) | *bin_data; | |
| else /* Padding */ | |
| leftchar <<= 8; | |
| leftbits += 8; | |
| /* See if there are 6-bit groups ready */ | |
| while ( leftbits >= 6 ) { | |
| this_ch = (leftchar >> (leftbits-6)) & 0x3f; | |
| leftbits -= 6; | |
| if (backtick && !this_ch) | |
| *ascii_data++ = '`'; | |
| else | |
| *ascii_data++ = this_ch + ' '; | |
| } | |
| } | |
| *ascii_data++ = '\n'; /* Append a courtesy newline */ | |
| return PyBytesWriter_FinishWithPointer(writer, ascii_data); | |
| } | |
| static int | |
| ignorechar(unsigned char c, Py_buffer *ignorechars) | |
| { | |
| return (ignorechars->buf != NULL && | |
| memchr(ignorechars->buf, c, ignorechars->len)); | |
| } | |
| /*[clinic input] | |
| binascii.a2b_base64 | |
| data: ascii_buffer | |
| / | |
| * | |
| strict_mode: bool(c_default="-1", py_default="<unrepresentable>") = False | |
| When set to true, bytes that are not part of the base64 standard are | |
| not allowed. The same applies to excess data after padding (= / ==). | |
| Set to True by default if ignorechars is specified, False otherwise. | |
| ignorechars: Py_buffer(py_default="<unrepresentable>") = None | |
| A byte string containing characters to ignore from the input when | |
| strict_mode is true. | |
| Decode a line of base64 data. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_a2b_base64_impl(PyObject *module, Py_buffer *data, int strict_mode, | |
| Py_buffer *ignorechars) | |
| /*[clinic end generated code: output=eab37aea4cfa6daa input=3be4937d72943835]*/ | |
| { | |
| assert(data->len >= 0); | |
| const unsigned char *ascii_data = data->buf; | |
| size_t ascii_len = data->len; | |
| binascii_state *state = NULL; | |
| if (strict_mode == -1) { | |
| strict_mode = (ignorechars->buf != NULL); | |
| } | |
| /* Allocate the buffer */ | |
| Py_ssize_t bin_len = ((ascii_len+3)/4)*3; /* Upper bound, corrected later */ | |
| PyBytesWriter *writer = PyBytesWriter_Create(bin_len); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| unsigned char *bin_data = PyBytesWriter_GetData(writer); | |
| size_t i = 0; /* Current position in input */ | |
| /* Fast path: use optimized decoder for complete quads. | |
| * This works for both strict and non-strict mode for valid input. | |
| * The fast path stops at padding, invalid chars, or incomplete groups. | |
| */ | |
| if (ascii_len >= 4) { | |
| Py_ssize_t fast_chars = base64_decode_fast(ascii_data, (Py_ssize_t)ascii_len, | |
| bin_data, table_a2b_base64); | |
| if (fast_chars > 0) { | |
| i = (size_t)fast_chars; | |
| bin_data += (fast_chars / 4) * 3; | |
| } | |
| } | |
| /* Slow path: handle remaining input (padding, invalid chars, partial groups) */ | |
| int quad_pos = 0; | |
| unsigned char leftchar = 0; | |
| int pads = 0; | |
| for (; i < ascii_len; i++) { | |
| unsigned char this_ch = ascii_data[i]; | |
| /* Check for pad sequences and ignore | |
| ** the invalid ones. | |
| */ | |
| if (this_ch == BASE64_PAD) { | |
| pads++; | |
| if (strict_mode) { | |
| if (quad_pos == 0) { | |
| state = get_binascii_state(module); | |
| if (state) { | |
| PyErr_SetString(state->Error, (i == 0) | |
| ? "Leading padding not allowed" | |
| : "Excess padding not allowed"); | |
| } | |
| goto error_end; | |
| } | |
| if (quad_pos == 1) { | |
| /* Set an error below. */ | |
| break; | |
| } | |
| if (quad_pos + pads > 4) { | |
| state = get_binascii_state(module); | |
| if (state) { | |
| PyErr_SetString(state->Error, "Excess padding not allowed"); | |
| } | |
| goto error_end; | |
| } | |
| } | |
| else { | |
| if (quad_pos >= 2 && quad_pos + pads >= 4) { | |
| /* A pad sequence means we should not parse more input. | |
| ** We've already interpreted the data from the quad at this point. | |
| */ | |
| goto done; | |
| } | |
| } | |
| continue; | |
| } | |
| unsigned char v = table_a2b_base64[this_ch]; | |
| if (v >= 64) { | |
| if (strict_mode && !ignorechar(this_ch, ignorechars)) { | |
| state = get_binascii_state(module); | |
| if (state) { | |
| PyErr_SetString(state->Error, "Only base64 data is allowed"); | |
| } | |
| goto error_end; | |
| } | |
| continue; | |
| } | |
| // Characters that are not '=', in the middle of the padding, are not allowed | |
| if (strict_mode && pads) { | |
| state = get_binascii_state(module); | |
| if (state) { | |
| PyErr_SetString(state->Error, (quad_pos + pads == 4) | |
| ? "Excess data after padding" | |
| : "Discontinuous padding not allowed"); | |
| } | |
| goto error_end; | |
| } | |
| pads = 0; | |
| switch (quad_pos) { | |
| case 0: | |
| quad_pos = 1; | |
| leftchar = v; | |
| break; | |
| case 1: | |
| quad_pos = 2; | |
| *bin_data++ = (leftchar << 2) | (v >> 4); | |
| leftchar = v & 0x0f; | |
| break; | |
| case 2: | |
| quad_pos = 3; | |
| *bin_data++ = (leftchar << 4) | (v >> 2); | |
| leftchar = v & 0x03; | |
| break; | |
| case 3: | |
| quad_pos = 0; | |
| *bin_data++ = (leftchar << 6) | (v); | |
| leftchar = 0; | |
| break; | |
| } | |
| } | |
| if (quad_pos == 1) { | |
| /* There is exactly one extra valid, non-padding, base64 character. | |
| ** This is an invalid length, as there is no possible input that | |
| ** could encoded into such a base64 string. | |
| */ | |
| state = get_binascii_state(module); | |
| if (state) { | |
| unsigned char *bin_data_start = PyBytesWriter_GetData(writer); | |
| PyErr_Format(state->Error, | |
| "Invalid base64-encoded string: " | |
| "number of data characters (%zd) cannot be 1 more " | |
| "than a multiple of 4", | |
| (bin_data - bin_data_start) / 3 * 4 + 1); | |
| } | |
| goto error_end; | |
| } | |
| if (quad_pos != 0 && quad_pos + pads != 4) { | |
| state = get_binascii_state(module); | |
| if (state) { | |
| PyErr_SetString(state->Error, "Incorrect padding"); | |
| } | |
| goto error_end; | |
| } | |
| done: | |
| return PyBytesWriter_FinishWithPointer(writer, bin_data); | |
| error_end: | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| binascii.b2a_base64 | |
| data: Py_buffer | |
| / | |
| * | |
| wrapcol: size_t = 0 | |
| newline: bool = True | |
| Base64-code line of data. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_b2a_base64_impl(PyObject *module, Py_buffer *data, size_t wrapcol, | |
| int newline) | |
| /*[clinic end generated code: output=2edc7311a9515eac input=2ee4214e6d489e2e]*/ | |
| { | |
| const unsigned char *bin_data = data->buf; | |
| Py_ssize_t bin_len = data->len; | |
| assert(bin_len >= 0); | |
| /* Each group of 3 bytes (rounded up) gets encoded as 4 characters, | |
| * not counting newlines. | |
| * Note that 'b' gets encoded as 'Yg==' (1 in, 4 out). | |
| * | |
| * Use unsigned integer arithmetic to avoid signed integer overflow. | |
| */ | |
| size_t out_len = ((size_t)bin_len + 2u) / 3u * 4u; | |
| if (out_len > PY_SSIZE_T_MAX) { | |
| goto toolong; | |
| } | |
| if (wrapcol && out_len) { | |
| /* Each line should encode a whole number of bytes. */ | |
| wrapcol = wrapcol < 4 ? 4 : wrapcol / 4 * 4; | |
| out_len += (out_len - 1u) / wrapcol; | |
| if (out_len > PY_SSIZE_T_MAX) { | |
| goto toolong; | |
| } | |
| } | |
| if (newline) { | |
| out_len++; | |
| if (out_len > PY_SSIZE_T_MAX) { | |
| goto toolong; | |
| } | |
| } | |
| PyBytesWriter *writer = PyBytesWriter_Create(out_len); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| unsigned char *ascii_data = PyBytesWriter_GetData(writer); | |
| /* Use the optimized fast path for complete 3-byte groups */ | |
| Py_ssize_t fast_bytes = base64_encode_fast(bin_data, bin_len, ascii_data, | |
| table_b2a_base64); | |
| bin_data += fast_bytes; | |
| ascii_data += (fast_bytes / 3) * 4; | |
| bin_len -= fast_bytes; | |
| /* Handle remaining 0-2 bytes */ | |
| if (bin_len == 1) { | |
| /* 1 byte remaining: produces 2 base64 chars + 2 padding */ | |
| unsigned int val = bin_data[0]; | |
| *ascii_data++ = table_b2a_base64[(val >> 2) & 0x3f]; | |
| *ascii_data++ = table_b2a_base64[(val << 4) & 0x3f]; | |
| *ascii_data++ = BASE64_PAD; | |
| *ascii_data++ = BASE64_PAD; | |
| } | |
| else if (bin_len == 2) { | |
| /* 2 bytes remaining: produces 3 base64 chars + 1 padding */ | |
| unsigned int val = ((unsigned int)bin_data[0] << 8) | bin_data[1]; | |
| *ascii_data++ = table_b2a_base64[(val >> 10) & 0x3f]; | |
| *ascii_data++ = table_b2a_base64[(val >> 4) & 0x3f]; | |
| *ascii_data++ = table_b2a_base64[(val << 2) & 0x3f]; | |
| *ascii_data++ = BASE64_PAD; | |
| } | |
| if (wrapcol) { | |
| unsigned char *start = PyBytesWriter_GetData(writer); | |
| ascii_data = start + wraplines(start, ascii_data - start, wrapcol); | |
| } | |
| if (newline) | |
| *ascii_data++ = '\n'; /* Append a courtesy newline */ | |
| return PyBytesWriter_FinishWithPointer(writer, ascii_data); | |
| toolong:; | |
| binascii_state *state = get_binascii_state(module); | |
| if (state == NULL) { | |
| return NULL; | |
| } | |
| PyErr_SetString(state->Error, "Too much data for base64"); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| binascii.crc_hqx | |
| data: Py_buffer | |
| crc: unsigned_int(bitwise=True) | |
| / | |
| Compute CRC-CCITT incrementally. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_crc_hqx_impl(PyObject *module, Py_buffer *data, unsigned int crc) | |
| /*[clinic end generated code: output=2fde213d0f547a98 input=56237755370a951c]*/ | |
| { | |
| const unsigned char *bin_data; | |
| Py_ssize_t len; | |
| crc &= 0xffff; | |
| bin_data = data->buf; | |
| len = data->len; | |
| while(len-- > 0) { | |
| crc = ((crc<<8)&0xff00) ^ crctab_hqx[(crc>>8)^*bin_data++]; | |
| } | |
| return PyLong_FromUnsignedLong(crc); | |
| } | |
| #ifndef USE_ZLIB_CRC32 | |
| /* Crc - 32 BIT ANSI X3.66 CRC checksum files | |
| Also known as: ISO 3307 | |
| **********************************************************************| | |
| * *| | |
| * Demonstration program to compute the 32-bit CRC used as the frame *| | |
| * check sequence in ADCCP (ANSI X3.66, also known as FIPS PUB 71 *| | |
| * and FED-STD-1003, the U.S. versions of CCITT's X.25 link-level *| | |
| * protocol). The 32-bit FCS was added via the Federal Register, *| | |
| * 1 June 1982, p.23798. I presume but don't know for certain that *| | |
| * this polynomial is or will be included in CCITT V.41, which *| | |
| * defines the 16-bit CRC (often called CRC-CCITT) polynomial. FIPS *| | |
| * PUB 78 says that the 32-bit FCS reduces otherwise undetected *| | |
| * errors by a factor of 10^-5 over 16-bit FCS. *| | |
| * *| | |
| **********************************************************************| | |
| Copyright (C) 1986 Gary S. Brown. You may use this program, or | |
| code or tables extracted from it, as desired without restriction. | |
| First, the polynomial itself and its table of feedback terms. The | |
| polynomial is | |
| X^32+X^26+X^23+X^22+X^16+X^12+X^11+X^10+X^8+X^7+X^5+X^4+X^2+X^1+X^0 | |
| Note that we take it "backwards" and put the highest-order term in | |
| the lowest-order bit. The X^32 term is "implied"; the LSB is the | |
| X^31 term, etc. The X^0 term (usually shown as "+1") results in | |
| the MSB being 1. | |
| Note that the usual hardware shift register implementation, which | |
| is what we're using (we're merely optimizing it by doing eight-bit | |
| chunks at a time) shifts bits into the lowest-order term. In our | |
| implementation, that means shifting towards the right. Why do we | |
| do it this way? Because the calculated CRC must be transmitted in | |
| order from highest-order term to lowest-order term. UARTs transmit | |
| characters in order from LSB to MSB. By storing the CRC this way, | |
| we hand it to the UART in the order low-byte to high-byte; the UART | |
| sends each low-bit to hight-bit; and the result is transmission bit | |
| by bit from highest- to lowest-order term without requiring any bit | |
| shuffling on our part. Reception works similarly. | |
| The feedback terms table consists of 256, 32-bit entries. Notes: | |
| 1. The table can be generated at runtime if desired; code to do so | |
| is shown later. It might not be obvious, but the feedback | |
| terms simply represent the results of eight shift/xor opera- | |
| tions for all combinations of data and CRC register values. | |
| 2. The CRC accumulation logic is the same for all CRC polynomials, | |
| be they sixteen or thirty-two bits wide. You simply choose the | |
| appropriate table. Alternatively, because the table can be | |
| generated at runtime, you can start by generating the table for | |
| the polynomial in question and use exactly the same "updcrc", | |
| if your application needn't simultaneously handle two CRC | |
| polynomials. (Note, however, that XMODEM is strange.) | |
| 3. For 16-bit CRCs, the table entries need be only 16 bits wide; | |
| of course, 32-bit entries work OK if the high 16 bits are zero. | |
| 4. The values must be right-shifted by eight bits by the "updcrc" | |
| logic; the shift must be unsigned (bring in zeroes). On some | |
| hardware you could probably optimize the shift in assembler by | |
| using byte-swap instructions. | |
| ********************************************************************/ | |
| static const unsigned int crc_32_tab[256] = { | |
| 0x00000000U, 0x77073096U, 0xee0e612cU, 0x990951baU, 0x076dc419U, | |
| 0x706af48fU, 0xe963a535U, 0x9e6495a3U, 0x0edb8832U, 0x79dcb8a4U, | |
| 0xe0d5e91eU, 0x97d2d988U, 0x09b64c2bU, 0x7eb17cbdU, 0xe7b82d07U, | |
| 0x90bf1d91U, 0x1db71064U, 0x6ab020f2U, 0xf3b97148U, 0x84be41deU, | |
| 0x1adad47dU, 0x6ddde4ebU, 0xf4d4b551U, 0x83d385c7U, 0x136c9856U, | |
| 0x646ba8c0U, 0xfd62f97aU, 0x8a65c9ecU, 0x14015c4fU, 0x63066cd9U, | |
| 0xfa0f3d63U, 0x8d080df5U, 0x3b6e20c8U, 0x4c69105eU, 0xd56041e4U, | |
| 0xa2677172U, 0x3c03e4d1U, 0x4b04d447U, 0xd20d85fdU, 0xa50ab56bU, | |
| 0x35b5a8faU, 0x42b2986cU, 0xdbbbc9d6U, 0xacbcf940U, 0x32d86ce3U, | |
| 0x45df5c75U, 0xdcd60dcfU, 0xabd13d59U, 0x26d930acU, 0x51de003aU, | |
| 0xc8d75180U, 0xbfd06116U, 0x21b4f4b5U, 0x56b3c423U, 0xcfba9599U, | |
| 0xb8bda50fU, 0x2802b89eU, 0x5f058808U, 0xc60cd9b2U, 0xb10be924U, | |
| 0x2f6f7c87U, 0x58684c11U, 0xc1611dabU, 0xb6662d3dU, 0x76dc4190U, | |
| 0x01db7106U, 0x98d220bcU, 0xefd5102aU, 0x71b18589U, 0x06b6b51fU, | |
| 0x9fbfe4a5U, 0xe8b8d433U, 0x7807c9a2U, 0x0f00f934U, 0x9609a88eU, | |
| 0xe10e9818U, 0x7f6a0dbbU, 0x086d3d2dU, 0x91646c97U, 0xe6635c01U, | |
| 0x6b6b51f4U, 0x1c6c6162U, 0x856530d8U, 0xf262004eU, 0x6c0695edU, | |
| 0x1b01a57bU, 0x8208f4c1U, 0xf50fc457U, 0x65b0d9c6U, 0x12b7e950U, | |
| 0x8bbeb8eaU, 0xfcb9887cU, 0x62dd1ddfU, 0x15da2d49U, 0x8cd37cf3U, | |
| 0xfbd44c65U, 0x4db26158U, 0x3ab551ceU, 0xa3bc0074U, 0xd4bb30e2U, | |
| 0x4adfa541U, 0x3dd895d7U, 0xa4d1c46dU, 0xd3d6f4fbU, 0x4369e96aU, | |
| 0x346ed9fcU, 0xad678846U, 0xda60b8d0U, 0x44042d73U, 0x33031de5U, | |
| 0xaa0a4c5fU, 0xdd0d7cc9U, 0x5005713cU, 0x270241aaU, 0xbe0b1010U, | |
| 0xc90c2086U, 0x5768b525U, 0x206f85b3U, 0xb966d409U, 0xce61e49fU, | |
| 0x5edef90eU, 0x29d9c998U, 0xb0d09822U, 0xc7d7a8b4U, 0x59b33d17U, | |
| 0x2eb40d81U, 0xb7bd5c3bU, 0xc0ba6cadU, 0xedb88320U, 0x9abfb3b6U, | |
| 0x03b6e20cU, 0x74b1d29aU, 0xead54739U, 0x9dd277afU, 0x04db2615U, | |
| 0x73dc1683U, 0xe3630b12U, 0x94643b84U, 0x0d6d6a3eU, 0x7a6a5aa8U, | |
| 0xe40ecf0bU, 0x9309ff9dU, 0x0a00ae27U, 0x7d079eb1U, 0xf00f9344U, | |
| 0x8708a3d2U, 0x1e01f268U, 0x6906c2feU, 0xf762575dU, 0x806567cbU, | |
| 0x196c3671U, 0x6e6b06e7U, 0xfed41b76U, 0x89d32be0U, 0x10da7a5aU, | |
| 0x67dd4accU, 0xf9b9df6fU, 0x8ebeeff9U, 0x17b7be43U, 0x60b08ed5U, | |
| 0xd6d6a3e8U, 0xa1d1937eU, 0x38d8c2c4U, 0x4fdff252U, 0xd1bb67f1U, | |
| 0xa6bc5767U, 0x3fb506ddU, 0x48b2364bU, 0xd80d2bdaU, 0xaf0a1b4cU, | |
| 0x36034af6U, 0x41047a60U, 0xdf60efc3U, 0xa867df55U, 0x316e8eefU, | |
| 0x4669be79U, 0xcb61b38cU, 0xbc66831aU, 0x256fd2a0U, 0x5268e236U, | |
| 0xcc0c7795U, 0xbb0b4703U, 0x220216b9U, 0x5505262fU, 0xc5ba3bbeU, | |
| 0xb2bd0b28U, 0x2bb45a92U, 0x5cb36a04U, 0xc2d7ffa7U, 0xb5d0cf31U, | |
| 0x2cd99e8bU, 0x5bdeae1dU, 0x9b64c2b0U, 0xec63f226U, 0x756aa39cU, | |
| 0x026d930aU, 0x9c0906a9U, 0xeb0e363fU, 0x72076785U, 0x05005713U, | |
| 0x95bf4a82U, 0xe2b87a14U, 0x7bb12baeU, 0x0cb61b38U, 0x92d28e9bU, | |
| 0xe5d5be0dU, 0x7cdcefb7U, 0x0bdbdf21U, 0x86d3d2d4U, 0xf1d4e242U, | |
| 0x68ddb3f8U, 0x1fda836eU, 0x81be16cdU, 0xf6b9265bU, 0x6fb077e1U, | |
| 0x18b74777U, 0x88085ae6U, 0xff0f6a70U, 0x66063bcaU, 0x11010b5cU, | |
| 0x8f659effU, 0xf862ae69U, 0x616bffd3U, 0x166ccf45U, 0xa00ae278U, | |
| 0xd70dd2eeU, 0x4e048354U, 0x3903b3c2U, 0xa7672661U, 0xd06016f7U, | |
| 0x4969474dU, 0x3e6e77dbU, 0xaed16a4aU, 0xd9d65adcU, 0x40df0b66U, | |
| 0x37d83bf0U, 0xa9bcae53U, 0xdebb9ec5U, 0x47b2cf7fU, 0x30b5ffe9U, | |
| 0xbdbdf21cU, 0xcabac28aU, 0x53b39330U, 0x24b4a3a6U, 0xbad03605U, | |
| 0xcdd70693U, 0x54de5729U, 0x23d967bfU, 0xb3667a2eU, 0xc4614ab8U, | |
| 0x5d681b02U, 0x2a6f2b94U, 0xb40bbe37U, 0xc30c8ea1U, 0x5a05df1bU, | |
| 0x2d02ef8dU | |
| }; | |
| static unsigned int | |
| internal_crc32(const unsigned char *bin_data, Py_ssize_t len, unsigned int crc) | |
| { /* By Jim Ahlstrom; All rights transferred to CNRI */ | |
| unsigned int result; | |
| crc = ~ crc; | |
| while (len-- > 0) { | |
| crc = crc_32_tab[(crc ^ *bin_data++) & 0xff] ^ (crc >> 8); | |
| /* Note: (crc >> 8) MUST zero fill on left */ | |
| } | |
| result = (crc ^ 0xFFFFFFFF); | |
| return result & 0xffffffff; | |
| } | |
| #endif /* USE_ZLIB_CRC32 */ | |
| /*[clinic input] | |
| binascii.crc32 -> unsigned_int | |
| data: Py_buffer | |
| crc: unsigned_int(bitwise=True) = 0 | |
| / | |
| Compute CRC-32 incrementally. | |
| [clinic start generated code]*/ | |
| static unsigned int | |
| binascii_crc32_impl(PyObject *module, Py_buffer *data, unsigned int crc) | |
| /*[clinic end generated code: output=52cf59056a78593b input=bbe340bc99d25aa8]*/ | |
| #ifdef USE_ZLIB_CRC32 | |
| /* This is the same as zlibmodule.c zlib_crc32_impl. It exists in two | |
| * modules for historical reasons. */ | |
| { | |
| /* Releasing the GIL for very small buffers is inefficient | |
| and may lower performance */ | |
| if (data->len > 1024*5) { | |
| unsigned char *buf = data->buf; | |
| Py_ssize_t len = data->len; | |
| Py_BEGIN_ALLOW_THREADS | |
| /* Avoid truncation of length for very large buffers. crc32() takes | |
| length as an unsigned int, which may be narrower than Py_ssize_t. | |
| We further limit size due to bugs in Apple's macOS zlib. | |
| See https://github.com/python/cpython/issues/105967 | |
| */ | |
| #define ZLIB_CRC_CHUNK_SIZE 0x40000000 | |
| #if ZLIB_CRC_CHUNK_SIZE > INT_MAX | |
| # error "unsupported less than 32-bit platform?" | |
| #endif | |
| while ((size_t)len > ZLIB_CRC_CHUNK_SIZE) { | |
| crc = crc32(crc, buf, ZLIB_CRC_CHUNK_SIZE); | |
| buf += (size_t) ZLIB_CRC_CHUNK_SIZE; | |
| len -= (size_t) ZLIB_CRC_CHUNK_SIZE; | |
| } | |
| #undef ZLIB_CRC_CHUNK_SIZE | |
| crc = crc32(crc, buf, (unsigned int)len); | |
| Py_END_ALLOW_THREADS | |
| } else { | |
| crc = crc32(crc, data->buf, (unsigned int)data->len); | |
| } | |
| return crc & 0xffffffff; | |
| } | |
| #else /* USE_ZLIB_CRC32 */ | |
| { | |
| const unsigned char *bin_data = data->buf; | |
| Py_ssize_t len = data->len; | |
| /* Releasing the GIL for very small buffers is inefficient | |
| and may lower performance */ | |
| if (len > 1024*5) { | |
| unsigned int result; | |
| Py_BEGIN_ALLOW_THREADS | |
| result = internal_crc32(bin_data, len, crc); | |
| Py_END_ALLOW_THREADS | |
| return result; | |
| } else { | |
| return internal_crc32(bin_data, len, crc); | |
| } | |
| } | |
| #endif /* USE_ZLIB_CRC32 */ | |
| /*[clinic input] | |
| binascii.b2a_hex | |
| data: Py_buffer | |
| sep: object = NULL | |
| An optional single character or byte to separate hex bytes. | |
| bytes_per_sep: int = 1 | |
| How many bytes between separators. Positive values count from the | |
| right, negative values count from the left. | |
| Hexadecimal representation of binary data. | |
| The return value is a bytes object. This function is also | |
| available as "hexlify()". | |
| Example: | |
| binascii.b2a_hex(b'\xb9\x01\xef') | |
| b'b901ef' | |
| binascii.hexlify(b'\xb9\x01\xef', ':') | |
| b'b9:01:ef' | |
| binascii.b2a_hex(b'\xb9\x01\xef', b'_', 2) | |
| b'b9_01ef' | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_b2a_hex_impl(PyObject *module, Py_buffer *data, PyObject *sep, | |
| int bytes_per_sep) | |
| /*[clinic end generated code: output=a26937946a81d2c7 input=ec0ade6ba2e43543]*/ | |
| { | |
| return _Py_strhex_bytes_with_sep((const char *)data->buf, data->len, | |
| sep, bytes_per_sep); | |
| } | |
| /*[clinic input] | |
| binascii.hexlify = binascii.b2a_hex | |
| Hexadecimal representation of binary data. | |
| The return value is a bytes object. This function is also | |
| available as "b2a_hex()". | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_hexlify_impl(PyObject *module, Py_buffer *data, PyObject *sep, | |
| int bytes_per_sep) | |
| /*[clinic end generated code: output=d12aa1b001b15199 input=bc317bd4e241f76b]*/ | |
| { | |
| return _Py_strhex_bytes_with_sep((const char *)data->buf, data->len, | |
| sep, bytes_per_sep); | |
| } | |
| /*[clinic input] | |
| binascii.a2b_hex | |
| hexstr: ascii_buffer | |
| / | |
| Binary data of hexadecimal representation. | |
| hexstr must contain an even number of hex digits (upper or lower case). | |
| This function is also available as "unhexlify()". | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_a2b_hex_impl(PyObject *module, Py_buffer *hexstr) | |
| /*[clinic end generated code: output=0cc1a139af0eeecb input=9e1e7f2f94db24fd]*/ | |
| { | |
| const char* argbuf; | |
| Py_ssize_t arglen; | |
| Py_ssize_t i, j; | |
| binascii_state *state; | |
| argbuf = hexstr->buf; | |
| arglen = hexstr->len; | |
| assert(arglen >= 0); | |
| /* XXX What should we do about strings with an odd length? Should | |
| * we add an implicit leading zero, or a trailing zero? For now, | |
| * raise an exception. | |
| */ | |
| if (arglen % 2) { | |
| state = get_binascii_state(module); | |
| if (state == NULL) { | |
| return NULL; | |
| } | |
| PyErr_SetString(state->Error, "Odd-length string"); | |
| return NULL; | |
| } | |
| PyBytesWriter *writer = PyBytesWriter_Create(arglen/2); | |
| if (writer == NULL) { | |
| return NULL; | |
| } | |
| char *retbuf = PyBytesWriter_GetData(writer); | |
| for (i=j=0; i < arglen; i += 2) { | |
| unsigned int top = _PyLong_DigitValue[Py_CHARMASK(argbuf[i])]; | |
| unsigned int bot = _PyLong_DigitValue[Py_CHARMASK(argbuf[i+1])]; | |
| if (top >= 16 || bot >= 16) { | |
| state = get_binascii_state(module); | |
| if (state == NULL) { | |
| goto error; | |
| } | |
| PyErr_SetString(state->Error, | |
| "Non-hexadecimal digit found"); | |
| goto error; | |
| } | |
| retbuf[j++] = (top << 4) + bot; | |
| } | |
| return PyBytesWriter_Finish(writer); | |
| error: | |
| PyBytesWriter_Discard(writer); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| binascii.unhexlify = binascii.a2b_hex | |
| Binary data of hexadecimal representation. | |
| hexstr must contain an even number of hex digits (upper or lower case). | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_unhexlify_impl(PyObject *module, Py_buffer *hexstr) | |
| /*[clinic end generated code: output=51a64c06c79629e3 input=dd8c012725f462da]*/ | |
| { | |
| return binascii_a2b_hex_impl(module, hexstr); | |
| } | |
| #define MAXLINESIZE 76 | |
| /*[clinic input] | |
| binascii.a2b_qp | |
| data: ascii_buffer | |
| header: bool = False | |
| Decode a string of qp-encoded data. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_a2b_qp_impl(PyObject *module, Py_buffer *data, int header) | |
| /*[clinic end generated code: output=e99f7846cfb9bc53 input=bdfb31598d4e47b9]*/ | |
| { | |
| Py_ssize_t in, out; | |
| char ch; | |
| const unsigned char *ascii_data; | |
| unsigned char *odata; | |
| Py_ssize_t datalen = 0; | |
| PyObject *rv; | |
| ascii_data = data->buf; | |
| datalen = data->len; | |
| /* We allocate the output same size as input, this is overkill. | |
| */ | |
| odata = (unsigned char *) PyMem_Calloc(1, datalen); | |
| if (odata == NULL) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| in = out = 0; | |
| while (in < datalen) { | |
| if (ascii_data[in] == '=') { | |
| in++; | |
| if (in >= datalen) break; | |
| /* Soft line breaks */ | |
| if ((ascii_data[in] == '\n') || (ascii_data[in] == '\r')) { | |
| if (ascii_data[in] != '\n') { | |
| while (in < datalen && ascii_data[in] != '\n') in++; | |
| } | |
| if (in < datalen) in++; | |
| } | |
| else if (ascii_data[in] == '=') { | |
| /* broken case from broken python qp */ | |
| odata[out++] = '='; | |
| in++; | |
| } | |
| else if ((in + 1 < datalen) && | |
| ((ascii_data[in] >= 'A' && ascii_data[in] <= 'F') || | |
| (ascii_data[in] >= 'a' && ascii_data[in] <= 'f') || | |
| (ascii_data[in] >= '0' && ascii_data[in] <= '9')) && | |
| ((ascii_data[in+1] >= 'A' && ascii_data[in+1] <= 'F') || | |
| (ascii_data[in+1] >= 'a' && ascii_data[in+1] <= 'f') || | |
| (ascii_data[in+1] >= '0' && ascii_data[in+1] <= '9'))) { | |
| /* hexval */ | |
| ch = _PyLong_DigitValue[ascii_data[in]] << 4; | |
| in++; | |
| ch |= _PyLong_DigitValue[ascii_data[in]]; | |
| in++; | |
| odata[out++] = ch; | |
| } | |
| else { | |
| odata[out++] = '='; | |
| } | |
| } | |
| else if (header && ascii_data[in] == '_') { | |
| odata[out++] = ' '; | |
| in++; | |
| } | |
| else { | |
| odata[out] = ascii_data[in]; | |
| in++; | |
| out++; | |
| } | |
| } | |
| rv = PyBytes_FromStringAndSize((char *)odata, out); | |
| PyMem_Free(odata); | |
| return rv; | |
| } | |
| static int | |
| to_hex (unsigned char ch, unsigned char *s) | |
| { | |
| unsigned int uvalue = ch; | |
| s[1] = "0123456789ABCDEF"[uvalue % 16]; | |
| uvalue = (uvalue / 16); | |
| s[0] = "0123456789ABCDEF"[uvalue % 16]; | |
| return 0; | |
| } | |
| /* XXX: This is ridiculously complicated to be backward compatible | |
| * (mostly) with the quopri module. It doesn't re-create the quopri | |
| * module bug where text ending in CRLF has the CR encoded */ | |
| /*[clinic input] | |
| binascii.b2a_qp | |
| data: Py_buffer | |
| quotetabs: bool = False | |
| istext: bool = True | |
| header: bool = False | |
| Encode a string using quoted-printable encoding. | |
| On encoding, when istext is set, newlines are not encoded, and white | |
| space at end of lines is. When istext is not set, \r and \n (CR/LF) | |
| are both encoded. When quotetabs is set, space and tabs are encoded. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| binascii_b2a_qp_impl(PyObject *module, Py_buffer *data, int quotetabs, | |
| int istext, int header) | |
| /*[clinic end generated code: output=e9884472ebb1a94c input=e9102879afb0defd]*/ | |
| { | |
| Py_ssize_t in, out; | |
| const unsigned char *databuf; | |
| unsigned char *odata; | |
| Py_ssize_t datalen = 0, odatalen = 0; | |
| PyObject *rv; | |
| unsigned int linelen = 0; | |
| unsigned char ch; | |
| int crlf = 0; | |
| const unsigned char *p; | |
| databuf = data->buf; | |
| datalen = data->len; | |
| /* See if this string is using CRLF line ends */ | |
| /* XXX: this function has the side effect of converting all of | |
| * the end of lines to be the same depending on this detection | |
| * here */ | |
| p = (const unsigned char *) memchr(databuf, '\n', datalen); | |
| if ((p != NULL) && (p > databuf) && (*(p-1) == '\r')) | |
| crlf = 1; | |
| /* First, scan to see how many characters need to be encoded */ | |
| in = 0; | |
| while (in < datalen) { | |
| Py_ssize_t delta = 0; | |
| if ((databuf[in] > 126) || | |
| (databuf[in] == '=') || | |
| (header && databuf[in] == '_') || | |
| ((databuf[in] == '.') && (linelen == 0) && | |
| (in + 1 == datalen || databuf[in+1] == '\n' || | |
| databuf[in+1] == '\r' || databuf[in+1] == 0)) || | |
| (!istext && ((databuf[in] == '\r') || (databuf[in] == '\n'))) || | |
| ((databuf[in] == '\t' || databuf[in] == ' ') && (in + 1 == datalen)) || | |
| ((databuf[in] < 33) && | |
| (databuf[in] != '\r') && (databuf[in] != '\n') && | |
| (quotetabs || ((databuf[in] != '\t') && (databuf[in] != ' '))))) | |
| { | |
| if ((linelen + 3) >= MAXLINESIZE) { | |
| linelen = 0; | |
| if (crlf) | |
| delta += 3; | |
| else | |
| delta += 2; | |
| } | |
| linelen += 3; | |
| delta += 3; | |
| in++; | |
| } | |
| else { | |
| if (istext && | |
| ((databuf[in] == '\n') || | |
| ((in+1 < datalen) && (databuf[in] == '\r') && | |
| (databuf[in+1] == '\n')))) | |
| { | |
| linelen = 0; | |
| /* Protect against whitespace on end of line */ | |
| if (in && ((databuf[in-1] == ' ') || (databuf[in-1] == '\t'))) | |
| delta += 2; | |
| if (crlf) | |
| delta += 2; | |
| else | |
| delta += 1; | |
| if (databuf[in] == '\r') | |
| in += 2; | |
| else | |
| in++; | |
| } | |
| else { | |
| if ((in + 1 != datalen) && | |
| (databuf[in+1] != '\n') && | |
| (linelen + 1) >= MAXLINESIZE) { | |
| linelen = 0; | |
| if (crlf) | |
| delta += 3; | |
| else | |
| delta += 2; | |
| } | |
| linelen++; | |
| delta++; | |
| in++; | |
| } | |
| } | |
| if (PY_SSIZE_T_MAX - delta < odatalen) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| odatalen += delta; | |
| } | |
| /* We allocate the output same size as input, this is overkill. | |
| */ | |
| odata = (unsigned char *) PyMem_Calloc(1, odatalen); | |
| if (odata == NULL) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| in = out = linelen = 0; | |
| while (in < datalen) { | |
| if ((databuf[in] > 126) || | |
| (databuf[in] == '=') || | |
| (header && databuf[in] == '_') || | |
| ((databuf[in] == '.') && (linelen == 0) && | |
| (in + 1 == datalen || databuf[in+1] == '\n' || | |
| databuf[in+1] == '\r' || databuf[in+1] == 0)) || | |
| (!istext && ((databuf[in] == '\r') || (databuf[in] == '\n'))) || | |
| ((databuf[in] == '\t' || databuf[in] == ' ') && (in + 1 == datalen)) || | |
| ((databuf[in] < 33) && | |
| (databuf[in] != '\r') && (databuf[in] != '\n') && | |
| (quotetabs || ((databuf[in] != '\t') && (databuf[in] != ' '))))) | |
| { | |
| if ((linelen + 3 )>= MAXLINESIZE) { | |
| odata[out++] = '='; | |
| if (crlf) odata[out++] = '\r'; | |
| odata[out++] = '\n'; | |
| linelen = 0; | |
| } | |
| odata[out++] = '='; | |
| to_hex(databuf[in], &odata[out]); | |
| out += 2; | |
| in++; | |
| linelen += 3; | |
| } | |
| else { | |
| if (istext && | |
| ((databuf[in] == '\n') || | |
| ((in+1 < datalen) && (databuf[in] == '\r') && | |
| (databuf[in+1] == '\n')))) | |
| { | |
| linelen = 0; | |
| /* Protect against whitespace on end of line */ | |
| if (out && ((odata[out-1] == ' ') || (odata[out-1] == '\t'))) { | |
| ch = odata[out-1]; | |
| odata[out-1] = '='; | |
| to_hex(ch, &odata[out]); | |
| out += 2; | |
| } | |
| if (crlf) odata[out++] = '\r'; | |
| odata[out++] = '\n'; | |
| if (databuf[in] == '\r') | |
| in += 2; | |
| else | |
| in++; | |
| } | |
| else { | |
| if ((in + 1 != datalen) && | |
| (databuf[in+1] != '\n') && | |
| (linelen + 1) >= MAXLINESIZE) { | |
| odata[out++] = '='; | |
| if (crlf) odata[out++] = '\r'; | |
| odata[out++] = '\n'; | |
| linelen = 0; | |
| } | |
| linelen++; | |
| if (header && databuf[in] == ' ') { | |
| odata[out++] = '_'; | |
| in++; | |
| } | |
| else { | |
| odata[out++] = databuf[in++]; | |
| } | |
| } | |
| } | |
| } | |
| rv = PyBytes_FromStringAndSize((char *)odata, out); | |
| PyMem_Free(odata); | |
| return rv; | |
| } | |
| /* List of functions defined in the module */ | |
| static struct PyMethodDef binascii_module_methods[] = { | |
| BINASCII_A2B_UU_METHODDEF | |
| BINASCII_B2A_UU_METHODDEF | |
| BINASCII_A2B_BASE64_METHODDEF | |
| BINASCII_B2A_BASE64_METHODDEF | |
| BINASCII_A2B_HEX_METHODDEF | |
| BINASCII_B2A_HEX_METHODDEF | |
| BINASCII_HEXLIFY_METHODDEF | |
| BINASCII_UNHEXLIFY_METHODDEF | |
| BINASCII_CRC_HQX_METHODDEF | |
| BINASCII_CRC32_METHODDEF | |
| BINASCII_A2B_QP_METHODDEF | |
| BINASCII_B2A_QP_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| /* Initialization function for the module (*must* be called PyInit_binascii) */ | |
| PyDoc_STRVAR(doc_binascii, "Conversion between binary data and ASCII"); | |
| static int | |
| binascii_exec(PyObject *module) | |
| { | |
| binascii_state *state = PyModule_GetState(module); | |
| if (state == NULL) { | |
| return -1; | |
| } | |
| state->Error = PyErr_NewException("binascii.Error", PyExc_ValueError, NULL); | |
| if (PyModule_AddObjectRef(module, "Error", state->Error) < 0) { | |
| return -1; | |
| } | |
| state->Incomplete = PyErr_NewException("binascii.Incomplete", NULL, NULL); | |
| if (PyModule_AddObjectRef(module, "Incomplete", state->Incomplete) < 0) { | |
| return -1; | |
| } | |
| return 0; | |
| } | |
| static PyModuleDef_Slot binascii_slots[] = { | |
| {Py_mod_exec, binascii_exec}, | |
| {Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| static int | |
| binascii_traverse(PyObject *module, visitproc visit, void *arg) | |
| { | |
| binascii_state *state = get_binascii_state(module); | |
| Py_VISIT(state->Error); | |
| Py_VISIT(state->Incomplete); | |
| return 0; | |
| } | |
| static int | |
| binascii_clear(PyObject *module) | |
| { | |
| binascii_state *state = get_binascii_state(module); | |
| Py_CLEAR(state->Error); | |
| Py_CLEAR(state->Incomplete); | |
| return 0; | |
| } | |
| static void | |
| binascii_free(void *module) | |
| { | |
| binascii_clear((PyObject *)module); | |
| } | |
| static struct PyModuleDef binasciimodule = { | |
| PyModuleDef_HEAD_INIT, | |
| "binascii", | |
| doc_binascii, | |
| sizeof(binascii_state), | |
| binascii_module_methods, | |
| binascii_slots, | |
| binascii_traverse, | |
| binascii_clear, | |
| binascii_free | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit_binascii(void) | |
| { | |
| return PyModuleDef_Init(&binasciimodule); | |
| } | |
| /* Socket module header file */ | |
| /* Includes needed for the sockaddr_* symbols below */ | |
| #ifndef MS_WINDOWS | |
| #ifdef __VMS | |
| # include <socket.h> | |
| # else | |
| # include <sys/socket.h> | |
| # endif | |
| # include <netinet/in.h> | |
| # include <netinet/tcp.h> | |
| #else /* MS_WINDOWS */ | |
| # include <winsock2.h> | |
| /* | |
| * If Windows has bluetooth support, include bluetooth constants. | |
| */ | |
| #ifdef AF_BTH | |
| # include <ws2bth.h> | |
| # ifdef __clang__ | |
| # pragma clang diagnostic push | |
| # pragma clang diagnostic ignored "-Wpragma-pack" | |
| # endif | |
| # include <pshpack1.h> | |
| /* | |
| * The current implementation assumes the bdaddr in the sockaddr structs | |
| * will be a bdaddr_t. We treat this as an opaque type: on *nix systems, it | |
| * will be a struct with a single member (an array of six bytes). On windows, | |
| * we typedef this to ULONGLONG to match the Windows definition. | |
| */ | |
| typedef ULONGLONG bdaddr_t; | |
| /* | |
| * Redefine SOCKADDR_BTH to provide names compatible with _BT_RC_MEMB() macros. | |
| */ | |
| struct SOCKADDR_BTH_REDEF { | |
| union { | |
| USHORT addressFamily; | |
| USHORT family; | |
| }; | |
| union { | |
| ULONGLONG btAddr; | |
| bdaddr_t bdaddr; | |
| }; | |
| GUID serviceClassId; | |
| union { | |
| ULONG port; | |
| ULONG channel; | |
| }; | |
| }; | |
| # include <poppack.h> | |
| # ifdef __clang__ | |
| # pragma clang diagnostic pop | |
| # endif | |
| #endif /* AF_BTH */ | |
| /* Windows 'supports' CMSG_LEN, but does not follow the POSIX standard | |
| * interface at all, so there is no point including the code that | |
| * attempts to use it. | |
| */ | |
| # ifdef PySocket_BUILDING_SOCKET | |
| # undef CMSG_LEN | |
| # endif | |
| # include <ws2tcpip.h> | |
| /* VC6 is shipped with old platform headers, and does not have MSTcpIP.h | |
| * Separate SDKs have all the functions we want, but older ones don't have | |
| * any version information. | |
| * I use SIO_GET_MULTICAST_FILTER to detect a decent SDK. | |
| */ | |
| # ifdef SIO_GET_MULTICAST_FILTER | |
| # include <mstcpip.h> /* for SIO_RCVALL */ | |
| # define HAVE_ADDRINFO | |
| # define HAVE_SOCKADDR_STORAGE | |
| # define HAVE_GETADDRINFO | |
| # define HAVE_GETNAMEINFO | |
| # define ENABLE_IPV6 | |
| # else | |
| typedef int socklen_t; | |
| # endif /* IPPROTO_IPV6 */ | |
| /* Remove ifdef once Py_WINVER >= 0x0604 | |
| * socket.h only defines AF_HYPERV if _WIN32_WINNT is at that level or higher | |
| * so for now it's just manually defined. | |
| */ | |
| # ifndef AF_HYPERV | |
| # define AF_HYPERV 34 | |
| # endif | |
| # include <hvsocket.h> | |
| #endif /* MS_WINDOWS */ | |
| #ifdef HAVE_SYS_UN_H | |
| # include <sys/un.h> | |
| #else | |
| # undef AF_UNIX | |
| #endif | |
| #ifdef HAVE_LINUX_NETLINK_H | |
| # ifdef HAVE_ASM_TYPES_H | |
| # include <asm/types.h> | |
| # endif | |
| # include <linux/netlink.h> | |
| #elif defined(HAVE_NETLINK_NETLINK_H) | |
| # include <netlink/netlink.h> | |
| #else | |
| # undef AF_NETLINK | |
| #endif | |
| #ifdef HAVE_LINUX_QRTR_H | |
| # ifdef HAVE_ASM_TYPES_H | |
| # include <asm/types.h> | |
| # endif | |
| # include <linux/qrtr.h> | |
| #else | |
| # undef AF_QIPCRTR | |
| #endif | |
| #ifdef HAVE_BLUETOOTH_BLUETOOTH_H | |
| #include <bluetooth/bluetooth.h> | |
| #include <bluetooth/rfcomm.h> | |
| #include <bluetooth/l2cap.h> | |
| #include <bluetooth/sco.h> | |
| #include <bluetooth/hci.h> | |
| #endif | |
| #ifdef HAVE_BLUETOOTH_H | |
| #ifdef __FreeBSD__ | |
| #define L2CAP_SOCKET_CHECKED | |
| #endif | |
| #include <bluetooth.h> | |
| #endif | |
| #ifdef HAVE_NET_IF_H | |
| # include <net/if.h> | |
| #endif | |
| #ifdef HAVE_NETPACKET_PACKET_H | |
| # include <sys/ioctl.h> | |
| # include <netpacket/packet.h> | |
| #endif | |
| #ifdef HAVE_LINUX_TIPC_H | |
| # include <linux/tipc.h> | |
| #endif | |
| #ifdef HAVE_LINUX_CAN_H | |
| # include <linux/can.h> | |
| #elif defined(HAVE_NETCAN_CAN_H) | |
| # include <netcan/can.h> | |
| #else | |
| # undef AF_CAN | |
| # undef PF_CAN | |
| #endif | |
| #ifdef HAVE_LINUX_CAN_RAW_H | |
| #include <linux/can/raw.h> | |
| #endif | |
| #ifdef HAVE_LINUX_CAN_BCM_H | |
| #include <linux/can/bcm.h> | |
| #endif | |
| #ifdef HAVE_LINUX_CAN_ISOTP_H | |
| #include <linux/can/isotp.h> | |
| #endif | |
| #ifdef HAVE_LINUX_CAN_J1939_H | |
| #include <linux/can/j1939.h> | |
| #endif | |
| #ifdef HAVE_SYS_SYS_DOMAIN_H | |
| #include <sys/sys_domain.h> | |
| #endif | |
| #ifdef HAVE_SYS_KERN_CONTROL_H | |
| #include <sys/kern_control.h> | |
| #endif | |
| #ifdef HAVE_LINUX_VM_SOCKETS_H | |
| # include <linux/vm_sockets.h> | |
| #else | |
| # undef AF_VSOCK | |
| #endif | |
| #ifdef HAVE_LINUX_NETFILTER_IPV4_H | |
| # include <linux/netfilter_ipv4.h> | |
| #endif | |
| #ifdef HAVE_SOCKADDR_ALG | |
| # include <linux/if_alg.h> | |
| # ifndef AF_ALG | |
| # define AF_ALG 38 | |
| # endif | |
| # ifndef SOL_ALG | |
| # define SOL_ALG 279 | |
| # endif | |
| /* Linux 3.19 */ | |
| # ifndef ALG_SET_AEAD_ASSOCLEN | |
| # define ALG_SET_AEAD_ASSOCLEN 4 | |
| # endif | |
| # ifndef ALG_SET_AEAD_AUTHSIZE | |
| # define ALG_SET_AEAD_AUTHSIZE 5 | |
| # endif | |
| /* Linux 4.8 */ | |
| # ifndef ALG_SET_PUBKEY | |
| # define ALG_SET_PUBKEY 6 | |
| # endif | |
| # ifndef ALG_OP_SIGN | |
| # define ALG_OP_SIGN 2 | |
| # endif | |
| # ifndef ALG_OP_VERIFY | |
| # define ALG_OP_VERIFY 3 | |
| # endif | |
| #endif /* HAVE_SOCKADDR_ALG */ | |
| #ifdef __EMSCRIPTEN__ | |
| // wasm32-emscripten sockets only support subset of IPv4 and IPv6. | |
| // SCTP protocol crashes runtime. | |
| #ifdef IPPROTO_SCTP | |
| # undef IPPROTO_SCTP | |
| #endif | |
| // setsockopt() fails with ENOPROTOOPT, getsockopt only supports SO_ERROR. | |
| // undef SO_REUSEADDR and SO_REUSEPORT so they cannot be used. | |
| #ifdef SO_REUSEADDR | |
| # undef SO_REUSEADDR | |
| #endif | |
| #ifdef SO_REUSEPORT | |
| # undef SO_REUSEPORT | |
| #endif | |
| #endif // __EMSCRIPTEN__ | |
| #ifndef Py__SOCKET_H | |
| #define Py__SOCKET_H | |
| #ifdef __cplusplus | |
| extern "C" { | |
| #endif | |
| /* Python module and C API name */ | |
| #define PySocket_MODULE_NAME "_socket" | |
| #define PySocket_CAPI_NAME "CAPI" | |
| #define PySocket_CAPSULE_NAME PySocket_MODULE_NAME "." PySocket_CAPI_NAME | |
| /* Abstract the socket file descriptor type */ | |
| #ifdef MS_WINDOWS | |
| typedef SOCKET SOCKET_T; | |
| # ifdef MS_WIN64 | |
| # define SIZEOF_SOCKET_T 8 | |
| # else | |
| # define SIZEOF_SOCKET_T 4 | |
| # endif | |
| #else | |
| typedef int SOCKET_T; | |
| # define SIZEOF_SOCKET_T SIZEOF_INT | |
| #endif | |
| #if SIZEOF_SOCKET_T <= SIZEOF_LONG | |
| #define PyLong_FromSocket_t(fd) PyLong_FromLong((SOCKET_T)(fd)) | |
| #define PyLong_AsSocket_t(fd) (SOCKET_T)PyLong_AsLong(fd) | |
| #else | |
| #define PyLong_FromSocket_t(fd) PyLong_FromLongLong((SOCKET_T)(fd)) | |
| #define PyLong_AsSocket_t(fd) (SOCKET_T)PyLong_AsLongLong(fd) | |
| #endif | |
| // AF_HYPERV is only supported on Windows | |
| #if defined(AF_HYPERV) && (defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM)) | |
| # define HAVE_AF_HYPERV | |
| #endif | |
| /* Socket address */ | |
| typedef union sock_addr { | |
| struct sockaddr_in in; | |
| struct sockaddr sa; | |
| #ifdef AF_UNIX | |
| struct sockaddr_un un; | |
| #endif | |
| #ifdef AF_NETLINK | |
| struct sockaddr_nl nl; | |
| #endif | |
| #ifdef ENABLE_IPV6 | |
| struct sockaddr_in6 in6; | |
| struct sockaddr_storage storage; | |
| #endif | |
| #if defined(MS_WINDOWS) | |
| struct SOCKADDR_BTH_REDEF bt_rc; | |
| #elif defined(HAVE_BLUETOOTH_BLUETOOTH_H) // Linux | |
| struct sockaddr_l2 bt_l2; | |
| struct sockaddr_rc bt_rc; | |
| struct sockaddr_sco bt_sco; | |
| struct sockaddr_hci bt_hci; | |
| #elif defined(HAVE_BLUETOOTH_H) | |
| # if defined(__FreeBSD__) | |
| struct sockaddr_l2cap bt_l2; | |
| struct sockaddr_rfcomm bt_rc; | |
| struct sockaddr_sco bt_sco; | |
| struct sockaddr_hci bt_hci; | |
| # else // NetBSD, DragonFly BSD | |
| struct sockaddr_bt bt; | |
| # endif | |
| #endif | |
| #ifdef HAVE_NETPACKET_PACKET_H | |
| struct sockaddr_ll ll; | |
| #endif | |
| #if defined(HAVE_LINUX_CAN_H) || defined(HAVE_NETCAN_CAN_H) | |
| struct sockaddr_can can; | |
| #endif | |
| #ifdef HAVE_SYS_KERN_CONTROL_H | |
| struct sockaddr_ctl ctl; | |
| #endif | |
| #ifdef HAVE_SOCKADDR_ALG | |
| struct sockaddr_alg alg; | |
| #endif | |
| #ifdef AF_QIPCRTR | |
| struct sockaddr_qrtr sq; | |
| #endif | |
| #ifdef AF_VSOCK | |
| struct sockaddr_vm vm; | |
| #endif | |
| #ifdef HAVE_LINUX_TIPC_H | |
| struct sockaddr_tipc tipc; | |
| #endif | |
| #ifdef HAVE_AF_HYPERV | |
| SOCKADDR_HV hv; | |
| #endif | |
| } sock_addr_t; | |
| /* The object holding a socket. It holds some extra information, | |
| like the address family, which is used to decode socket address | |
| arguments properly. */ | |
| typedef struct { | |
| PyObject_HEAD | |
| SOCKET_T sock_fd; /* Socket file descriptor */ | |
| int sock_family; /* Address family, e.g., AF_INET */ | |
| int sock_type; /* Socket type, e.g., SOCK_STREAM */ | |
| int sock_proto; /* Protocol type, usually 0 */ | |
| PyObject *(*errorhandler)(void); /* Error handler; checks | |
| errno, returns NULL and | |
| sets a Python exception */ | |
| PyTime_t sock_timeout; /* Operation timeout in seconds; | |
| 0.0 means non-blocking */ | |
| struct _socket_state *state; | |
| #ifdef MS_WINDOWS | |
| int quickack; | |
| #endif | |
| } PySocketSockObject; | |
| /* --- C API ----------------------------------------------------*/ | |
| /* Short explanation of what this C API export mechanism does | |
| and how it works: | |
| The _ssl module needs access to the type object defined in | |
| the _socket module. Since cross-DLL linking introduces a lot of | |
| problems on many platforms, the "trick" is to wrap the | |
| C API of a module in a struct which then gets exported to | |
| other modules via a PyCapsule. | |
| The code in socketmodule.c defines this struct (which currently | |
| only contains the type object reference, but could very | |
| well also include other C APIs needed by other modules) | |
| and exports it as PyCapsule via the module dictionary | |
| under the name "CAPI". | |
| Other modules can now include the socketmodule.h file | |
| which defines the needed C APIs to import and set up | |
| a static copy of this struct in the importing module. | |
| After initialization, the importing module can then | |
| access the C APIs from the _socket module by simply | |
| referring to the static struct, e.g. | |
| Load _socket module and its C API; this sets up the global | |
| PySocketModule: | |
| if (PySocketModule_ImportModuleAndAPI()) | |
| return; | |
| Now use the C API as if it were defined in the using | |
| module: | |
| if (!PyArg_ParseTuple(args, "O!|zz:ssl", | |
| PySocketModule.Sock_Type, | |
| (PyObject*)&Sock, | |
| &key_file, &cert_file)) | |
| return NULL; | |
| Support could easily be extended to export more C APIs/symbols | |
| this way. Currently, only the type object is exported, | |
| other candidates would be socket constructors and socket | |
| access functions. | |
| */ | |
| /* C API for usage by other Python modules. | |
| * Always add new things to the end for binary compatibility. */ | |
| typedef struct { | |
| PyTypeObject *Sock_Type; | |
| PyObject *error; | |
| PyObject *timeout_error; | |
| } PySocketModule_APIObject; | |
| #define PySocketModule_ImportModuleAndAPI() PyCapsule_Import(PySocket_CAPSULE_NAME, 1) | |
| #ifdef __cplusplus | |
| } | |
| #endif | |
| #endif /* !Py__SOCKET_H */ | |
| /* math.integer module -- integer-related mathematical functions */ | |
| #ifndef Py_BUILD_CORE_BUILTIN | |
| # define Py_BUILD_CORE_MODULE 1 | |
| #endif | |
| #include "Python.h" | |
| #include "pycore_abstract.h" // _PyNumber_Index() | |
| #include "pycore_bitutils.h" // _Py_bit_length() | |
| #include "pycore_long.h" // _PyLong_GetZero() | |
| #include "clinic/mathintegermodule.c.h" | |
| /*[clinic input] | |
| module math | |
| module math.integer | |
| [clinic start generated code]*/ | |
| /*[clinic end generated code: output=da39a3ee5e6b4b0d input=e3d09c1c90de7fa8]*/ | |
| /*[clinic input] | |
| math.integer.gcd | |
| *integers as args: array | |
| Greatest Common Divisor. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_gcd_impl(PyObject *module, PyObject * const *args, | |
| Py_ssize_t args_length) | |
| /*[clinic end generated code: output=8e9c5bab06bea203 input=a90cde2ac5281551]*/ | |
| { | |
| // Fast-path for the common case: gcd(int, int) | |
| if (args_length == 2 && PyLong_CheckExact(args[0]) && PyLong_CheckExact(args[1])) | |
| { | |
| return _PyLong_GCD(args[0], args[1]); | |
| } | |
| if (args_length == 0) { | |
| return PyLong_FromLong(0); | |
| } | |
| PyObject *res = PyNumber_Index(args[0]); | |
| if (res == NULL) { | |
| return NULL; | |
| } | |
| if (args_length == 1) { | |
| Py_SETREF(res, PyNumber_Absolute(res)); | |
| return res; | |
| } | |
| PyObject *one = _PyLong_GetOne(); // borrowed ref | |
| for (Py_ssize_t i = 1; i < args_length; i++) { | |
| PyObject *x = _PyNumber_Index(args[i]); | |
| if (x == NULL) { | |
| Py_DECREF(res); | |
| return NULL; | |
| } | |
| if (res == one) { | |
| /* Fast path: just check arguments. | |
| It is okay to use identity comparison here. */ | |
| Py_DECREF(x); | |
| continue; | |
| } | |
| Py_SETREF(res, _PyLong_GCD(res, x)); | |
| Py_DECREF(x); | |
| if (res == NULL) { | |
| return NULL; | |
| } | |
| } | |
| return res; | |
| } | |
| static PyObject * | |
| long_lcm(PyObject *a, PyObject *b) | |
| { | |
| PyObject *g, *m, *f, *ab; | |
| if (_PyLong_IsZero((PyLongObject *)a) || _PyLong_IsZero((PyLongObject *)b)) { | |
| return PyLong_FromLong(0); | |
| } | |
| g = _PyLong_GCD(a, b); | |
| if (g == NULL) { | |
| return NULL; | |
| } | |
| f = PyNumber_FloorDivide(a, g); | |
| Py_DECREF(g); | |
| if (f == NULL) { | |
| return NULL; | |
| } | |
| m = PyNumber_Multiply(f, b); | |
| Py_DECREF(f); | |
| if (m == NULL) { | |
| return NULL; | |
| } | |
| ab = PyNumber_Absolute(m); | |
| Py_DECREF(m); | |
| return ab; | |
| } | |
| /*[clinic input] | |
| math.integer.lcm | |
| *integers as args: array | |
| Least Common Multiple. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_lcm_impl(PyObject *module, PyObject * const *args, | |
| Py_ssize_t args_length) | |
| /*[clinic end generated code: output=3e88889b866ccc28 input=261bddc85a136bdf]*/ | |
| { | |
| PyObject *res, *x; | |
| Py_ssize_t i; | |
| if (args_length == 0) { | |
| return PyLong_FromLong(1); | |
| } | |
| res = PyNumber_Index(args[0]); | |
| if (res == NULL) { | |
| return NULL; | |
| } | |
| if (args_length == 1) { | |
| Py_SETREF(res, PyNumber_Absolute(res)); | |
| return res; | |
| } | |
| PyObject *zero = _PyLong_GetZero(); // borrowed ref | |
| for (i = 1; i < args_length; i++) { | |
| x = PyNumber_Index(args[i]); | |
| if (x == NULL) { | |
| Py_DECREF(res); | |
| return NULL; | |
| } | |
| if (res == zero) { | |
| /* Fast path: just check arguments. | |
| It is okay to use identity comparison here. */ | |
| Py_DECREF(x); | |
| continue; | |
| } | |
| Py_SETREF(res, long_lcm(res, x)); | |
| Py_DECREF(x); | |
| if (res == NULL) { | |
| return NULL; | |
| } | |
| } | |
| return res; | |
| } | |
| /* Integer square root | |
| Given a nonnegative integer `n`, we want to compute the largest integer | |
| `a` for which `a * a <= n`, or equivalently the integer part of the exact | |
| square root of `n`. | |
| We use an adaptive-precision pure-integer version of Newton's iteration. Given | |
| a positive integer `n`, the algorithm produces at each iteration an integer | |
| approximation `a` to the square root of `n >> s` for some even integer `s`, | |
| with `s` decreasing as the iterations progress. On the final iteration, `s` is | |
| zero and we have an approximation to the square root of `n` itself. | |
| At every step, the approximation `a` is strictly within 1.0 of the true square | |
| root, so we have | |
| (a - 1)**2 < (n >> s) < (a + 1)**2 | |
| After the final iteration, a check-and-correct step is needed to determine | |
| whether `a` or `a - 1` gives the desired integer square root of `n`. | |
| The algorithm is remarkable in its simplicity. There's no need for a | |
| per-iteration check-and-correct step, and termination is straightforward: the | |
| number of iterations is known in advance (it's exactly `floor(log2(log2(n)))` | |
| for `n > 1`). The only tricky part of the correctness proof is in establishing | |
| that the bound `(a - 1)**2 < (n >> s) < (a + 1)**2` is maintained from one | |
| iteration to the next. A sketch of the proof of this is given below. | |
| In addition to the proof sketch, a formal, computer-verified proof | |
| of correctness (using Lean) of an equivalent recursive algorithm can be found | |
| here: | |
| https://github.com/mdickinson/snippets/blob/master/proofs/isqrt/src/isqrt.lean | |
| Here's Python code equivalent to the C implementation below: | |
| def isqrt(n): | |
| """ | |
| Return the integer part of the square root of the input. | |
| """ | |
| n = operator.index(n) | |
| if n < 0: | |
| raise ValueError("isqrt() argument must be nonnegative") | |
| if n == 0: | |
| return 0 | |
| c = (n.bit_length() - 1) // 2 | |
| a = 1 | |
| d = 0 | |
| for s in reversed(range(c.bit_length())): | |
| # Loop invariant: (a-1)**2 < (n >> 2*(c - d)) < (a+1)**2 | |
| e = d | |
| d = c >> s | |
| a = (a << d - e - 1) + (n >> 2*c - e - d + 1) // a | |
| return a - (a*a > n) | |
| Sketch of proof of correctness | |
| ------------------------------ | |
| The delicate part of the correctness proof is showing that the loop invariant | |
| is preserved from one iteration to the next. That is, just before the line | |
| a = (a << d - e - 1) + (n >> 2*c - e - d + 1) // a | |
| is executed in the above code, we know that | |
| (1) (a - 1)**2 < (n >> 2*(c - e)) < (a + 1)**2. | |
| (since `e` is always the value of `d` from the previous iteration). We must | |
| prove that after that line is executed, we have | |
| (a - 1)**2 < (n >> 2*(c - d)) < (a + 1)**2 | |
| To facilitate the proof, we make some changes of notation. Write `m` for | |
| `n >> 2*(c-d)`, and write `b` for the new value of `a`, so | |
| b = (a << d - e - 1) + (n >> 2*c - e - d + 1) // a | |
| or equivalently: | |
| (2) b = (a << d - e - 1) + (m >> d - e + 1) // a | |
| Then we can rewrite (1) as: | |
| (3) (a - 1)**2 < (m >> 2*(d - e)) < (a + 1)**2 | |
| and we must show that (b - 1)**2 < m < (b + 1)**2. | |
| From this point on, we switch to mathematical notation, so `/` means exact | |
| division rather than integer division and `^` is used for exponentiation. We | |
| use the `√` symbol for the exact square root. In (3), we can remove the | |
| implicit floor operation to give: | |
| (4) (a - 1)^2 < m / 4^(d - e) < (a + 1)^2 | |
| Taking square roots throughout (4), scaling by `2^(d-e)`, and rearranging gives | |
| (5) 0 <= | 2^(d-e)a - √m | < 2^(d-e) | |
| Squaring and dividing through by `2^(d-e+1) a` gives | |
| (6) 0 <= 2^(d-e-1) a + m / (2^(d-e+1) a) - √m < 2^(d-e-1) / a | |
| We'll show below that `2^(d-e-1) <= a`. Given that, we can replace the | |
| right-hand side of (6) with `1`, and now replacing the central | |
| term `m / (2^(d-e+1) a)` with its floor in (6) gives | |
| (7) -1 < 2^(d-e-1) a + m // 2^(d-e+1) a - √m < 1 | |
| Or equivalently, from (2): | |
| (7) -1 < b - √m < 1 | |
| and rearranging gives that `(b-1)^2 < m < (b+1)^2`, which is what we needed | |
| to prove. | |
| We're not quite done: we still have to prove the inequality `2^(d - e - 1) <= | |
| a` that was used to get line (7) above. From the definition of `c`, we have | |
| `4^c <= n`, which implies | |
| (8) 4^d <= m | |
| also, since `e == d >> 1`, `d` is at most `2e + 1`, from which it follows | |
| that `2d - 2e - 1 <= d` and hence that | |
| (9) 4^(2d - 2e - 1) <= m | |
| Dividing both sides by `4^(d - e)` gives | |
| (10) 4^(d - e - 1) <= m / 4^(d - e) | |
| But we know from (4) that `m / 4^(d-e) < (a + 1)^2`, hence | |
| (11) 4^(d - e - 1) < (a + 1)^2 | |
| Now taking square roots of both sides and observing that both `2^(d-e-1)` and | |
| `a` are integers gives `2^(d - e - 1) <= a`, which is what we needed. This | |
| completes the proof sketch. | |
| */ | |
| /* | |
| The _approximate_isqrt_tab table provides approximate square roots for | |
| 16-bit integers. For any n in the range 2**14 <= n < 2**16, the value | |
| a = _approximate_isqrt_tab[(n >> 8) - 64] | |
| is an approximate square root of n, satisfying (a - 1)**2 < n < (a + 1)**2. | |
| The table was computed in Python using the expression: | |
| [min(round(sqrt(256*n + 128)), 255) for n in range(64, 256)] | |
| */ | |
| static const uint8_t _approximate_isqrt_tab[192] = { | |
| 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, | |
| 140, 141, 142, 143, 144, 144, 145, 146, 147, 148, 149, 150, | |
| 151, 151, 152, 153, 154, 155, 156, 156, 157, 158, 159, 160, | |
| 160, 161, 162, 163, 164, 164, 165, 166, 167, 167, 168, 169, | |
| 170, 170, 171, 172, 173, 173, 174, 175, 176, 176, 177, 178, | |
| 179, 179, 180, 181, 181, 182, 183, 183, 184, 185, 186, 186, | |
| 187, 188, 188, 189, 190, 190, 191, 192, 192, 193, 194, 194, | |
| 195, 196, 196, 197, 198, 198, 199, 200, 200, 201, 201, 202, | |
| 203, 203, 204, 205, 205, 206, 206, 207, 208, 208, 209, 210, | |
| 210, 211, 211, 212, 213, 213, 214, 214, 215, 216, 216, 217, | |
| 217, 218, 219, 219, 220, 220, 221, 221, 222, 223, 223, 224, | |
| 224, 225, 225, 226, 227, 227, 228, 228, 229, 229, 230, 230, | |
| 231, 232, 232, 233, 233, 234, 234, 235, 235, 236, 237, 237, | |
| 238, 238, 239, 239, 240, 240, 241, 241, 242, 242, 243, 243, | |
| 244, 244, 245, 246, 246, 247, 247, 248, 248, 249, 249, 250, | |
| 250, 251, 251, 252, 252, 253, 253, 254, 254, 255, 255, 255, | |
| }; | |
| /* Approximate square root of a large 64-bit integer. | |
| Given `n` satisfying `2**62 <= n < 2**64`, return `a` | |
| satisfying `(a - 1)**2 < n < (a + 1)**2`. */ | |
| static inline uint32_t | |
| _approximate_isqrt(uint64_t n) | |
| { | |
| uint32_t u = _approximate_isqrt_tab[(n >> 56) - 64]; | |
| u = (u << 7) + (uint32_t)(n >> 41) / u; | |
| return (u << 15) + (uint32_t)((n >> 17) / u); | |
| } | |
| /*[clinic input] | |
| math.integer.isqrt | |
| n: object | |
| / | |
| Return the integer part of the square root of the input. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_isqrt(PyObject *module, PyObject *n) | |
| /*[clinic end generated code: output=551031e41a0f5d9e input=921ddd9853133d8d]*/ | |
| { | |
| int a_too_large, c_bit_length; | |
| int64_t c, d; | |
| uint64_t m; | |
| uint32_t u; | |
| PyObject *a = NULL, *b; | |
| n = _PyNumber_Index(n); | |
| if (n == NULL) { | |
| return NULL; | |
| } | |
| if (_PyLong_IsNegative((PyLongObject *)n)) { | |
| PyErr_SetString( | |
| PyExc_ValueError, | |
| "isqrt() argument must be nonnegative"); | |
| goto error; | |
| } | |
| if (_PyLong_IsZero((PyLongObject *)n)) { | |
| Py_DECREF(n); | |
| return PyLong_FromLong(0); | |
| } | |
| /* c = (n.bit_length() - 1) // 2 */ | |
| c = _PyLong_NumBits(n); | |
| assert(c > 0); | |
| assert(!PyErr_Occurred()); | |
| c = (c - 1) / 2; | |
| /* Fast path: if c <= 31 then n < 2**64 and we can compute directly with a | |
| fast, almost branch-free algorithm. */ | |
| if (c <= 31) { | |
| int shift = 31 - (int)c; | |
| m = (uint64_t)PyLong_AsUnsignedLongLong(n); | |
| Py_DECREF(n); | |
| if (m == (uint64_t)(-1) && PyErr_Occurred()) { | |
| return NULL; | |
| } | |
| u = _approximate_isqrt(m << 2*shift) >> shift; | |
| u -= (uint64_t)u * u > m; | |
| return PyLong_FromUnsignedLong(u); | |
| } | |
| /* Slow path: n >= 2**64. We perform the first five iterations in C integer | |
| arithmetic, then switch to using Python long integers. */ | |
| /* From n >= 2**64 it follows that c.bit_length() >= 6. */ | |
| c_bit_length = 6; | |
| while ((c >> c_bit_length) > 0) { | |
| ++c_bit_length; | |
| } | |
| /* Initialise d and a. */ | |
| d = c >> (c_bit_length - 5); | |
| b = _PyLong_Rshift(n, 2*c - 62); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| m = (uint64_t)PyLong_AsUnsignedLongLong(b); | |
| Py_DECREF(b); | |
| if (m == (uint64_t)(-1) && PyErr_Occurred()) { | |
| goto error; | |
| } | |
| u = _approximate_isqrt(m) >> (31U - d); | |
| a = PyLong_FromUnsignedLong(u); | |
| if (a == NULL) { | |
| goto error; | |
| } | |
| for (int s = c_bit_length - 6; s >= 0; --s) { | |
| PyObject *q; | |
| int64_t e = d; | |
| d = c >> s; | |
| /* q = (n >> 2*c - e - d + 1) // a */ | |
| q = _PyLong_Rshift(n, 2*c - d - e + 1); | |
| if (q == NULL) { | |
| goto error; | |
| } | |
| Py_SETREF(q, PyNumber_FloorDivide(q, a)); | |
| if (q == NULL) { | |
| goto error; | |
| } | |
| /* a = (a << d - 1 - e) + q */ | |
| Py_SETREF(a, _PyLong_Lshift(a, d - 1 - e)); | |
| if (a == NULL) { | |
| Py_DECREF(q); | |
| goto error; | |
| } | |
| Py_SETREF(a, PyNumber_Add(a, q)); | |
| Py_DECREF(q); | |
| if (a == NULL) { | |
| goto error; | |
| } | |
| } | |
| /* The correct result is either a or a - 1. Figure out which, and | |
| decrement a if necessary. */ | |
| /* a_too_large = n < a * a */ | |
| b = PyNumber_Multiply(a, a); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| a_too_large = PyObject_RichCompareBool(n, b, Py_LT); | |
| Py_DECREF(b); | |
| if (a_too_large == -1) { | |
| goto error; | |
| } | |
| if (a_too_large) { | |
| Py_SETREF(a, PyNumber_Subtract(a, _PyLong_GetOne())); | |
| } | |
| Py_DECREF(n); | |
| return a; | |
| error: | |
| Py_XDECREF(a); | |
| Py_DECREF(n); | |
| return NULL; | |
| } | |
| static unsigned long | |
| count_set_bits(unsigned long n) | |
| { | |
| unsigned long count = 0; | |
| while (n != 0) { | |
| ++count; | |
| n &= n - 1; /* clear least significant bit */ | |
| } | |
| return count; | |
| } | |
| /* Divide-and-conquer factorial algorithm | |
| * | |
| * Based on the formula and pseudo-code provided at: | |
| * http://www.luschny.de/math/factorial/binarysplitfact.html | |
| * | |
| * Faster algorithms exist, but they're more complicated and depend on | |
| * a fast prime factorization algorithm. | |
| * | |
| * Notes on the algorithm | |
| * ---------------------- | |
| * | |
| * factorial(n) is written in the form 2**k * m, with m odd. k and m are | |
| * computed separately, and then combined using a left shift. | |
| * | |
| * The function factorial_odd_part computes the odd part m (i.e., the greatest | |
| * odd divisor) of factorial(n), using the formula: | |
| * | |
| * factorial_odd_part(n) = | |
| * | |
| * product_{i >= 0} product_{0 < j <= n / 2**i, j odd} j | |
| * | |
| * Example: factorial_odd_part(20) = | |
| * | |
| * (1) * | |
| * (1) * | |
| * (1 * 3 * 5) * | |
| * (1 * 3 * 5 * 7 * 9) * | |
| * (1 * 3 * 5 * 7 * 9 * 11 * 13 * 15 * 17 * 19) | |
| * | |
| * Here i goes from large to small: the first term corresponds to i=4 (any | |
| * larger i gives an empty product), and the last term corresponds to i=0. | |
| * Each term can be computed from the last by multiplying by the extra odd | |
| * numbers required: e.g., to get from the penultimate term to the last one, | |
| * we multiply by (11 * 13 * 15 * 17 * 19). | |
| * | |
| * To see a hint of why this formula works, here are the same numbers as above | |
| * but with the even parts (i.e., the appropriate powers of 2) included. For | |
| * each subterm in the product for i, we multiply that subterm by 2**i: | |
| * | |
| * factorial(20) = | |
| * | |
| * (16) * | |
| * (8) * | |
| * (4 * 12 * 20) * | |
| * (2 * 6 * 10 * 14 * 18) * | |
| * (1 * 3 * 5 * 7 * 9 * 11 * 13 * 15 * 17 * 19) | |
| * | |
| * The factorial_partial_product function computes the product of all odd j in | |
| * range(start, stop) for given start and stop. It's used to compute the | |
| * partial products like (11 * 13 * 15 * 17 * 19) in the example above. It | |
| * operates recursively, repeatedly splitting the range into two roughly equal | |
| * pieces until the subranges are small enough to be computed using only C | |
| * integer arithmetic. | |
| * | |
| * The two-valuation k (i.e., the exponent of the largest power of 2 dividing | |
| * the factorial) is computed independently in the main math_integer_factorial | |
| * function. By standard results, its value is: | |
| * | |
| * two_valuation = n//2 + n//4 + n//8 + .... | |
| * | |
| * It can be shown (e.g., by complete induction on n) that two_valuation is | |
| * equal to n - count_set_bits(n), where count_set_bits(n) gives the number of | |
| * '1'-bits in the binary expansion of n. | |
| */ | |
| /* factorial_partial_product: Compute product(range(start, stop, 2)) using | |
| * divide and conquer. Assumes start and stop are odd and stop > start. | |
| * max_bits must be >= bit_length(stop - 2). */ | |
| static PyObject * | |
| factorial_partial_product(unsigned long start, unsigned long stop, | |
| unsigned long max_bits) | |
| { | |
| unsigned long midpoint, num_operands; | |
| PyObject *left = NULL, *right = NULL, *result = NULL; | |
| /* If the return value will fit an unsigned long, then we can | |
| * multiply in a tight, fast loop where each multiply is O(1). | |
| * Compute an upper bound on the number of bits required to store | |
| * the answer. | |
| * | |
| * Storing some integer z requires floor(lg(z))+1 bits, which is | |
| * conveniently the value returned by bit_length(z). The | |
| * product x*y will require at most | |
| * bit_length(x) + bit_length(y) bits to store, based | |
| * on the idea that lg product = lg x + lg y. | |
| * | |
| * We know that stop - 2 is the largest number to be multiplied. From | |
| * there, we have: bit_length(answer) <= num_operands * | |
| * bit_length(stop - 2) | |
| */ | |
| num_operands = (stop - start) / 2; | |
| /* The "num_operands <= 8 * SIZEOF_LONG" check guards against the | |
| * unlikely case of an overflow in num_operands * max_bits. */ | |
| if (num_operands <= 8 * SIZEOF_LONG && | |
| num_operands * max_bits <= 8 * SIZEOF_LONG) { | |
| unsigned long j, total; | |
| for (total = start, j = start + 2; j < stop; j += 2) | |
| total *= j; | |
| return PyLong_FromUnsignedLong(total); | |
| } | |
| /* find midpoint of range(start, stop), rounded up to next odd number. */ | |
| midpoint = (start + num_operands) | 1; | |
| left = factorial_partial_product(start, midpoint, | |
| _Py_bit_length(midpoint - 2)); | |
| if (left == NULL) | |
| goto error; | |
| right = factorial_partial_product(midpoint, stop, max_bits); | |
| if (right == NULL) | |
| goto error; | |
| result = PyNumber_Multiply(left, right); | |
| error: | |
| Py_XDECREF(left); | |
| Py_XDECREF(right); | |
| return result; | |
| } | |
| /* factorial_odd_part: compute the odd part of factorial(n). */ | |
| static PyObject * | |
| factorial_odd_part(unsigned long n) | |
| { | |
| long i; | |
| unsigned long v, lower, upper; | |
| PyObject *partial, *tmp, *inner, *outer; | |
| inner = PyLong_FromLong(1); | |
| if (inner == NULL) | |
| return NULL; | |
| outer = Py_NewRef(inner); | |
| upper = 3; | |
| for (i = _Py_bit_length(n) - 2; i >= 0; i--) { | |
| v = n >> i; | |
| if (v <= 2) | |
| continue; | |
| lower = upper; | |
| /* (v + 1) | 1 = least odd integer strictly larger than n / 2**i */ | |
| upper = (v + 1) | 1; | |
| /* Here inner is the product of all odd integers j in the range (0, | |
| n/2**(i+1)]. The factorial_partial_product call below gives the | |
| product of all odd integers j in the range (n/2**(i+1), n/2**i]. */ | |
| partial = factorial_partial_product(lower, upper, _Py_bit_length(upper-2)); | |
| /* inner *= partial */ | |
| if (partial == NULL) | |
| goto error; | |
| tmp = PyNumber_Multiply(inner, partial); | |
| Py_DECREF(partial); | |
| if (tmp == NULL) | |
| goto error; | |
| Py_SETREF(inner, tmp); | |
| /* Now inner is the product of all odd integers j in the range (0, | |
| n/2**i], giving the inner product in the formula above. */ | |
| /* outer *= inner; */ | |
| tmp = PyNumber_Multiply(outer, inner); | |
| if (tmp == NULL) | |
| goto error; | |
| Py_SETREF(outer, tmp); | |
| } | |
| Py_DECREF(inner); | |
| return outer; | |
| error: | |
| Py_DECREF(outer); | |
| Py_DECREF(inner); | |
| return NULL; | |
| } | |
| /* Lookup table for small factorial values */ | |
| static const unsigned long SmallFactorials[] = { | |
| 1, 1, 2, 6, 24, 120, 720, 5040, 40320, | |
| 362880, 3628800, 39916800, 479001600, | |
| #if SIZEOF_LONG >= 8 | |
| 6227020800, 87178291200, 1307674368000, | |
| 20922789888000, 355687428096000, 6402373705728000, | |
| 121645100408832000, 2432902008176640000 | |
| #endif | |
| }; | |
| /*[clinic input] | |
| math.integer.factorial | |
| n as arg: object | |
| / | |
| Find n!. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_factorial(PyObject *module, PyObject *arg) | |
| /*[clinic end generated code: output=131c23fd48650414 input=742f4dfa490a1b07]*/ | |
| { | |
| long x, two_valuation; | |
| int overflow; | |
| PyObject *result, *odd_part; | |
| x = PyLong_AsLongAndOverflow(arg, &overflow); | |
| if (x == -1 && PyErr_Occurred()) { | |
| return NULL; | |
| } | |
| else if (overflow == 1) { | |
| PyErr_Format(PyExc_OverflowError, | |
| "factorial() argument should not exceed %ld", | |
| LONG_MAX); | |
| return NULL; | |
| } | |
| else if (overflow == -1 || x < 0) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "factorial() not defined for negative values"); | |
| return NULL; | |
| } | |
| /* use lookup table if x is small */ | |
| if (x < (long)Py_ARRAY_LENGTH(SmallFactorials)) | |
| return PyLong_FromUnsignedLong(SmallFactorials[x]); | |
| /* else express in the form odd_part * 2**two_valuation, and compute as | |
| odd_part << two_valuation. */ | |
| odd_part = factorial_odd_part(x); | |
| if (odd_part == NULL) | |
| return NULL; | |
| two_valuation = x - count_set_bits(x); | |
| result = _PyLong_Lshift(odd_part, two_valuation); | |
| Py_DECREF(odd_part); | |
| return result; | |
| } | |
| /* least significant 64 bits of the odd part of factorial(n), for n in range(128). | |
| Python code to generate the values: | |
| import math.integer | |
| for n in range(128): | |
| fac = math.integer.factorial(n) | |
| fac_odd_part = fac // (fac & -fac) | |
| reduced_fac_odd_part = fac_odd_part % (2**64) | |
| print(f"{reduced_fac_odd_part:#018x}u") | |
| */ | |
| static const uint64_t reduced_factorial_odd_part[] = { | |
| 0x0000000000000001u, 0x0000000000000001u, 0x0000000000000001u, 0x0000000000000003u, | |
| 0x0000000000000003u, 0x000000000000000fu, 0x000000000000002du, 0x000000000000013bu, | |
| 0x000000000000013bu, 0x0000000000000b13u, 0x000000000000375fu, 0x0000000000026115u, | |
| 0x000000000007233fu, 0x00000000005cca33u, 0x0000000002898765u, 0x00000000260eeeebu, | |
| 0x00000000260eeeebu, 0x0000000286fddd9bu, 0x00000016beecca73u, 0x000001b02b930689u, | |
| 0x00000870d9df20adu, 0x0000b141df4dae31u, 0x00079dd498567c1bu, 0x00af2e19afc5266du, | |
| 0x020d8a4d0f4f7347u, 0x335281867ec241efu, 0x9b3093d46fdd5923u, 0x5e1f9767cc5866b1u, | |
| 0x92dd23d6966aced7u, 0xa30d0f4f0a196e5bu, 0x8dc3e5a1977d7755u, 0x2ab8ce915831734bu, | |
| 0x2ab8ce915831734bu, 0x81d2a0bc5e5fdcabu, 0x9efcac82445da75bu, 0xbc8b95cf58cde171u, | |
| 0xa0e8444a1f3cecf9u, 0x4191deb683ce3ffdu, 0xddd3878bc84ebfc7u, 0xcb39a64b83ff3751u, | |
| 0xf8203f7993fc1495u, 0xbd2a2a78b35f4bddu, 0x84757be6b6d13921u, 0x3fbbcfc0b524988bu, | |
| 0xbd11ed47c8928df9u, 0x3c26b59e41c2f4c5u, 0x677a5137e883fdb3u, 0xff74e943b03b93ddu, | |
| 0xfe5ebbcb10b2bb97u, 0xb021f1de3235e7e7u, 0x33509eb2e743a58fu, 0x390f9da41279fb7du, | |
| 0xe5cb0154f031c559u, 0x93074695ba4ddb6du, 0x81c471caa636247fu, 0xe1347289b5a1d749u, | |
| 0x286f21c3f76ce2ffu, 0x00be84a2173e8ac7u, 0x1595065ca215b88bu, 0xf95877595b018809u, | |
| 0x9c2efe3c5516f887u, 0x373294604679382bu, 0xaf1ff7a888adcd35u, 0x18ddf279a2c5800bu, | |
| 0x18ddf279a2c5800bu, 0x505a90e2542582cbu, 0x5bacad2cd8d5dc2bu, 0xfe3152bcbff89f41u, | |
| 0xe1467e88bf829351u, 0xb8001adb9e31b4d5u, 0x2803ac06a0cbb91fu, 0x1904b5d698805799u, | |
| 0xe12a648b5c831461u, 0x3516abbd6160cfa9u, 0xac46d25f12fe036du, 0x78bfa1da906b00efu, | |
| 0xf6390338b7f111bdu, 0x0f25f80f538255d9u, 0x4ec8ca55b8db140fu, 0x4ff670740b9b30a1u, | |
| 0x8fd032443a07f325u, 0x80dfe7965c83eeb5u, 0xa3dc1714d1213afdu, 0x205b7bbfcdc62007u, | |
| 0xa78126bbe140a093u, 0x9de1dc61ca7550cfu, 0x84f0046d01b492c5u, 0x2d91810b945de0f3u, | |
| 0xf5408b7f6008aa71u, 0x43707f4863034149u, 0xdac65fb9679279d5u, 0xc48406e7d1114eb7u, | |
| 0xa7dc9ed3c88e1271u, 0xfb25b2efdb9cb30du, 0x1bebda0951c4df63u, 0x5c85e975580ee5bdu, | |
| 0x1591bc60082cb137u, 0x2c38606318ef25d7u, 0x76ca72f7c5c63e27u, 0xf04a75d17baa0915u, | |
| 0x77458175139ae30du, 0x0e6c1330bc1b9421u, 0xdf87d2b5797e8293u, 0xefa5c703e1e68925u, | |
| 0x2b6b1b3278b4f6e1u, 0xceee27b382394249u, 0xd74e3829f5dab91du, 0xfdb17989c26b5f1fu, | |
| 0xc1b7d18781530845u, 0x7b4436b2105a8561u, 0x7ba7c0418372a7d7u, 0x9dbc5c67feb6c639u, | |
| 0x502686d7f6ff6b8fu, 0x6101855406be7a1fu, 0x9956afb5806930e7u, 0xe1f0ee88af40f7c5u, | |
| 0x984b057bda5c1151u, 0x9a49819acc13ea05u, 0x8ef0dead0896ef27u, 0x71f7826efe292b21u, | |
| 0xad80a480e46986efu, 0x01cdc0ebf5e0c6f7u, 0x6e06f839968f68dbu, 0xdd5943ab56e76139u, | |
| 0xcdcf31bf8604c5e7u, 0x7e2b4a847054a1cbu, 0x0ca75697a4d3d0f5u, 0x4703f53ac514a98bu, | |
| }; | |
| /* inverses of reduced_factorial_odd_part values modulo 2**64. | |
| Python code to generate the values: | |
| import math.integer | |
| for n in range(128): | |
| fac = math.integer.factorial(n) | |
| fac_odd_part = fac // (fac & -fac) | |
| inverted_fac_odd_part = pow(fac_odd_part, -1, 2**64) | |
| print(f"{inverted_fac_odd_part:#018x}u") | |
| */ | |
| static const uint64_t inverted_factorial_odd_part[] = { | |
| 0x0000000000000001u, 0x0000000000000001u, 0x0000000000000001u, 0xaaaaaaaaaaaaaaabu, | |
| 0xaaaaaaaaaaaaaaabu, 0xeeeeeeeeeeeeeeefu, 0x4fa4fa4fa4fa4fa5u, 0x2ff2ff2ff2ff2ff3u, | |
| 0x2ff2ff2ff2ff2ff3u, 0x938cc70553e3771bu, 0xb71c27cddd93e49fu, 0xb38e3229fcdee63du, | |
| 0xe684bb63544a4cbfu, 0xc2f684917ca340fbu, 0xf747c9cba417526du, 0xbb26eb51d7bd49c3u, | |
| 0xbb26eb51d7bd49c3u, 0xb0a7efb985294093u, 0xbe4b8c69f259eabbu, 0x6854d17ed6dc4fb9u, | |
| 0xe1aa904c915f4325u, 0x3b8206df131cead1u, 0x79c6009fea76fe13u, 0xd8c5d381633cd365u, | |
| 0x4841f12b21144677u, 0x4a91ff68200b0d0fu, 0x8f9513a58c4f9e8bu, 0x2b3e690621a42251u, | |
| 0x4f520f00e03c04e7u, 0x2edf84ee600211d3u, 0xadcaa2764aaacdfdu, 0x161f4f9033f4fe63u, | |
| 0x161f4f9033f4fe63u, 0xbada2932ea4d3e03u, 0xcec189f3efaa30d3u, 0xf7475bb68330bf91u, | |
| 0x37eb7bf7d5b01549u, 0x46b35660a4e91555u, 0xa567c12d81f151f7u, 0x4c724007bb2071b1u, | |
| 0x0f4a0cce58a016bdu, 0xfa21068e66106475u, 0x244ab72b5a318ae1u, 0x366ce67e080d0f23u, | |
| 0xd666fdae5dd2a449u, 0xd740ddd0acc06a0du, 0xb050bbbb28e6f97bu, 0x70b003fe890a5c75u, | |
| 0xd03aabff83037427u, 0x13ec4ca72c783bd7u, 0x90282c06afdbd96fu, 0x4414ddb9db4a95d5u, | |
| 0xa2c68735ae6832e9u, 0xbf72d71455676665u, 0xa8469fab6b759b7fu, 0xc1e55b56e606caf9u, | |
| 0x40455630fc4a1cffu, 0x0120a7b0046d16f7u, 0xa7c3553b08faef23u, 0x9f0bfd1b08d48639u, | |
| 0xa433ffce9a304d37u, 0xa22ad1d53915c683u, 0xcb6cbc723ba5dd1du, 0x547fb1b8ab9d0ba3u, | |
| 0x547fb1b8ab9d0ba3u, 0x8f15a826498852e3u, 0x32e1a03f38880283u, 0x3de4cce63283f0c1u, | |
| 0x5dfe6667e4da95b1u, 0xfda6eeeef479e47du, 0xf14de991cc7882dfu, 0xe68db79247630ca9u, | |
| 0xa7d6db8207ee8fa1u, 0x255e1f0fcf034499u, 0xc9a8990e43dd7e65u, 0x3279b6f289702e0fu, | |
| 0xe7b5905d9b71b195u, 0x03025ba41ff0da69u, 0xb7df3d6d3be55aefu, 0xf89b212ebff2b361u, | |
| 0xfe856d095996f0adu, 0xd6e533e9fdf20f9du, 0xf8c0e84a63da3255u, 0xa677876cd91b4db7u, | |
| 0x07ed4f97780d7d9bu, 0x90a8705f258db62fu, 0xa41bbb2be31b1c0du, 0x6ec28690b038383bu, | |
| 0xdb860c3bb2edd691u, 0x0838286838a980f9u, 0x558417a74b36f77du, 0x71779afc3646ef07u, | |
| 0x743cda377ccb6e91u, 0x7fdf9f3fe89153c5u, 0xdc97d25df49b9a4bu, 0x76321a778eb37d95u, | |
| 0x7cbb5e27da3bd487u, 0x9cff4ade1a009de7u, 0x70eb166d05c15197u, 0xdcf0460b71d5fe3du, | |
| 0x5ac1ee5260b6a3c5u, 0xc922dedfdd78efe1u, 0xe5d381dc3b8eeb9bu, 0xd57e5347bafc6aadu, | |
| 0x86939040983acd21u, 0x395b9d69740a4ff9u, 0x1467299c8e43d135u, 0x5fe440fcad975cdfu, | |
| 0xcaa9a39794a6ca8du, 0xf61dbd640868dea1u, 0xac09d98d74843be7u, 0x2b103b9e1a6b4809u, | |
| 0x2ab92d16960f536fu, 0x6653323d5e3681dfu, 0xefd48c1c0624e2d7u, 0xa496fefe04816f0du, | |
| 0x1754a7b07bbdd7b1u, 0x23353c829a3852cdu, 0xbf831261abd59097u, 0x57a8e656df0618e1u, | |
| 0x16e9206c3100680fu, 0xadad4c6ee921dac7u, 0x635f2b3860265353u, 0xdd6d0059f44b3d09u, | |
| 0xac4dd6b894447dd7u, 0x42ea183eeaa87be3u, 0x15612d1550ee5b5du, 0x226fa19d656cb623u, | |
| }; | |
| /* exponent of the largest power of 2 dividing factorial(n), for n in range(68) | |
| Python code to generate the values: | |
| import math.integer | |
| for n in range(128): | |
| fac = math.integer.factorial(n) | |
| fac_trailing_zeros = (fac & -fac).bit_length() - 1 | |
| print(fac_trailing_zeros) | |
| */ | |
| static const uint8_t factorial_trailing_zeros[] = { | |
| 0, 0, 1, 1, 3, 3, 4, 4, 7, 7, 8, 8, 10, 10, 11, 11, // 0-15 | |
| 15, 15, 16, 16, 18, 18, 19, 19, 22, 22, 23, 23, 25, 25, 26, 26, // 16-31 | |
| 31, 31, 32, 32, 34, 34, 35, 35, 38, 38, 39, 39, 41, 41, 42, 42, // 32-47 | |
| 46, 46, 47, 47, 49, 49, 50, 50, 53, 53, 54, 54, 56, 56, 57, 57, // 48-63 | |
| 63, 63, 64, 64, 66, 66, 67, 67, 70, 70, 71, 71, 73, 73, 74, 74, // 64-79 | |
| 78, 78, 79, 79, 81, 81, 82, 82, 85, 85, 86, 86, 88, 88, 89, 89, // 80-95 | |
| 94, 94, 95, 95, 97, 97, 98, 98, 101, 101, 102, 102, 104, 104, 105, 105, // 96-111 | |
| 109, 109, 110, 110, 112, 112, 113, 113, 116, 116, 117, 117, 119, 119, 120, 120, // 112-127 | |
| }; | |
| /* Number of permutations and combinations. | |
| * P(n, k) = n! / (n-k)! | |
| * C(n, k) = P(n, k) / k! | |
| */ | |
| /* Calculate C(n, k) for n in the 63-bit range. */ | |
| static PyObject * | |
| perm_comb_small(unsigned long long n, unsigned long long k, int iscomb) | |
| { | |
| assert(k != 0); | |
| /* For small enough n and k the result fits in the 64-bit range and can | |
| * be calculated without allocating intermediate PyLong objects. */ | |
| if (iscomb) { | |
| /* Maps k to the maximal n so that 2*k-1 <= n <= 127 and C(n, k) | |
| * fits into a uint64_t. Exclude k = 1, because the second fast | |
| * path is faster for this case.*/ | |
| static const unsigned char fast_comb_limits1[] = { | |
| 0, 0, 127, 127, 127, 127, 127, 127, // 0-7 | |
| 127, 127, 127, 127, 127, 127, 127, 127, // 8-15 | |
| 116, 105, 97, 91, 86, 82, 78, 76, // 16-23 | |
| 74, 72, 71, 70, 69, 68, 68, 67, // 24-31 | |
| 67, 67, 67, // 32-34 | |
| }; | |
| if (k < Py_ARRAY_LENGTH(fast_comb_limits1) && n <= fast_comb_limits1[k]) { | |
| /* | |
| comb(n, k) fits into a uint64_t. We compute it as | |
| comb_odd_part << shift | |
| where 2**shift is the largest power of two dividing comb(n, k) | |
| and comb_odd_part is comb(n, k) >> shift. comb_odd_part can be | |
| calculated efficiently via arithmetic modulo 2**64, using three | |
| lookups and two uint64_t multiplications. | |
| */ | |
| uint64_t comb_odd_part = reduced_factorial_odd_part[n] | |
| * inverted_factorial_odd_part[k] | |
| * inverted_factorial_odd_part[n - k]; | |
| int shift = factorial_trailing_zeros[n] | |
| - factorial_trailing_zeros[k] | |
| - factorial_trailing_zeros[n - k]; | |
| return PyLong_FromUnsignedLongLong(comb_odd_part << shift); | |
| } | |
| /* Maps k to the maximal n so that 2*k-1 <= n <= 127 and C(n, k)*k | |
| * fits into a long long (which is at least 64 bit). Only contains | |
| * items larger than in fast_comb_limits1. */ | |
| static const unsigned long long fast_comb_limits2[] = { | |
| 0, ULLONG_MAX, 4294967296ULL, 3329022, 102570, 13467, 3612, 1449, // 0-7 | |
| 746, 453, 308, 227, 178, 147, // 8-13 | |
| }; | |
| if (k < Py_ARRAY_LENGTH(fast_comb_limits2) && n <= fast_comb_limits2[k]) { | |
| /* C(n, k) = C(n, k-1) * (n-k+1) / k */ | |
| unsigned long long result = n; | |
| for (unsigned long long i = 1; i < k;) { | |
| result *= --n; | |
| result /= ++i; | |
| } | |
| return PyLong_FromUnsignedLongLong(result); | |
| } | |
| } | |
| else { | |
| /* Maps k to the maximal n so that k <= n and P(n, k) | |
| * fits into a long long (which is at least 64 bit). */ | |
| static const unsigned long long fast_perm_limits[] = { | |
| 0, ULLONG_MAX, 4294967296ULL, 2642246, 65537, 7133, 1627, 568, // 0-7 | |
| 259, 142, 88, 61, 45, 36, 30, 26, // 8-15 | |
| 24, 22, 21, 20, 20, // 16-20 | |
| }; | |
| if (k < Py_ARRAY_LENGTH(fast_perm_limits) && n <= fast_perm_limits[k]) { | |
| if (n <= 127) { | |
| /* P(n, k) fits into a uint64_t. */ | |
| uint64_t perm_odd_part = reduced_factorial_odd_part[n] | |
| * inverted_factorial_odd_part[n - k]; | |
| int shift = factorial_trailing_zeros[n] | |
| - factorial_trailing_zeros[n - k]; | |
| return PyLong_FromUnsignedLongLong(perm_odd_part << shift); | |
| } | |
| /* P(n, k) = P(n, k-1) * (n-k+1) */ | |
| unsigned long long result = n; | |
| for (unsigned long long i = 1; i < k;) { | |
| result *= --n; | |
| ++i; | |
| } | |
| return PyLong_FromUnsignedLongLong(result); | |
| } | |
| } | |
| /* For larger n use recursive formulas: | |
| * | |
| * P(n, k) = P(n, j) * P(n-j, k-j) | |
| * C(n, k) = C(n, j) * C(n-j, k-j) // C(k, j) | |
| */ | |
| unsigned long long j = k / 2; | |
| PyObject *a, *b; | |
| a = perm_comb_small(n, j, iscomb); | |
| if (a == NULL) { | |
| return NULL; | |
| } | |
| b = perm_comb_small(n - j, k - j, iscomb); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| Py_SETREF(a, PyNumber_Multiply(a, b)); | |
| Py_DECREF(b); | |
| if (iscomb && a != NULL) { | |
| b = perm_comb_small(k, j, 1); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| Py_SETREF(a, PyNumber_FloorDivide(a, b)); | |
| Py_DECREF(b); | |
| } | |
| return a; | |
| error: | |
| Py_DECREF(a); | |
| return NULL; | |
| } | |
| /* Calculate P(n, k) or C(n, k) using recursive formulas. | |
| * It is more efficient than sequential multiplication thanks to | |
| * Karatsuba multiplication. | |
| */ | |
| static PyObject * | |
| perm_comb(PyObject *n, unsigned long long k, int iscomb) | |
| { | |
| if (k == 0) { | |
| return PyLong_FromLong(1); | |
| } | |
| if (k == 1) { | |
| return Py_NewRef(n); | |
| } | |
| /* P(n, k) = P(n, j) * P(n-j, k-j) */ | |
| /* C(n, k) = C(n, j) * C(n-j, k-j) // C(k, j) */ | |
| unsigned long long j = k / 2; | |
| PyObject *a, *b; | |
| a = perm_comb(n, j, iscomb); | |
| if (a == NULL) { | |
| return NULL; | |
| } | |
| PyObject *t = PyLong_FromUnsignedLongLong(j); | |
| if (t == NULL) { | |
| goto error; | |
| } | |
| n = PyNumber_Subtract(n, t); | |
| Py_DECREF(t); | |
| if (n == NULL) { | |
| goto error; | |
| } | |
| b = perm_comb(n, k - j, iscomb); | |
| Py_DECREF(n); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| Py_SETREF(a, PyNumber_Multiply(a, b)); | |
| Py_DECREF(b); | |
| if (iscomb && a != NULL) { | |
| b = perm_comb_small(k, j, 1); | |
| if (b == NULL) { | |
| goto error; | |
| } | |
| Py_SETREF(a, PyNumber_FloorDivide(a, b)); | |
| Py_DECREF(b); | |
| } | |
| return a; | |
| error: | |
| Py_DECREF(a); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| @permit_long_summary | |
| math.integer.perm | |
| n: object | |
| k: object = None | |
| / | |
| Number of ways to choose k items from n items without repetition and with order. | |
| Evaluates to n! / (n - k)! when k <= n and evaluates | |
| to zero when k > n. | |
| If k is not specified or is None, then k defaults to n | |
| and the function returns n!. | |
| Raises ValueError if either of the arguments are negative. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_perm_impl(PyObject *module, PyObject *n, PyObject *k) | |
| /*[clinic end generated code: output=9f9b96cd73a94de4 input=fd627e5a09dd5116]*/ | |
| { | |
| PyObject *result = NULL; | |
| int overflow, cmp; | |
| long long ki, ni; | |
| if (k == Py_None) { | |
| return math_integer_factorial(module, n); | |
| } | |
| n = PyNumber_Index(n); | |
| if (n == NULL) { | |
| return NULL; | |
| } | |
| k = PyNumber_Index(k); | |
| if (k == NULL) { | |
| Py_DECREF(n); | |
| return NULL; | |
| } | |
| assert(PyLong_CheckExact(n) && PyLong_CheckExact(k)); | |
| if (_PyLong_IsNegative((PyLongObject *)n)) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "n must be a non-negative integer"); | |
| goto error; | |
| } | |
| if (_PyLong_IsNegative((PyLongObject *)k)) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "k must be a non-negative integer"); | |
| goto error; | |
| } | |
| cmp = PyObject_RichCompareBool(n, k, Py_LT); | |
| if (cmp != 0) { | |
| if (cmp > 0) { | |
| result = PyLong_FromLong(0); | |
| goto done; | |
| } | |
| goto error; | |
| } | |
| ki = PyLong_AsLongLongAndOverflow(k, &overflow); | |
| assert(overflow >= 0 && !PyErr_Occurred()); | |
| if (overflow > 0) { | |
| PyErr_Format(PyExc_OverflowError, | |
| "k must not exceed %lld", | |
| LLONG_MAX); | |
| goto error; | |
| } | |
| assert(ki >= 0); | |
| ni = PyLong_AsLongLongAndOverflow(n, &overflow); | |
| assert(overflow >= 0 && !PyErr_Occurred()); | |
| if (!overflow && ki > 1) { | |
| assert(ni >= 0); | |
| result = perm_comb_small((unsigned long long)ni, | |
| (unsigned long long)ki, 0); | |
| } | |
| else { | |
| result = perm_comb(n, (unsigned long long)ki, 0); | |
| } | |
| done: | |
| Py_DECREF(n); | |
| Py_DECREF(k); | |
| return result; | |
| error: | |
| Py_DECREF(n); | |
| Py_DECREF(k); | |
| return NULL; | |
| } | |
| /*[clinic input] | |
| @permit_long_summary | |
| math.integer.comb | |
| n: object | |
| k: object | |
| / | |
| Number of ways to choose k items from n items without repetition and without order. | |
| Evaluates to n! / (k! * (n - k)!) when k <= n and evaluates | |
| to zero when k > n. | |
| Also called the binomial coefficient because it is equivalent | |
| to the coefficient of k-th term in polynomial expansion of the | |
| expression (1 + x)**n. | |
| Raises ValueError if either of the arguments are negative. | |
| [clinic start generated code]*/ | |
| static PyObject * | |
| math_integer_comb_impl(PyObject *module, PyObject *n, PyObject *k) | |
| /*[clinic end generated code: output=c2c9cdfe0d5dd43f input=8cc12726b682c4a5]*/ | |
| { | |
| PyObject *result = NULL, *temp; | |
| int overflow, cmp; | |
| long long ki, ni; | |
| n = PyNumber_Index(n); | |
| if (n == NULL) { | |
| return NULL; | |
| } | |
| k = PyNumber_Index(k); | |
| if (k == NULL) { | |
| Py_DECREF(n); | |
| return NULL; | |
| } | |
| assert(PyLong_CheckExact(n) && PyLong_CheckExact(k)); | |
| if (_PyLong_IsNegative((PyLongObject *)n)) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "n must be a non-negative integer"); | |
| goto error; | |
| } | |
| if (_PyLong_IsNegative((PyLongObject *)k)) { | |
| PyErr_SetString(PyExc_ValueError, | |
| "k must be a non-negative integer"); | |
| goto error; | |
| } | |
| ni = PyLong_AsLongLongAndOverflow(n, &overflow); | |
| assert(overflow >= 0 && !PyErr_Occurred()); | |
| if (!overflow) { | |
| assert(ni >= 0); | |
| ki = PyLong_AsLongLongAndOverflow(k, &overflow); | |
| assert(overflow >= 0 && !PyErr_Occurred()); | |
| if (overflow || ki > ni) { | |
| result = PyLong_FromLong(0); | |
| goto done; | |
| } | |
| assert(ki >= 0); | |
| ki = Py_MIN(ki, ni - ki); | |
| if (ki > 1) { | |
| result = perm_comb_small((unsigned long long)ni, | |
| (unsigned long long)ki, 1); | |
| goto done; | |
| } | |
| /* For k == 1 just return the original n in perm_comb(). */ | |
| } | |
| else { | |
| /* k = min(k, n - k) */ | |
| temp = PyNumber_Subtract(n, k); | |
| if (temp == NULL) { | |
| goto error; | |
| } | |
| assert(PyLong_Check(temp)); | |
| if (_PyLong_IsNegative((PyLongObject *)temp)) { | |
| Py_DECREF(temp); | |
| result = PyLong_FromLong(0); | |
| goto done; | |
| } | |
| cmp = PyObject_RichCompareBool(temp, k, Py_LT); | |
| if (cmp > 0) { | |
| Py_SETREF(k, temp); | |
| } | |
| else { | |
| Py_DECREF(temp); | |
| if (cmp < 0) { | |
| goto error; | |
| } | |
| } | |
| ki = PyLong_AsLongLongAndOverflow(k, &overflow); | |
| assert(overflow >= 0 && !PyErr_Occurred()); | |
| if (overflow) { | |
| PyErr_Format(PyExc_OverflowError, | |
| "min(n - k, k) must not exceed %lld", | |
| LLONG_MAX); | |
| goto error; | |
| } | |
| assert(ki >= 0); | |
| } | |
| result = perm_comb(n, (unsigned long long)ki, 1); | |
| done: | |
| Py_DECREF(n); | |
| Py_DECREF(k); | |
| return result; | |
| error: | |
| Py_DECREF(n); | |
| Py_DECREF(k); | |
| return NULL; | |
| } | |
| static PyMethodDef math_integer_methods[] = { | |
| MATH_INTEGER_COMB_METHODDEF | |
| MATH_INTEGER_FACTORIAL_METHODDEF | |
| MATH_INTEGER_GCD_METHODDEF | |
| MATH_INTEGER_ISQRT_METHODDEF | |
| MATH_INTEGER_LCM_METHODDEF | |
| MATH_INTEGER_PERM_METHODDEF | |
| {NULL, NULL} /* sentinel */ | |
| }; | |
| static int | |
| math_integer_exec(PyObject *module) | |
| { | |
| /* Fix the __name__ attribute of the module and the __module__ attribute | |
| * of its functions. | |
| */ | |
| PyObject *name = PyUnicode_FromString("math.integer"); | |
| if (name == NULL) { | |
| return -1; | |
| } | |
| if (PyObject_SetAttrString(module, "__name__", name) < 0) { | |
| Py_DECREF(name); | |
| return -1; | |
| } | |
| for (const PyMethodDef *m = math_integer_methods; m->ml_name; m++) { | |
| PyObject *obj = PyObject_GetAttrString(module, m->ml_name); | |
| if (obj == NULL) { | |
| Py_DECREF(name); | |
| return -1; | |
| } | |
| if (PyObject_SetAttrString(obj, "__module__", name) < 0) { | |
| Py_DECREF(name); | |
| Py_DECREF(obj); | |
| return -1; | |
| } | |
| Py_DECREF(obj); | |
| } | |
| Py_DECREF(name); | |
| return 0; | |
| } | |
| static PyModuleDef_Slot math_integer_slots[] = { | |
| {Py_mod_exec, math_integer_exec}, | |
| {Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| PyDoc_STRVAR(module_doc, | |
| "This module provides access to integer related mathematical functions."); | |
| static struct PyModuleDef math_integer_module = { | |
| PyModuleDef_HEAD_INIT, | |
| .m_name = "math.integer", | |
| .m_doc = module_doc, | |
| .m_size = 0, | |
| .m_methods = math_integer_methods, | |
| .m_slots = math_integer_slots, | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit__math_integer(void) | |
| { | |
| return PyModuleDef_Init(&math_integer_module); | |
| } | |
| /* | |
| * Helper method for urllib to fetch the proxy configuration settings | |
| * using the SystemConfiguration framework. | |
| */ | |
| // Need limited C API version 3.13 for Py_mod_gil | |
| #include "pyconfig.h" // Py_GIL_DISABLED | |
| #ifndef Py_GIL_DISABLED | |
| # define Py_LIMITED_API 0x030d0000 | |
| #endif | |
| #include <Python.h> | |
| #include <SystemConfiguration/SystemConfiguration.h> | |
| static int32_t | |
| cfnum_to_int32(CFNumberRef num) | |
| { | |
| int32_t result; | |
| CFNumberGetValue(num, kCFNumberSInt32Type, &result); | |
| return result; | |
| } | |
| static PyObject* | |
| cfstring_to_pystring(CFStringRef ref) | |
| { | |
| const char* s; | |
| s = CFStringGetCStringPtr(ref, kCFStringEncodingUTF8); | |
| if (s) { | |
| return PyUnicode_DecodeUTF8(s, strlen(s), NULL); | |
| } else { | |
| CFIndex len = CFStringGetLength(ref); | |
| Boolean ok; | |
| PyObject* result; | |
| char* buf; | |
| buf = PyMem_Malloc(len*4); | |
| if (buf == NULL) { | |
| PyErr_NoMemory(); | |
| return NULL; | |
| } | |
| ok = CFStringGetCString(ref, | |
| buf, len * 4, | |
| kCFStringEncodingUTF8); | |
| if (!ok) { | |
| PyMem_Free(buf); | |
| return NULL; | |
| } else { | |
| result = PyUnicode_DecodeUTF8(buf, strlen(buf), NULL); | |
| PyMem_Free(buf); | |
| } | |
| return result; | |
| } | |
| } | |
| static PyObject* | |
| get_proxy_settings(PyObject* Py_UNUSED(mod), PyObject *Py_UNUSED(ignored)) | |
| { | |
| CFDictionaryRef proxyDict = NULL; | |
| CFNumberRef aNum = NULL; | |
| CFArrayRef anArray = NULL; | |
| PyObject* result = NULL; | |
| PyObject* v; | |
| int r; | |
| Py_BEGIN_ALLOW_THREADS | |
| proxyDict = SCDynamicStoreCopyProxies(NULL); | |
| Py_END_ALLOW_THREADS | |
| if (!proxyDict) { | |
| Py_RETURN_NONE; | |
| } | |
| result = PyDict_New(); | |
| if (result == NULL) goto error; | |
| aNum = CFDictionaryGetValue(proxyDict, | |
| kSCPropNetProxiesExcludeSimpleHostnames); | |
| if (aNum == NULL) { | |
| v = PyBool_FromLong(0); | |
| } else { | |
| v = PyBool_FromLong(cfnum_to_int32(aNum)); | |
| } | |
| if (v == NULL) goto error; | |
| r = PyDict_SetItemString(result, "exclude_simple", v); | |
| Py_CLEAR(v); | |
| if (r == -1) goto error; | |
| anArray = CFDictionaryGetValue(proxyDict, | |
| kSCPropNetProxiesExceptionsList); | |
| if (anArray != NULL) { | |
| CFIndex len = CFArrayGetCount(anArray); | |
| CFIndex i; | |
| v = PyTuple_New(len); | |
| if (v == NULL) goto error; | |
| r = PyDict_SetItemString(result, "exceptions", v); | |
| Py_DECREF(v); | |
| if (r == -1) goto error; | |
| for (i = 0; i < len; i++) { | |
| CFStringRef aString = NULL; | |
| aString = CFArrayGetValueAtIndex(anArray, i); | |
| if (aString == NULL) { | |
| PyTuple_SetItem(v, i, Py_NewRef(Py_None)); | |
| } else { | |
| PyObject* t = cfstring_to_pystring(aString); | |
| if (!t) { | |
| PyTuple_SetItem(v, i, Py_NewRef(Py_None)); | |
| } else { | |
| PyTuple_SetItem(v, i, t); | |
| } | |
| } | |
| } | |
| } | |
| CFRelease(proxyDict); | |
| return result; | |
| error: | |
| if (proxyDict) CFRelease(proxyDict); | |
| Py_XDECREF(result); | |
| return NULL; | |
| } | |
| static int | |
| set_proxy(PyObject* proxies, const char* proto, CFDictionaryRef proxyDict, | |
| CFStringRef enabledKey, | |
| CFStringRef hostKey, CFStringRef portKey) | |
| { | |
| CFNumberRef aNum; | |
| aNum = CFDictionaryGetValue(proxyDict, enabledKey); | |
| if (aNum && cfnum_to_int32(aNum)) { | |
| CFStringRef hostString; | |
| hostString = CFDictionaryGetValue(proxyDict, hostKey); | |
| aNum = CFDictionaryGetValue(proxyDict, portKey); | |
| if (hostString) { | |
| int r; | |
| PyObject* h = cfstring_to_pystring(hostString); | |
| PyObject* v; | |
| if (h) { | |
| if (aNum) { | |
| int32_t port = cfnum_to_int32(aNum); | |
| v = PyUnicode_FromFormat("http://%U:%ld", h, (long)port); | |
| } else { | |
| v = PyUnicode_FromFormat("http://%U", h); | |
| } | |
| Py_DECREF(h); | |
| if (!v) return -1; | |
| r = PyDict_SetItemString(proxies, proto, v); | |
| Py_DECREF(v); | |
| return r; | |
| } | |
| } | |
| } | |
| return 0; | |
| } | |
| static PyObject* | |
| get_proxies(PyObject* Py_UNUSED(mod), PyObject *Py_UNUSED(ignored)) | |
| { | |
| PyObject* result = NULL; | |
| int r; | |
| CFDictionaryRef proxyDict = NULL; | |
| Py_BEGIN_ALLOW_THREADS | |
| proxyDict = SCDynamicStoreCopyProxies(NULL); | |
| Py_END_ALLOW_THREADS | |
| if (proxyDict == NULL) { | |
| return PyDict_New(); | |
| } | |
| result = PyDict_New(); | |
| if (result == NULL) goto error; | |
| r = set_proxy(result, "http", proxyDict, | |
| kSCPropNetProxiesHTTPEnable, | |
| kSCPropNetProxiesHTTPProxy, | |
| kSCPropNetProxiesHTTPPort); | |
| if (r == -1) goto error; | |
| r = set_proxy(result, "https", proxyDict, | |
| kSCPropNetProxiesHTTPSEnable, | |
| kSCPropNetProxiesHTTPSProxy, | |
| kSCPropNetProxiesHTTPSPort); | |
| if (r == -1) goto error; | |
| r = set_proxy(result, "ftp", proxyDict, | |
| kSCPropNetProxiesFTPEnable, | |
| kSCPropNetProxiesFTPProxy, | |
| kSCPropNetProxiesFTPPort); | |
| if (r == -1) goto error; | |
| r = set_proxy(result, "gopher", proxyDict, | |
| kSCPropNetProxiesGopherEnable, | |
| kSCPropNetProxiesGopherProxy, | |
| kSCPropNetProxiesGopherPort); | |
| if (r == -1) goto error; | |
| r = set_proxy(result, "socks", proxyDict, | |
| kSCPropNetProxiesSOCKSEnable, | |
| kSCPropNetProxiesSOCKSProxy, | |
| kSCPropNetProxiesSOCKSPort); | |
| if (r == -1) goto error; | |
| CFRelease(proxyDict); | |
| return result; | |
| error: | |
| if (proxyDict) CFRelease(proxyDict); | |
| Py_XDECREF(result); | |
| return NULL; | |
| } | |
| static PyMethodDef mod_methods[] = { | |
| { | |
| "_get_proxy_settings", | |
| get_proxy_settings, | |
| METH_NOARGS, | |
| NULL, | |
| }, | |
| { | |
| "_get_proxies", | |
| get_proxies, | |
| METH_NOARGS, | |
| NULL, | |
| }, | |
| { 0, 0, 0, 0 } | |
| }; | |
| static PyModuleDef_Slot _scproxy_slots[] = { | |
| {Py_mod_multiple_interpreters, Py_MOD_PER_INTERPRETER_GIL_SUPPORTED}, | |
| {Py_mod_gil, Py_MOD_GIL_NOT_USED}, | |
| {0, NULL} | |
| }; | |
| static struct PyModuleDef _scproxy_module = { | |
| PyModuleDef_HEAD_INIT, | |
| .m_name = "_scproxy", | |
| .m_size = 0, | |
| .m_methods = mod_methods, | |
| .m_slots = _scproxy_slots, | |
| }; | |
| PyMODINIT_FUNC | |
| PyInit__scproxy(void) | |
| { | |
| return PyModuleDef_Init(&_scproxy_module); | |
| } | |
| """ | |