[#EVP_DecryptInit_ex2] = EVP_DecryptInit_ex2 :mrdocs: Initialize `ctx` for decryption with `cipher,` `key,` `iv,` and optional parameters. == Synopsis Declared in `<openssl/evp.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int EVP_DecryptInit_ex2( xref:EVP_CIPHER_CTX.adoc[EVP_CIPHER_CTX]* ctx, xref:EVP_CIPHER-07.adoc[EVP_CIPHER] const* cipher, unsigned char const* key, unsigned char const* iv, xref:OSSL_PARAM.adoc[OSSL_PARAM] const params[]); ---- == Return Value 1 on success, or 0 on failure. == Parameters [cols="1,4"] |=== | Name| Description | *ctx* | Cipher context to (re)initialize. | *cipher* | Cipher algorithm, or NULL to reuse the algorithm already associated with `ctx.` | *key* | Decryption key bytes, or NULL to set the cipher without a key yet. | *iv* | Initialization vector, or NULL when unused or set later. | *params* | Optional OSSL_PARAM array applied after initialization, or NULL. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#