mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-11 06:20:53 +02:00
Fix missing op validation in EVP_PKEY_decrypt
F-747
This commit is contained in:
committed by
David Garske
parent
5f7bc0f3a6
commit
fac08427e5
@@ -3096,6 +3096,12 @@ int wolfSSL_EVP_PKEY_decrypt(WOLFSSL_EVP_PKEY_CTX *ctx,
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (ctx->op != WC_EVP_PKEY_OP_DECRYPT) {
|
||||
WOLFSSL_MSG("ctx->op must be set to WC_EVP_PKEY_OP_DECRYPT. Use "
|
||||
"wolfSSL_EVP_PKEY_decrypt_init.");
|
||||
return WOLFSSL_FAILURE;
|
||||
}
|
||||
|
||||
(void)out;
|
||||
(void)outLen;
|
||||
(void)in;
|
||||
|
||||
Reference in New Issue
Block a user