CVE-2026-6766
Integer underflow in tls13_AEAD → wild-address write via SSL_AeadDecrypt
- Vendor
- Mozilla — Firefox NSS (libssl3)
- Severity
- Medium · CVSS 5.3
- CWE
- CWE-191 (Integer Underflow / Wraparound)
- Verified on
- GCP e2-standard-4 · Ubuntu 22.04 · ASAN
- Time to patch
- Fixed in Firefox 150 and Firefox ESR 140.10
## Technical summary
When SSL_AeadDecrypt() is called with a ciphertext shorter than the AEAD tag length (16 bytes for AES-128-GCM), an unsigned subtraction in tls13_AEAD wraps around to ~4GB. The resulting wild tag pointer drives a SEGV during the Intel AES-GCM decrypt path. Reachable from any remote QUIC peer; affects deployments using external PKCS#11 modules.
## lib/ssl/tls13con.c:5150 — vulnerable AEAD decrypt path
/* tls13_AEAD() — decrypt path */
if (decrypt) {
inLen = inLen - tagLen; /* BUG: no check that inLen >= tagLen */
tag = (unsigned char *)in + inLen; /* wild pointer when underflow occurs */
}
rv = PK11_AEADOp(context, ivGen, fixedbits, ivOut, ivLen,
aad, aadLen, out, (int *)outLen, maxout,
tag, tagLen, in, inLen);## AddressSanitizer output (excerpt)
==2914==ERROR: AddressSanitizer: SEGV on unknown address
The signal is caused by a WRITE memory access (wild-addr-write).
#0 intel_aes_gcmDEC intel-gcm.S:1186
#1 platform_AES_GCM_DecryptAEAD intel-gcm-wrap.c:503
#2 sftk_AES_AEAD softoken/sftkmessage.c:321
#3 PK11_AEADRawOp pk11/pk11cxt.c:1426
#4 tls13_AEAD (decrypt=1) lib/ssl/tls13con.c:5151 inLen=0xFFFFFFF5
SUMMARY: Wild-address write from unsigned (inLen - tagLen) underflow