diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2020-08-13 17:44:54 +0200 |
---|---|---|
committer | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2020-08-21 09:04:13 +0200 |
commit | 6d1f50b520ce0a2eaa624686a26ffd4a5af00d93 (patch) | |
tree | d094306e91bd79803bb49a9323ec36bd122ecb4e /include | |
parent | cac30a69bcadcfcf5beb034abf958bbcdb8b83cb (diff) |
Use in CMP+CRMF libctx and propq param added to sign/verify/HMAC/decrypt
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/11808)
Diffstat (limited to 'include')
-rw-r--r-- | include/openssl/cmperr.h | 2 | ||||
-rw-r--r-- | include/openssl/crmf.h | 12 | ||||
-rw-r--r-- | include/openssl/crmferr.h | 3 |
3 files changed, 11 insertions, 6 deletions
diff --git a/include/openssl/cmperr.h b/include/openssl/cmperr.h index f18ba386bc..2ae82974a9 100644 --- a/include/openssl/cmperr.h +++ b/include/openssl/cmperr.h @@ -45,7 +45,6 @@ int ERR_load_CMP_strings(void); # define CMP_R_CERTRESPONSE_NOT_FOUND 113 # define CMP_R_CERT_AND_KEY_DO_NOT_MATCH 114 # define CMP_R_CHECKAFTER_OUT_OF_RANGE 181 -# define CMP_R_CHECKING_PBM_NO_SECRET_AVAILABLE 166 # define CMP_R_ENCOUNTERED_KEYUPDATEWARNING 176 # define CMP_R_ENCOUNTERED_WAITING 162 # define CMP_R_ERROR_CALCULATING_PROTECTION 115 @@ -75,6 +74,7 @@ int ERR_load_CMP_strings(void); # define CMP_R_MISSING_KEY_INPUT_FOR_CREATING_PROTECTION 130 # define CMP_R_MISSING_KEY_USAGE_DIGITALSIGNATURE 142 # define CMP_R_MISSING_P10CSR 121 +# define CMP_R_MISSING_PBM_SECRET 166 # define CMP_R_MISSING_PRIVATE_KEY 131 # define CMP_R_MISSING_PROTECTION 143 # define CMP_R_MISSING_REFERENCE_CERT 168 diff --git a/include/openssl/crmf.h b/include/openssl/crmf.h index 8107d26d5c..022f0bb9d2 100644 --- a/include/openssl/crmf.h +++ b/include/openssl/crmf.h @@ -70,7 +70,8 @@ typedef struct ossl_crmf_optionalvalidity_st OSSL_CRMF_OPTIONALVALIDITY; OSSL_CRMF_PBMPARAMETER *OSSL_CRMF_pbmp_new(OPENSSL_CTX *libctx, size_t slen, int owfnid, size_t itercnt, int macnid); -int OSSL_CRMF_pbm_new(const OSSL_CRMF_PBMPARAMETER *pbmp, +int OSSL_CRMF_pbm_new(OPENSSL_CTX *libctx, const char *propq, + const OSSL_CRMF_PBMPARAMETER *pbmp, const unsigned char *msg, size_t msglen, const unsigned char *sec, size_t seclen, unsigned char **mac, size_t *maclen); @@ -119,10 +120,12 @@ int OSSL_CRMF_MSG_push0_extension(OSSL_CRMF_MSG *crm, X509_EXTENSION *ext); # define OSSL_CRMF_POPO_SIGNATURE 1 # define OSSL_CRMF_POPO_KEYENC 2 # define OSSL_CRMF_POPO_KEYAGREE 3 -int OSSL_CRMF_MSG_create_popo(OSSL_CRMF_MSG *crm, EVP_PKEY *pkey, - int dgst, int ppmtd); +int OSSL_CRMF_MSG_create_popo(int meth, OSSL_CRMF_MSG *crm, + EVP_PKEY *pkey, const EVP_MD *digest, + OPENSSL_CTX *libctx, const char *propq); int OSSL_CRMF_MSGS_verify_popo(const OSSL_CRMF_MSGS *reqs, - int rid, int acceptRAVerified); + int rid, int acceptRAVerified, + OPENSSL_CTX *libctx, const char *propq); OSSL_CRMF_CERTTEMPLATE *OSSL_CRMF_MSG_get0_tmpl(const OSSL_CRMF_MSG *crm); ASN1_INTEGER *OSSL_CRMF_CERTTEMPLATE_get0_serialNumber(const OSSL_CRMF_CERTTEMPLATE *tmpl); @@ -138,6 +141,7 @@ int OSSL_CRMF_CERTTEMPLATE_fill(OSSL_CRMF_CERTTEMPLATE *tmpl, const ASN1_INTEGER *serial); X509 *OSSL_CRMF_ENCRYPTEDVALUE_get1_encCert(const OSSL_CRMF_ENCRYPTEDVALUE *ecert, + OPENSSL_CTX *libctx, const char *propq, EVP_PKEY *pkey); # ifdef __cplusplus diff --git a/include/openssl/crmferr.h b/include/openssl/crmferr.h index 17e5c85cc2..a4c194e094 100644 --- a/include/openssl/crmferr.h +++ b/include/openssl/crmferr.h @@ -10,6 +10,7 @@ #ifndef OPENSSL_CRMFERR_H # define OPENSSL_CRMFERR_H +# pragma once # include <openssl/opensslconf.h> # include <openssl/symhacks.h> @@ -62,6 +63,7 @@ int ERR_load_CRMF_strings(void); # define CRMF_R_ITERATIONCOUNT_BELOW_100 108 # define CRMF_R_MALFORMED_IV 101 # define CRMF_R_NULL_ARGUMENT 109 +# define CRMF_R_POPOSKINPUT_NOT_SUPPORTED 113 # define CRMF_R_POPO_INCONSISTENT_PUBLIC_KEY 117 # define CRMF_R_POPO_MISSING 121 # define CRMF_R_POPO_MISSING_PUBLIC_KEY 118 @@ -70,7 +72,6 @@ int ERR_load_CRMF_strings(void); # define CRMF_R_SETTING_MAC_ALGOR_FAILURE 110 # define CRMF_R_SETTING_OWF_ALGOR_FAILURE 111 # define CRMF_R_UNSUPPORTED_ALGORITHM 112 -# define CRMF_R_UNSUPPORTED_ALG_FOR_POPSIGNINGKEY 113 # define CRMF_R_UNSUPPORTED_CIPHER 114 # define CRMF_R_UNSUPPORTED_METHOD_FOR_CREATING_POPO 115 # define CRMF_R_UNSUPPORTED_POPO_METHOD 116 |