# CVE-2026-119340: Tesseract: GENERIC_2D_ARRAY DeSerializeSize signed integer comparison bypass allows negative dimensions

- Severity: Medium 5.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.16%, higher than 5% of CVEs (2026-12-01)
- Published: 2026-10-30T20:22:46.387Z
- Modified: 2026-11-05T03:17:20.013Z
- Weaknesses: CWE-190, CWE-681
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Tesseract is an open source OCR engine. Prior to 5.5.4, GENERIC_2D_ARRAY::DeSerializeSize in src/ccstruct/matrix.h reads matrix dimensions as signed int32_t values and compares them only with UINT16_MAX, allowing negative values to reach ResizeNoInit. Negative dimensions or a 65535 by 65535 product can create inconsistent allocation state and later out-of-bounds accesses while loading a crafted traineddata file, causing denial of service. This issue is fixed in version 5.5.4.

(As written by CVE List.)

## Affected

- tesseract-ocr tesseract: < 5.5.4

## References

- <https://github.com/tesseract-ocr/tesseract/security/advisories/GHSA-6xhq-wvww-6xfg>
- <https://github.com/tesseract-ocr/tesseract/pull/4649>
- <https://github.com/tesseract-ocr/tesseract/commit/048e92378f1a34dcdaf94bc515c7552ac01f08ef>
- <https://github.com/tesseract-ocr/tesseract/releases/tag/5.5.4>

## Sources

- CVE List: [CVE-2026-119340](https://www.cve.org/CVERecord?id=CVE-2026-119340), CVE Terms of Use, modified 2026-11-05
- NVD: [CVE-2026-119340](https://nvd.nist.gov/vuln/detail/CVE-2026-119340), Public domain, modified 2026-11-05

---

Page: https://cve.day/CVE-2026-119340 · Whole record: https://cve.day/CVE-2026-119340.json · Rebuilt by cve.day 2026-11-25T22:59:48.024Z
