crypto_blkcipher_encrypt_iv (9) - Linux Manuals
crypto_blkcipher_encrypt_iv: encrypt plaintext with dedicated IV
crypto_blkcipher_encrypt_iv - encrypt plaintext with dedicated IV
int crypto_blkcipher_encrypt_iv(struct blkcipher_desc
* desc, struct scatterlist * dst, struct scatterlist * src, unsigned int nbytes);
- reference to the block cipher handle with meta data
- scatter/gather list that is filled by the cipher operation with the ciphertext
- scatter/gather list that holds the plaintext
- number of bytes of the plaintext to encrypt.
Encrypt plaintext data with the use of an IV that is solely used for this cipher operation. Any previously set IV is not used.
The blkcipher_desc data structure must be filled by the caller and can reside on the stack. The caller must fill desc as follows: desc.tfm is filled with the block cipher handle; desc.info is filled with the IV to be used for the current operation; desc.flags is filled with either CRYPTO_TFM_REQ_MAY_SLEEP or 0.
0 if the cipher operation was successful; < 0 if an error occurred
Stephan Mueller <smueller [at] chronox.de>
Marek Vasut <marek [at] denx.de>