opnsense-src/sys/crypto/openssl
Mark Johnston 118b866d9c ossl: Fix some bugs in the fallback AES-GCM implementation
gcm_*_aesni() are used when the AVX512 implementation is not available.
Fix two bugs which manifest when handling operations spanning multiple
segments:
- Avoid underflow when the length of the input is smaller than the
  residual.
- In gcm_decrypt_aesni(), ensure that we begin the operation at the
  right offset into the input and output buffers.

Reviewed by:	jhb
Fixes:		9b1d87286c ("ossl: Add a fallback AES-GCM implementation using AES-NI")
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D42838

(cherry picked from commit 47d767dab54895f3ba8abac6ab2295797394659e)
2023-12-03 12:48:09 -05:00
..
aarch64 OpenSSL: update to 3.0.12 2023-10-25 16:20:31 -04:00
amd64 ossl: Fix some bugs in the fallback AES-GCM implementation 2023-12-03 12:48:09 -05:00
arm ossl: Update the generated assembly files from OpenSSL 3.0. 2023-09-08 13:55:44 -07:00
i386 ossl: Update the generated assembly files from OpenSSL 3.0. 2023-09-08 13:55:44 -07:00
powerpc ossl: Update the generated assembly files from OpenSSL 3.0. 2023-09-08 13:55:44 -07:00
powerpc64 ossl: Update the generated assembly files from OpenSSL 3.0. 2023-09-08 13:55:44 -07:00
powerpc64le ossl: Update the generated assembly files from OpenSSL 3.0. 2023-09-08 13:55:44 -07:00
ossl.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
ossl.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
ossl_aarch64.c sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
ossl_aarch64.h ossl: Add support for AES-CBC cipher 2021-11-08 10:53:31 +01:00
ossl_aes.c ossl: Keep mutable AES-GCM state on the stack 2023-12-02 14:25:42 -05:00
ossl_aes_gcm.h ossl: Provide a fallback definition of __uint128_t when needed 2023-06-04 12:39:44 -04:00
ossl_chacha.h ossl: Add ChaCha20 cipher support. 2021-03-03 15:20:57 -08:00
ossl_chacha20.c spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD 2023-05-12 10:44:03 -06:00
ossl_cipher.h spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD 2023-05-12 10:44:03 -06:00
ossl_hash.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
ossl_poly1305.c ossl: Add support for the ChaCha20 + Poly1305 AEAD cipher from RFC 8439 2021-03-03 15:20:57 -08:00
ossl_poly1305.h ossl: Add support for the ChaCha20 + Poly1305 AEAD cipher from RFC 8439 2021-03-03 15:20:57 -08:00
ossl_sha.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
ossl_sha1.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
ossl_sha256.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
ossl_sha512.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
ossl_x86.c sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
ossl_x86.h ossl: Add support for AES-CBC cipher 2021-11-08 10:53:31 +01:00