Re: [PATCH] arm/arm64/crypto: assure that ECB modes don't require an IV

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12 February 2016 at 16:47, Jeremy Linton <jeremy.linton@xxxxxxx> wrote:
> ECB modes don't use an initialization vector. The kernel
> /proc/crypto interface doesn't reflect this properly.
>
> Signed-off-by: Jeremy Linton <jeremy.linton@xxxxxxx>

Thanks for spotting that!

Acked-by: Ard Biesheuvel <ard.biesheuvel@xxxxxxxxxx>

> ---
>  arch/arm/crypto/aes-ce-glue.c | 4 ++--
>  arch/arm64/crypto/aes-glue.c  | 4 ++--
>  2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm/crypto/aes-ce-glue.c b/arch/arm/crypto/aes-ce-glue.c
> index b445a5d..89a3a3e 100644
> --- a/arch/arm/crypto/aes-ce-glue.c
> +++ b/arch/arm/crypto/aes-ce-glue.c
> @@ -364,7 +364,7 @@ static struct crypto_alg aes_algs[] = { {
>         .cra_blkcipher = {
>                 .min_keysize    = AES_MIN_KEY_SIZE,
>                 .max_keysize    = AES_MAX_KEY_SIZE,
> -               .ivsize         = AES_BLOCK_SIZE,
> +               .ivsize         = 0,
>                 .setkey         = ce_aes_setkey,
>                 .encrypt        = ecb_encrypt,
>                 .decrypt        = ecb_decrypt,
> @@ -441,7 +441,7 @@ static struct crypto_alg aes_algs[] = { {
>         .cra_ablkcipher = {
>                 .min_keysize    = AES_MIN_KEY_SIZE,
>                 .max_keysize    = AES_MAX_KEY_SIZE,
> -               .ivsize         = AES_BLOCK_SIZE,
> +               .ivsize         = 0,
>                 .setkey         = ablk_set_key,
>                 .encrypt        = ablk_encrypt,
>                 .decrypt        = ablk_decrypt,
> diff --git a/arch/arm64/crypto/aes-glue.c b/arch/arm64/crypto/aes-glue.c
> index 05d9e16..7a3d22a 100644
> --- a/arch/arm64/crypto/aes-glue.c
> +++ b/arch/arm64/crypto/aes-glue.c
> @@ -294,7 +294,7 @@ static struct crypto_alg aes_algs[] = { {
>         .cra_blkcipher = {
>                 .min_keysize    = AES_MIN_KEY_SIZE,
>                 .max_keysize    = AES_MAX_KEY_SIZE,
> -               .ivsize         = AES_BLOCK_SIZE,
> +               .ivsize         = 0,
>                 .setkey         = aes_setkey,
>                 .encrypt        = ecb_encrypt,
>                 .decrypt        = ecb_decrypt,
> @@ -371,7 +371,7 @@ static struct crypto_alg aes_algs[] = { {
>         .cra_ablkcipher = {
>                 .min_keysize    = AES_MIN_KEY_SIZE,
>                 .max_keysize    = AES_MAX_KEY_SIZE,
> -               .ivsize         = AES_BLOCK_SIZE,
> +               .ivsize         = 0,
>                 .setkey         = ablk_set_key,
>                 .encrypt        = ablk_encrypt,
>                 .decrypt        = ablk_decrypt,
> --
> 2.4.3
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
--
To unsubscribe from this list: send the line "unsubscribe linux-crypto" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux