mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
[CRYPTO] geode: Use correct encrypt/decrypt function in fallback
crypto_blkcipher_decrypt is wrong because it does not care about the IV. Signed-off-by: Sebastian Siewior <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
This commit is contained in:
parent
5de8f1b562
commit
fdc520aa69
1 changed files with 2 additions and 2 deletions
|
|
@ -190,7 +190,7 @@ static int fallback_blk_dec(struct blkcipher_desc *desc,
|
|||
tfm = desc->tfm;
|
||||
desc->tfm = op->fallback.blk;
|
||||
|
||||
ret = crypto_blkcipher_decrypt(desc, dst, src, nbytes);
|
||||
ret = crypto_blkcipher_decrypt_iv(desc, dst, src, nbytes);
|
||||
|
||||
desc->tfm = tfm;
|
||||
return ret;
|
||||
|
|
@ -206,7 +206,7 @@ static int fallback_blk_enc(struct blkcipher_desc *desc,
|
|||
tfm = desc->tfm;
|
||||
desc->tfm = op->fallback.blk;
|
||||
|
||||
ret = crypto_blkcipher_encrypt(desc, dst, src, nbytes);
|
||||
ret = crypto_blkcipher_encrypt_iv(desc, dst, src, nbytes);
|
||||
|
||||
desc->tfm = tfm;
|
||||
return ret;
|
||||
|
|
|
|||
Loading…
Reference in a new issue