CVE-2026-5477 in Wolfssl
An integer overflow existed in the wolfCrypt CMAC implementation, that could be exploited to forge CMAC tags. The function wc_CmacUpdate used the guard `if (cmac->totalSz != 0)` to skip XOR-chaining on the first block (where digest is all-zeros and the XOR is a no-op). However, totalSz is word32 and wraps to zero af...
Affects 1 product from 1 vendor. Facts below cite their sources.
Remotely exploitable over the network, low complexity, no authentication required, no user interaction needed, impact contained to the vulnerable component, no confidentiality impact, full integrity impact, no availability impact.
Affected products and versions
| Vendor | Product | Affected versions |
|---|---|---|
| Wolfssl | Wolfssl | ≤ 5.9.0 |
A product listed here is affected only at the versions shown. Use the free check to test the exact version you run.
Fix and vendor advisory
No official vendor advisory link on record. See the CVE record.
Exploitation
| CISA known-exploited | Not in the CISA KEV catalog |
|---|---|
| Public exploit | Not confirmed |
Official description
An integer overflow existed in the wolfCrypt CMAC implementation, that could be exploited to forge CMAC tags. The function wc_CmacUpdate used the guard `if (cmac->totalSz != 0)` to skip XOR-chaining on the first block (where digest is all-zeros and the XOR is a no-op). However, totalSz is word32 and wraps to zero after 2^28 block flushes (4 GiB), causing the guard to erroneously discard the live CBC-MAC chain state. Any two messages sharing a common suffix beyond the 4 GiB mark then produce identical CMAC tags, enabling a zero-work prefix-substitution forgery. The fix removes the guard, making the XOR unconditional; the no-op property on the first block is preserved because digest is zero-initialized by wc_InitCmac_ex.
Source: NIST NVD / MITRE CVE.
Record details
| CVE ID | CVE-2026-5477 |
|---|---|
| BreachSpider ID | BS-2026-GLOBAL-153955-H |
| CVSS vector | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N |
| Published | 2026-04-10 |
| Last modified | 2026-06-17 |
| Weakness (CWE) | |
| Source | NVD |
Weakness definitions
CWE-190: Integer Overflow or Wraparound
Arithmetic operation exceeds the maximum integer value, wrapping around and often leading to undersized allocations.
Related attack patterns (CAPEC)
CAPEC-92 Forced Integer Overflow via CWE-190
Mapping is CWE to CAPEC per MITRE CAPEC 3.9.
Analysis AI-written, not human-reviewed
An integer overflow vulnerability in the wolfCrypt CMAC implementation allows for the forging of CMAC tags due to incorrect handling of the totalSz variable, which wraps after 2^28 block flushes.
The vulnerability arises from the use of a 32-bit word (word32) for the totalSz variable in the wc_CmacUpdate function. This variable is used to determine whether to perform XOR-chaining on the first block. When totalSz wraps to zero after processing 4 GiB of data, the guard condition `if (cmac->totalSz != 0)` fails, leading to the incorrect skipping of XOR-chaining, which can be exploited to forge CMAC tags.
Questions
What is CVE-2026-5477?
An integer overflow vulnerability in the wolfCrypt CMAC implementation allows for the forging of CMAC tags due to incorrect handling of the totalSz variable, which wraps after 2^28 block flushes.
What is the CVSS score for CVE-2026-5477?
CVE-2026-5477 has CVSS 7.5 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N. EPSS: 0.4%.
Is CVE-2026-5477 actively exploited?
No confirmed active exploitation of CVE-2026-5477 as of 2026-09-25.
How do I remediate CVE-2026-5477?
Priority: HIGH.
What systems are affected by CVE-2026-5477?
CVE-2026-5477 affects Wolfssl Wolfssl.
For developers and AI agents
Run this check from your own code or agent
REST API
curl -s https://breachspider.com/api/v1/assets/correlate-cves \
-H "Authorization: Bearer $BREACHSPIDER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"assets":[{"asset_id":"dev-1","vendor":"Wolfssl","product":"Wolfssl","version":"1.0"}]}'
MCP for AI agents
# hosted: add as a connector
https://mcp.breachspider.com/mcp
# local
pipx install breachspider-mcp
Free trial: 14 days, 750 device checks, no card.
Page facts from NVD, MITRE, CISA and vendor advisories, record last modified 2026-06-17.