Binary-parser versions prior to 2.3.1 are affected by a critical code injection vulnerability identified as CVE-2026-134814. This flaw, rated with a CVSS score of 9.2, allows attackers to inject arbitrary JavaScript through string options in the parser.

The vulnerability arises from the interpolation of string-valued parser options, such as length, lengthInBytes, offset, tag, key, and namely() aliases, into generated JavaScript without validation. This can lead to arbitrary JavaScript execution in Node.js processes when parsing data with parsers built from attacker-controlled strings.

Sploitus has published a proof-of-concept harness and exploit demonstrating the issue. However, Redpacketsecurity states that active exploitation of this vulnerability cannot be confirmed, despite the reported exploitation.

The most vulnerable systems are Node.js services and tools that dynamically build parsers from user-controlled input. The risk is particularly high where untrusted parties can influence parser definitions.

The vulnerability has been addressed in binary-parser version 2.3.1, which includes a fix for the issue. Users of affected versions are advised to update to the latest version to mitigate potential risks.