diff options
Diffstat (limited to 'src/lib/libcrypto/engine/engine.h')
-rw-r--r-- | src/lib/libcrypto/engine/engine.h | 55 |
1 files changed, 42 insertions, 13 deletions
diff --git a/src/lib/libcrypto/engine/engine.h b/src/lib/libcrypto/engine/engine.h index f503595ece..7fbd95f634 100644 --- a/src/lib/libcrypto/engine/engine.h +++ b/src/lib/libcrypto/engine/engine.h | |||
@@ -88,16 +88,15 @@ | |||
88 | #include <openssl/ecdsa.h> | 88 | #include <openssl/ecdsa.h> |
89 | #endif | 89 | #endif |
90 | #include <openssl/rand.h> | 90 | #include <openssl/rand.h> |
91 | #include <openssl/store.h> | ||
92 | #include <openssl/ui.h> | 91 | #include <openssl/ui.h> |
93 | #include <openssl/err.h> | 92 | #include <openssl/err.h> |
94 | #endif | 93 | #endif |
95 | 94 | ||
96 | #include <openssl/x509.h> | ||
97 | |||
98 | #include <openssl/ossl_typ.h> | 95 | #include <openssl/ossl_typ.h> |
99 | #include <openssl/symhacks.h> | 96 | #include <openssl/symhacks.h> |
100 | 97 | ||
98 | #include <openssl/x509.h> | ||
99 | |||
101 | #ifdef __cplusplus | 100 | #ifdef __cplusplus |
102 | extern "C" { | 101 | extern "C" { |
103 | #endif | 102 | #endif |
@@ -113,6 +112,8 @@ extern "C" { | |||
113 | #define ENGINE_METHOD_CIPHERS (unsigned int)0x0040 | 112 | #define ENGINE_METHOD_CIPHERS (unsigned int)0x0040 |
114 | #define ENGINE_METHOD_DIGESTS (unsigned int)0x0080 | 113 | #define ENGINE_METHOD_DIGESTS (unsigned int)0x0080 |
115 | #define ENGINE_METHOD_STORE (unsigned int)0x0100 | 114 | #define ENGINE_METHOD_STORE (unsigned int)0x0100 |
115 | #define ENGINE_METHOD_PKEY_METHS (unsigned int)0x0200 | ||
116 | #define ENGINE_METHOD_PKEY_ASN1_METHS (unsigned int)0x0400 | ||
116 | /* Obvious all-or-nothing cases. */ | 117 | /* Obvious all-or-nothing cases. */ |
117 | #define ENGINE_METHOD_ALL (unsigned int)0xFFFF | 118 | #define ENGINE_METHOD_ALL (unsigned int)0xFFFF |
118 | #define ENGINE_METHOD_NONE (unsigned int)0x0000 | 119 | #define ENGINE_METHOD_NONE (unsigned int)0x0000 |
@@ -297,7 +298,8 @@ typedef int (*ENGINE_SSL_CLIENT_CERT_PTR)(ENGINE *, SSL *ssl, | |||
297 | * parameter is non-NULL it is set to the size of the returned array. */ | 298 | * parameter is non-NULL it is set to the size of the returned array. */ |
298 | typedef int (*ENGINE_CIPHERS_PTR)(ENGINE *, const EVP_CIPHER **, const int **, int); | 299 | typedef int (*ENGINE_CIPHERS_PTR)(ENGINE *, const EVP_CIPHER **, const int **, int); |
299 | typedef int (*ENGINE_DIGESTS_PTR)(ENGINE *, const EVP_MD **, const int **, int); | 300 | typedef int (*ENGINE_DIGESTS_PTR)(ENGINE *, const EVP_MD **, const int **, int); |
300 | 301 | typedef int (*ENGINE_PKEY_METHS_PTR)(ENGINE *, EVP_PKEY_METHOD **, const int **, int); | |
302 | typedef int (*ENGINE_PKEY_ASN1_METHS_PTR)(ENGINE *, EVP_PKEY_ASN1_METHOD **, const int **, int); | ||
301 | /* STRUCTURE functions ... all of these functions deal with pointers to ENGINE | 303 | /* STRUCTURE functions ... all of these functions deal with pointers to ENGINE |
302 | * structures where the pointers have a "structural reference". This means that | 304 | * structures where the pointers have a "structural reference". This means that |
303 | * their reference is to allowed access to the structure but it does not imply | 305 | * their reference is to allowed access to the structure but it does not imply |
@@ -329,19 +331,20 @@ void ENGINE_load_aep(void); | |||
329 | void ENGINE_load_atalla(void); | 331 | void ENGINE_load_atalla(void); |
330 | void ENGINE_load_chil(void); | 332 | void ENGINE_load_chil(void); |
331 | void ENGINE_load_cswift(void); | 333 | void ENGINE_load_cswift(void); |
332 | #ifndef OPENSSL_NO_GMP | ||
333 | void ENGINE_load_gmp(void); | ||
334 | #endif | ||
335 | void ENGINE_load_nuron(void); | 334 | void ENGINE_load_nuron(void); |
336 | void ENGINE_load_sureware(void); | 335 | void ENGINE_load_sureware(void); |
337 | void ENGINE_load_ubsec(void); | 336 | void ENGINE_load_ubsec(void); |
338 | #endif | ||
339 | void ENGINE_load_cryptodev(void); | ||
340 | void ENGINE_load_padlock(void); | 337 | void ENGINE_load_padlock(void); |
341 | void ENGINE_load_builtin_engines(void); | ||
342 | #ifndef OPENSSL_NO_CAPIENG | ||
343 | void ENGINE_load_capi(void); | 338 | void ENGINE_load_capi(void); |
339 | #ifndef OPENSSL_NO_GMP | ||
340 | void ENGINE_load_gmp(void); | ||
341 | #endif | ||
342 | #ifndef OPENSSL_NO_GOST | ||
343 | void ENGINE_load_gost(void); | ||
344 | #endif | ||
344 | #endif | 345 | #endif |
346 | void ENGINE_load_cryptodev(void); | ||
347 | void ENGINE_load_builtin_engines(void); | ||
345 | 348 | ||
346 | /* Get and set global flags (ENGINE_TABLE_FLAG_***) for the implementation | 349 | /* Get and set global flags (ENGINE_TABLE_FLAG_***) for the implementation |
347 | * "registry" handling. */ | 350 | * "registry" handling. */ |
@@ -392,6 +395,14 @@ int ENGINE_register_digests(ENGINE *e); | |||
392 | void ENGINE_unregister_digests(ENGINE *e); | 395 | void ENGINE_unregister_digests(ENGINE *e); |
393 | void ENGINE_register_all_digests(void); | 396 | void ENGINE_register_all_digests(void); |
394 | 397 | ||
398 | int ENGINE_register_pkey_meths(ENGINE *e); | ||
399 | void ENGINE_unregister_pkey_meths(ENGINE *e); | ||
400 | void ENGINE_register_all_pkey_meths(void); | ||
401 | |||
402 | int ENGINE_register_pkey_asn1_meths(ENGINE *e); | ||
403 | void ENGINE_unregister_pkey_asn1_meths(ENGINE *e); | ||
404 | void ENGINE_register_all_pkey_asn1_meths(void); | ||
405 | |||
395 | /* These functions register all support from the above categories. Note, use of | 406 | /* These functions register all support from the above categories. Note, use of |
396 | * these functions can result in static linkage of code your application may not | 407 | * these functions can result in static linkage of code your application may not |
397 | * need. If you only need a subset of functionality, consider using more | 408 | * need. If you only need a subset of functionality, consider using more |
@@ -471,6 +482,8 @@ int ENGINE_set_load_ssl_client_cert_function(ENGINE *e, | |||
471 | ENGINE_SSL_CLIENT_CERT_PTR loadssl_f); | 482 | ENGINE_SSL_CLIENT_CERT_PTR loadssl_f); |
472 | int ENGINE_set_ciphers(ENGINE *e, ENGINE_CIPHERS_PTR f); | 483 | int ENGINE_set_ciphers(ENGINE *e, ENGINE_CIPHERS_PTR f); |
473 | int ENGINE_set_digests(ENGINE *e, ENGINE_DIGESTS_PTR f); | 484 | int ENGINE_set_digests(ENGINE *e, ENGINE_DIGESTS_PTR f); |
485 | int ENGINE_set_pkey_meths(ENGINE *e, ENGINE_PKEY_METHS_PTR f); | ||
486 | int ENGINE_set_pkey_asn1_meths(ENGINE *e, ENGINE_PKEY_ASN1_METHS_PTR f); | ||
474 | int ENGINE_set_flags(ENGINE *e, int flags); | 487 | int ENGINE_set_flags(ENGINE *e, int flags); |
475 | int ENGINE_set_cmd_defns(ENGINE *e, const ENGINE_CMD_DEFN *defns); | 488 | int ENGINE_set_cmd_defns(ENGINE *e, const ENGINE_CMD_DEFN *defns); |
476 | /* These functions allow control over any per-structure ENGINE data. */ | 489 | /* These functions allow control over any per-structure ENGINE data. */ |
@@ -507,8 +520,16 @@ ENGINE_LOAD_KEY_PTR ENGINE_get_load_pubkey_function(const ENGINE *e); | |||
507 | ENGINE_SSL_CLIENT_CERT_PTR ENGINE_get_ssl_client_cert_function(const ENGINE *e); | 520 | ENGINE_SSL_CLIENT_CERT_PTR ENGINE_get_ssl_client_cert_function(const ENGINE *e); |
508 | ENGINE_CIPHERS_PTR ENGINE_get_ciphers(const ENGINE *e); | 521 | ENGINE_CIPHERS_PTR ENGINE_get_ciphers(const ENGINE *e); |
509 | ENGINE_DIGESTS_PTR ENGINE_get_digests(const ENGINE *e); | 522 | ENGINE_DIGESTS_PTR ENGINE_get_digests(const ENGINE *e); |
523 | ENGINE_PKEY_METHS_PTR ENGINE_get_pkey_meths(const ENGINE *e); | ||
524 | ENGINE_PKEY_ASN1_METHS_PTR ENGINE_get_pkey_asn1_meths(const ENGINE *e); | ||
510 | const EVP_CIPHER *ENGINE_get_cipher(ENGINE *e, int nid); | 525 | const EVP_CIPHER *ENGINE_get_cipher(ENGINE *e, int nid); |
511 | const EVP_MD *ENGINE_get_digest(ENGINE *e, int nid); | 526 | const EVP_MD *ENGINE_get_digest(ENGINE *e, int nid); |
527 | const EVP_PKEY_METHOD *ENGINE_get_pkey_meth(ENGINE *e, int nid); | ||
528 | const EVP_PKEY_ASN1_METHOD *ENGINE_get_pkey_asn1_meth(ENGINE *e, int nid); | ||
529 | const EVP_PKEY_ASN1_METHOD *ENGINE_get_pkey_asn1_meth_str(ENGINE *e, | ||
530 | const char *str, int len); | ||
531 | const EVP_PKEY_ASN1_METHOD *ENGINE_pkey_asn1_find_str(ENGINE **pe, | ||
532 | const char *str, int len); | ||
512 | const ENGINE_CMD_DEFN *ENGINE_get_cmd_defns(const ENGINE *e); | 533 | const ENGINE_CMD_DEFN *ENGINE_get_cmd_defns(const ENGINE *e); |
513 | int ENGINE_get_flags(const ENGINE *e); | 534 | int ENGINE_get_flags(const ENGINE *e); |
514 | 535 | ||
@@ -560,6 +581,8 @@ ENGINE *ENGINE_get_default_RAND(void); | |||
560 | * ciphering or digesting corresponding to "nid". */ | 581 | * ciphering or digesting corresponding to "nid". */ |
561 | ENGINE *ENGINE_get_cipher_engine(int nid); | 582 | ENGINE *ENGINE_get_cipher_engine(int nid); |
562 | ENGINE *ENGINE_get_digest_engine(int nid); | 583 | ENGINE *ENGINE_get_digest_engine(int nid); |
584 | ENGINE *ENGINE_get_pkey_meth_engine(int nid); | ||
585 | ENGINE *ENGINE_get_pkey_asn1_meth_engine(int nid); | ||
563 | 586 | ||
564 | /* This sets a new default ENGINE structure for performing RSA | 587 | /* This sets a new default ENGINE structure for performing RSA |
565 | * operations. If the result is non-zero (success) then the ENGINE | 588 | * operations. If the result is non-zero (success) then the ENGINE |
@@ -575,6 +598,8 @@ int ENGINE_set_default_DH(ENGINE *e); | |||
575 | int ENGINE_set_default_RAND(ENGINE *e); | 598 | int ENGINE_set_default_RAND(ENGINE *e); |
576 | int ENGINE_set_default_ciphers(ENGINE *e); | 599 | int ENGINE_set_default_ciphers(ENGINE *e); |
577 | int ENGINE_set_default_digests(ENGINE *e); | 600 | int ENGINE_set_default_digests(ENGINE *e); |
601 | int ENGINE_set_default_pkey_meths(ENGINE *e); | ||
602 | int ENGINE_set_default_pkey_asn1_meths(ENGINE *e); | ||
578 | 603 | ||
579 | /* The combination "set" - the flags are bitwise "OR"d from the | 604 | /* The combination "set" - the flags are bitwise "OR"d from the |
580 | * ENGINE_METHOD_*** defines above. As with the "ENGINE_register_complete()" | 605 | * ENGINE_METHOD_*** defines above. As with the "ENGINE_register_complete()" |
@@ -703,7 +728,7 @@ typedef int (*dynamic_bind_engine)(ENGINE *e, const char *id, | |||
703 | * values. */ | 728 | * values. */ |
704 | void *ENGINE_get_static_state(void); | 729 | void *ENGINE_get_static_state(void); |
705 | 730 | ||
706 | #if defined(__OpenBSD__) || defined(__FreeBSD__) | 731 | #if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV) |
707 | void ENGINE_setup_bsd_cryptodev(void); | 732 | void ENGINE_setup_bsd_cryptodev(void); |
708 | #endif | 733 | #endif |
709 | 734 | ||
@@ -732,13 +757,15 @@ void ERR_load_ENGINE_strings(void); | |||
732 | #define ENGINE_F_ENGINE_GET_DEFAULT_TYPE 177 | 757 | #define ENGINE_F_ENGINE_GET_DEFAULT_TYPE 177 |
733 | #define ENGINE_F_ENGINE_GET_DIGEST 186 | 758 | #define ENGINE_F_ENGINE_GET_DIGEST 186 |
734 | #define ENGINE_F_ENGINE_GET_NEXT 115 | 759 | #define ENGINE_F_ENGINE_GET_NEXT 115 |
760 | #define ENGINE_F_ENGINE_GET_PKEY_ASN1_METH 193 | ||
761 | #define ENGINE_F_ENGINE_GET_PKEY_METH 192 | ||
735 | #define ENGINE_F_ENGINE_GET_PREV 116 | 762 | #define ENGINE_F_ENGINE_GET_PREV 116 |
736 | #define ENGINE_F_ENGINE_INIT 119 | 763 | #define ENGINE_F_ENGINE_INIT 119 |
737 | #define ENGINE_F_ENGINE_LIST_ADD 120 | 764 | #define ENGINE_F_ENGINE_LIST_ADD 120 |
738 | #define ENGINE_F_ENGINE_LIST_REMOVE 121 | 765 | #define ENGINE_F_ENGINE_LIST_REMOVE 121 |
739 | #define ENGINE_F_ENGINE_LOAD_PRIVATE_KEY 150 | 766 | #define ENGINE_F_ENGINE_LOAD_PRIVATE_KEY 150 |
740 | #define ENGINE_F_ENGINE_LOAD_PUBLIC_KEY 151 | 767 | #define ENGINE_F_ENGINE_LOAD_PUBLIC_KEY 151 |
741 | #define ENGINE_F_ENGINE_LOAD_SSL_CLIENT_CERT 192 | 768 | #define ENGINE_F_ENGINE_LOAD_SSL_CLIENT_CERT 194 |
742 | #define ENGINE_F_ENGINE_NEW 122 | 769 | #define ENGINE_F_ENGINE_NEW 122 |
743 | #define ENGINE_F_ENGINE_REMOVE 123 | 770 | #define ENGINE_F_ENGINE_REMOVE 123 |
744 | #define ENGINE_F_ENGINE_SET_DEFAULT_STRING 189 | 771 | #define ENGINE_F_ENGINE_SET_DEFAULT_STRING 189 |
@@ -767,6 +794,7 @@ void ERR_load_ENGINE_strings(void); | |||
767 | #define ENGINE_R_DSO_FAILURE 104 | 794 | #define ENGINE_R_DSO_FAILURE 104 |
768 | #define ENGINE_R_DSO_NOT_FOUND 132 | 795 | #define ENGINE_R_DSO_NOT_FOUND 132 |
769 | #define ENGINE_R_ENGINES_SECTION_ERROR 148 | 796 | #define ENGINE_R_ENGINES_SECTION_ERROR 148 |
797 | #define ENGINE_R_ENGINE_CONFIGURATION_ERROR 102 | ||
770 | #define ENGINE_R_ENGINE_IS_NOT_IN_LIST 105 | 798 | #define ENGINE_R_ENGINE_IS_NOT_IN_LIST 105 |
771 | #define ENGINE_R_ENGINE_SECTION_ERROR 149 | 799 | #define ENGINE_R_ENGINE_SECTION_ERROR 149 |
772 | #define ENGINE_R_FAILED_LOADING_PRIVATE_KEY 128 | 800 | #define ENGINE_R_FAILED_LOADING_PRIVATE_KEY 128 |
@@ -793,6 +821,7 @@ void ERR_load_ENGINE_strings(void); | |||
793 | #define ENGINE_R_RSA_NOT_IMPLEMENTED 141 | 821 | #define ENGINE_R_RSA_NOT_IMPLEMENTED 141 |
794 | #define ENGINE_R_UNIMPLEMENTED_CIPHER 146 | 822 | #define ENGINE_R_UNIMPLEMENTED_CIPHER 146 |
795 | #define ENGINE_R_UNIMPLEMENTED_DIGEST 147 | 823 | #define ENGINE_R_UNIMPLEMENTED_DIGEST 147 |
824 | #define ENGINE_R_UNIMPLEMENTED_PUBLIC_KEY_METHOD 101 | ||
796 | #define ENGINE_R_VERSION_INCOMPATIBILITY 145 | 825 | #define ENGINE_R_VERSION_INCOMPATIBILITY 145 |
797 | 826 | ||
798 | #ifdef __cplusplus | 827 | #ifdef __cplusplus |