[#BIO_set_cipher] = BIO_set_cipher :mrdocs: Configure a cipher filter BIO with algorithm, key, IV, and encrypt/decrypt mode. == Synopsis Declared in `<openssl/evp.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int BIO_set_cipher( xref:BIO.adoc[BIO]* b, xref:EVP_CIPHER-07.adoc[EVP_CIPHER] const* c, unsigned char const* k, unsigned char const* i, int enc); ---- == Return Value 1 on success, or 0 on failure. == Parameters [cols="1,4"] |=== | Name| Description | *b* | BIO created with BIO_f_cipher(). | *c* | Cipher algorithm to use. | *k* | Key bytes whose length matches the cipher's key length. | *i* | IV bytes whose length matches the cipher's IV length (may be NULL for ECB). | *enc* | 1 to encrypt, or 0 to decrypt. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#