From: Dr. Stephen Henson Date: Mon, 21 Nov 2016 01:34:56 +0000 (+0000) Subject: Add pss field to RSA structure and free it. X-Git-Tag: OpenSSL_1_1_1-pre1~2785 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d771441d9ba5ccb55fa6f7a3b6ec5bac1ebc1d1f;p=oweals%2Fopenssl.git Add pss field to RSA structure and free it. Reviewed-by: Rich Salz Reviewed-by: Matt Caswell (Merged from https://github.com/openssl/openssl/pull/2177) --- diff --git a/crypto/rsa/rsa_lib.c b/crypto/rsa/rsa_lib.c index e41644b099..8f934d8abc 100644 --- a/crypto/rsa/rsa_lib.c +++ b/crypto/rsa/rsa_lib.c @@ -152,6 +152,7 @@ void RSA_free(RSA *r) BN_clear_free(r->dmp1); BN_clear_free(r->dmq1); BN_clear_free(r->iqmp); + RSA_PSS_PARAMS_free(r->pss); BN_BLINDING_free(r->blinding); BN_BLINDING_free(r->mt_blinding); OPENSSL_free(r->bignum_data); diff --git a/crypto/rsa/rsa_locl.h b/crypto/rsa/rsa_locl.h index e342ca8dfb..fe55b35aae 100644 --- a/crypto/rsa/rsa_locl.h +++ b/crypto/rsa/rsa_locl.h @@ -28,6 +28,8 @@ struct rsa_st { BIGNUM *dmp1; BIGNUM *dmq1; BIGNUM *iqmp; + /* If a PSS only key this contains the parameter restrictions */ + RSA_PSS_PARAMS *pss; /* be careful using this if the RSA structure is shared */ CRYPTO_EX_DATA ex_data; CRYPTO_REF_COUNT references;