Node.js Wrapper for Tesseract OCR Vulnerability Exposes Command Injection Risk
CVE-2026-26832

9.8CRITICAL

Key Information:

Vendor

npm

Vendor
CVE Published:
25 March 2026

What is CVE-2026-26832?

The node-tesseract-ocr package provides an interface for integrating Tesseract OCR in Node.js applications. In all versions up to 2.2.1, a vulnerability exists in the recognize() function, where an attacker can exploit unsanitized file path inputs. This input is concatenated into a command string and executed via child_process.exec(), leading to OS command injection. This could allow an attacker to execute arbitrary commands on the host machine, potentially compromising the integrity and security of the system. Developers using this package should evaluate their applications and implement necessary mitigations to safeguard their environments.

References

CVSS V3.1

Score:
9.8
Severity:
CRITICAL
Confidentiality:
High
Integrity:
High
Availability:
High
Attack Vector:
Network
Attack Complexity:
Low
Privileges Required:
None
User Interaction:
None
Scope:
Unchanged

Timeline

  • Vulnerability published

  • Vulnerability Reserved

.