## Overview
A high-severity code injection vulnerability has been identified in the binary-parser library, affecting versions prior to 2.3.1. This vulnerability, tracked as CVE-2026-134814, poses a significant risk to applications utilizing this library.
## Technical Details
The vulnerability arises from unvalidated string-typed options passed to the `Context.generateOption()` function. Attackers can exploit this flaw by controlling parser definitions. They can inject malicious JavaScript by supplying crafted values for parameters like `length`, `lengthInBytes`, `key`, `tag`, `offset`, or `namely()` alias. If the parser compiles with these options, arbitrary JavaScript code can execute within the Node.js process.
## Impact
The CVSS score of 9.2 indicates a critical risk. Successful exploitation could lead to remote code execution, allowing attackers to execute arbitrary code in the context of the affected application. This could compromise the entire Node.js environment and expose sensitive data or system resources.
## Mitigation
Defenders should prioritize updating the binary-parser library to version 2.3.1 or later to mitigate this vulnerability. Additionally, review and validate parser definitions to ensure no untrusted input is processed. Regularly monitor for updates and security advisories related to this and other dependencies.
CSURFACE Threat Sensor