From: Ard Biesheuvel Date: Tue, 29 Nov 2016 17:23:36 +0000 (+0000) Subject: crypto: arm/aesbs - fix brokenness after skcipher conversion X-Git-Tag: v4.10-rc1~117^2~20 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=81126d1a8bc23c72a13c05c4308dc6951afc3b45;p=linux.git crypto: arm/aesbs - fix brokenness after skcipher conversion The CBC encryption routine should use the encryption round keys, not the decryption round keys. Signed-off-by: Ard Biesheuvel Signed-off-by: Herbert Xu --- diff --git a/arch/arm/crypto/aesbs-glue.c b/arch/arm/crypto/aesbs-glue.c index f5eafce10557..d8e06de72ef3 100644 --- a/arch/arm/crypto/aesbs-glue.c +++ b/arch/arm/crypto/aesbs-glue.c @@ -113,7 +113,7 @@ static inline void aesbs_encrypt_one(struct crypto_skcipher *tfm, { struct aesbs_cbc_ctx *ctx = crypto_skcipher_ctx(tfm); - AES_encrypt(src, dst, &ctx->dec.rk); + AES_encrypt(src, dst, &ctx->enc); } static int aesbs_cbc_encrypt(struct skcipher_request *req)