1
linux/lib/crypto
Tianjia Zhang ba3c557420 crypto: lib/mpi - Fix unexpected pointer access in mpi_ec_init
When the mpi_ec_ctx structure is initialized, some fields are not
cleared, causing a crash when referencing the field when the
structure was released. Initially, this issue was ignored because
memory for mpi_ec_ctx is allocated with the __GFP_ZERO flag.
For example, this error will be triggered when calculating the
Za value for SM2 separately.

Fixes: d58bb7e55a ("lib/mpi: Introduce ec implementation to MPI library")
Cc: stable@vger.kernel.org # v6.5
Signed-off-by: Tianjia Zhang <tianjia.zhang@linux.alibaba.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2023-12-22 12:30:19 +08:00
..
mpi crypto: lib/mpi - Fix unexpected pointer access in mpi_ec_init 2023-12-22 12:30:19 +08:00
aes.c
aesgcm.c crypto: lib/aesgcm - Add kernel docs for aesgcm_mac 2023-11-17 19:16:28 +08:00
arc4.c
blake2s-generic.c
blake2s-selftest.c
blake2s.c
chacha20poly1305-selftest.c
chacha20poly1305.c
chacha.c
curve25519-fiat32.c
curve25519-generic.c
curve25519-hacl64.c types: Introduce [us]128 2023-06-05 09:36:35 +02:00
curve25519-selftest.c
curve25519.c
des.c
gf128mul.c
Kconfig
libchacha.c
Makefile crypto: lib - Move mpi into lib/crypto 2023-08-11 19:19:27 +08:00
memneq.c
poly1305-donna32.c
poly1305-donna64.c types: Introduce [us]128 2023-06-05 09:36:35 +02:00
poly1305.c
sha1.c
sha256.c crypto: lib/sha256 - Use generic code from sha256_base 2023-05-19 16:45:43 +08:00
utils.c