crypto_aead_setkey (9) - Linux Man Pages
crypto_aead_setkey: set key for cipher
crypto_aead_setkey - set key for cipher
int crypto_aead_setkey(struct crypto_aead
*tfm, const u8 *key, unsigned int keylen);
- cipher handle
- buffer holding the key
- length of the key in bytes
The caller provided key is set for the AEAD referenced by the cipher handle.
Note, the key length determines the cipher type. Many block ciphers implement different cipher modes depending on the key size, such as AES-128 vs AES-192 vs. AES-256. When providing a 16 byte key for an AES cipher handle, AES-128 is performed.
Stephan Mueller <smueller [at] chronox.de>
Marek Vasut <marek [at] denx.de>