# JLSEC-2026-691: A stack buffer overflow vulnerability exists in wolfSSL's PKCS7 SignedData encoding functionality

- Severity: High 7.1 (CVSS:3.1, scored by Julia Security Advisories) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2026-07-14T21:41:35.775Z
- Modified: 2026-07-25T18:24:46.263Z
- Related: CVE-2026-0819, GHSA-3cr6-hpf3-2hmg, EUVD-2026-13131

## Description

A stack buffer overflow vulnerability exists in wolfSSL's PKCS7 SignedData encoding functionality. In `wc_PKCS7_BuildSignedAttributes()`, when adding custom signed attributes, the code passes an incorrect capacity value (esd->signedAttribsCount) to EncodeAttributes() instead of the remaining available space in the fixed-size signedAttribs[7] array. When an application sets pkcs7->signedAttribsSz to a value greater than `MAX_SIGNED_ATTRIBS_SZ` (default 7) minus the number of default attributes already added, EncodeAttributes() writes beyond the array bounds, causing stack memory corruption. In `WOLFSSL_SMALL_STACK` builds, this becomes heap corruption. Exploitation requires an application that allows untrusted input to control the signedAttribs array size when calling `wc_PKCS7_EncodeSignedData()` or related signing functions.

(As written by Julia Security Advisories.)

## Affected

- wolfSSL_jll (Julia): from 5.7.2+0 before 5.9.2+0

## Every score

- Julia Security Advisories: CVSS:3.1 7.1 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H`
- Julia Security Advisories: CVSS:4.0 `CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N/E:U/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X`

## References

- <https://github.com/advisories/GHSA-3cr6-hpf3-2hmg> (web)
- <https://github.com/wolfSSL/wolfssl/pull/9630> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-0819> (web)

## Sources

- Julia Security Advisories: [JLSEC-2026-691](https://osv.dev/vulnerability/JLSEC-2026-691), CC-BY-4.0, modified 2026-07-25

---

Page: https://cve.day/JLSEC-2026-691 · Whole record: https://cve.day/JLSEC-2026-691.json · Rebuilt by cve.day 2026-11-25T22:56:26.204Z
