WSL2-Linux-Kernel/arch/arm
Ard Biesheuvel 1a20b96612 crypto: arm/aes - don't use IV buffer to return final keystream block
The ARM bit sliced AES core code uses the IV buffer to pass the final
keystream block back to the glue code if the input is not a multiple of
the block size, so that the asm code does not have to deal with anything
except 16 byte blocks. This is done under the assumption that the outgoing
IV is meaningless anyway in this case, given that chaining is no longer
possible under these circumstances.

However, as it turns out, the CCM driver does expect the IV to retain
a value that is equal to the original IV except for the counter value,
and even interprets byte zero as a length indicator, which may result
in memory corruption if the IV is overwritten with something else.

So use a separate buffer to return the final keystream block.

Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2017-02-03 18:16:21 +08:00
..
boot ARMv7 VExpress fixes for v4.10 2017-01-04 16:33:37 +01:00
common Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
configs ARM: SoC defconfig updates for v4.10 2016-12-15 15:41:04 -08:00
crypto crypto: arm/aes - don't use IV buffer to return final keystream block 2017-02-03 18:16:21 +08:00
firmware
include Merge branch 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm 2016-12-15 16:06:15 -08:00
kernel Merge branch 'smp-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-12-25 14:05:56 -08:00
kvm Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
lib Merge branches 'clkdev', 'fixes', 'misc' and 'sa1100-base' into for-linus 2016-12-14 11:13:46 +00:00
mach-alpine
mach-artpec ARM: ARTPEC-6: add select MFD_SYSCON to MACH_ARTPEC6 2016-11-26 00:06:34 +01:00
mach-asm9260
mach-aspeed
mach-at91
mach-axxia
mach-bcm
mach-berlin
mach-clps711x
mach-cns3xxx
mach-davinci ARM: davinci: da8xx: Fix sleeping function called from invalid context 2017-01-02 16:15:07 +05:30
mach-digicolor
mach-dove
mach-ebsa110
mach-efm32
mach-ep93xx clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
mach-exynos
mach-footbridge clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
mach-gemini
mach-highbank
mach-hisi
mach-imx ARM: i.MX: remove map_io callback 2017-01-02 14:02:09 +08:00
mach-integrator ARM: SoC platform updates for v4.10 2016-12-15 15:39:02 -08:00
mach-iop13xx Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
mach-iop32x
mach-iop33x
mach-ixp4xx clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
mach-keystone
mach-ks8695
mach-lpc18xx
mach-lpc32xx ARM: SoC platform updates for v4.10 2016-12-15 15:39:02 -08:00
mach-mediatek
mach-meson
mach-mmp clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
mach-moxart
mach-mv78xx0
mach-mvebu cpu/hotplug: Cleanup state names 2016-12-25 10:47:44 +01:00
mach-mxs
mach-netx
mach-nomadik
mach-nspire
mach-omap1
mach-omap2 Merge branch 'omap-for-v4.10/legacy' into omap-for-v4.10/fixes 2016-12-27 10:29:24 -08:00
mach-orion5x
mach-oxnas
mach-picoxcell
mach-prima2
mach-pxa ARM: SoC platform updates for v4.10 2016-12-15 15:39:02 -08:00
mach-qcom
mach-realview
mach-rockchip
mach-rpc Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
mach-s3c24xx Samsung mach/soc update for v4.10: 2017-01-04 16:12:17 +01:00
mach-s3c64xx MTD updates for v4.10-rc1: 2016-12-17 16:41:10 -08:00
mach-s5pv210
mach-sa1100 Merge branch 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm 2016-12-15 16:06:15 -08:00
mach-shmobile ARM: SoC driver updates for v4.10 2016-12-15 16:03:25 -08:00
mach-socfpga
mach-spear
mach-sti
mach-stm32
mach-sunxi
mach-tango
mach-tegra
mach-u300
mach-uniphier
mach-ux500
mach-versatile
mach-vexpress
mach-vt8500
mach-w90x900
mach-zx
mach-zynq
mm cpu/hotplug: Cleanup state names 2016-12-25 10:47:44 +01:00
net
nwfpe
oprofile
plat-iop clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01:00
plat-omap
plat-orion
plat-pxa
plat-samsung virtio, vhost: new device, fixes, speedups 2016-12-15 18:13:41 -08:00
plat-versatile
probes
tools Merge branch 'syscalls' into for-linus 2016-12-14 11:14:00 +00:00
vdso
vfp cpu/hotplug: Cleanup state names 2016-12-25 10:47:44 +01:00
xen cpu/hotplug: Cleanup state names 2016-12-25 10:47:44 +01:00
Kconfig Samsung mach/soc update for v4.10: 2017-01-04 16:12:17 +01:00
Kconfig-nommu
Kconfig.debug
Makefile Merge branch 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm 2016-12-15 16:06:15 -08:00