Description
An out-of-bounds read (buffer over-read) vulnerability exists in QTextCodec::codecForName() in Qt. When the function is called with a QByteArray that is not NUL-terminated (for example, one created with QByteArray::fromRawData()), the codec-name matching routine reads past the end of the supplied buffer. In most cases this results in an incorrect text codec being selected; in the worst case, if the over-read reaches unmapped memory, the process crashes (denial of service). The over-read is bounded by the length of the longest codec-name candidate, and the out-of-bounds bytes are only compared internally against Qt's fixed list of codec names, so no data is disclosed to an attacker. Applications that do not pass non-NUL-terminated QByteArrays to QTextCodec::codecForName() are not exposed. The affected code resides in the Qt5Compat module from Qt 6.0.0 onward, and in Qt Core (qtbase) in Qt 4.x and Qt 5.x.
Published: 2026-07-21
Score: 6.3 Medium
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability is an out-of-bounds read in Qt's QTextCodec::codecForName() when called with a non‑NUL‑terminated QByteArray. This causes the codec‑name matching routine to read past the supplied buffer. In most scenarios the application ends up selecting an incorrect text codec; in the worst case, an over‑read that reaches unmapped memory can crash the process, resulting in a denial‑of‑service condition. The fault is a buffer over‑read (CWE‑125) and does not expose application data to an attacker.

Affected Systems

Qt products including Qt 4.x, Qt 5.x, and Qt 6.0.0 and later are affected. The faulty code resides in the Qt5Compat module from Qt 6.0.0 onward, and in Qt Core (qtbase) in Qt 4.x and Qt 5.x. Any application that links against these modules and invokes QTextCodec::codecForName() with non‑NUL‑terminated input is exposed.

Risk and Exploitability

The CVSS score is 6.3, indicating moderate severity, while the EPSS score is less than 1% and the issue is not listed in the CISA KEV catalog, pointing to a low likelihood of exploitation in the wild. The flaw requires the attacker to supply crafted input that triggers a non‑NUL‑terminated QByteArray to the codec selection routine, so exploitation is limited to environments where that function is exposed to untrusted data. The primary impact remains a denial‑of‑service via process crash, with no direct data disclosure.

Generated by OpenCVE AI on July 30, 2026 at 17:30 UTC.

Remediation

Vendor Solution

Update to Qt 6.8.8, Qt 6.11.1, Qt 6.12.0, or later, or apply the referenced patch.


OpenCVE Recommended Actions

  • Update Qt to 6.8.8, 6.11.1, 6.12.0, or later, or apply the referenced patch.
  • Avoid passing non‑NUL‑terminated QByteArrays to QTextCodec::codecForName(); ensure input is terminated or validated before calling the function.
  • Monitor Qt releases and apply any subsequent security updates promptly.

Generated by OpenCVE AI on July 30, 2026 at 17:30 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Wed, 22 Jul 2026 19:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Tue, 21 Jul 2026 14:00:00 +0000

Type Values Removed Values Added
Description An out-of-bounds read (buffer over-read) vulnerability exists in QTextCodec::codecForName() in Qt. When the function is called with a QByteArray that is not NUL-terminated (for example, one created with QByteArray::fromRawData()), the codec-name matching routine reads past the end of the supplied buffer. In most cases this results in an incorrect text codec being selected; in the worst case, if the over-read reaches unmapped memory, the process crashes (denial of service). The over-read is bounded by the length of the longest codec-name candidate, and the out-of-bounds bytes are only compared internally against Qt's fixed list of codec names, so no data is disclosed to an attacker. Applications that do not pass non-NUL-terminated QByteArrays to QTextCodec::codecForName() are not exposed. The affected code resides in the Qt5Compat module from Qt 6.0.0 onward, and in Qt Core (qtbase) in Qt 4.x and Qt 5.x.
Title Out-of-bounds read in QTextCodec::codecForName() in Qt
First Time appeared Qt
Qt qt
Weaknesses CWE-125
CPEs cpe:2.3:a:qt:qt:*:*:*:*:*:*:*:*
Vendors & Products Qt
Qt qt
References
Metrics cvssV4_0

{'score': 6.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: TQtC

Published:

Updated: 2026-07-22T18:28:22.217Z

Reserved: 2026-05-25T09:55:56.600Z

Link: CVE-2026-9499

cve-icon Vulnrichment

Updated: 2026-07-22T18:13:29.239Z

cve-icon NVD

No data.

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-07-30T17:45:03Z

Weaknesses