CVE-2026-73649: CWE-94: Improper Control of Generation of Code ('Code Injection') in shepherdwind velocity.js
Velocity.js, a JavaScript implementation of the Apache Velocity template engine, contains a critical code injection vulnerability (CWE-94) in versions prior to 2.1.7. The vulnerability arises because property-read expressions were not properly filtered, allowing attacker-controlled templates to access the JavaScript Function constructor via prototype traversal. This flaw enables execution of arbitrary shell commands and access to sensitive environment variables, cloud credentials, and internal network resources within the server process. The issue is fixed in version 2.1.7.
AI Analysis
Technical Summary
Velocity.js versions before 2.1.7 have an improper control of code generation vulnerability (CWE-94) due to incomplete filtering of property-read expressions in the template engine's code. While the earlier fix for CVE-2026-44966 filtered dangerous properties in the #set assignment handler, property-read expressions in src/compile/references.ts remained unfiltered. This allowed attacker-controlled templates to traverse constructor.constructor to the JavaScript Function constructor, enabling arbitrary code execution on the server. The vulnerability permits execution of shell commands and unauthorized access to environment variables, cloud credentials, and internal network resources. The vulnerability is resolved in version 2.1.7.
Potential Impact
Successful exploitation allows an unauthenticated attacker to execute arbitrary code on the server running Velocity.js, leading to full compromise of the server environment. This includes executing shell commands, accessing sensitive environment variables, cloud credentials, and internal network resources, resulting in complete confidentiality, integrity, and availability loss.
Mitigation Recommendations
Upgrade Velocity.js to version 2.1.7 or later, where this vulnerability is fixed. No other mitigations are indicated. Patch status is confirmed by the vendor advisory stating the issue is fixed in 2.1.7.
CVE-2026-73649: CWE-94: Improper Control of Generation of Code ('Code Injection') in shepherdwind velocity.js
Description
Velocity.js, a JavaScript implementation of the Apache Velocity template engine, contains a critical code injection vulnerability (CWE-94) in versions prior to 2.1.7. The vulnerability arises because property-read expressions were not properly filtered, allowing attacker-controlled templates to access the JavaScript Function constructor via prototype traversal. This flaw enables execution of arbitrary shell commands and access to sensitive environment variables, cloud credentials, and internal network resources within the server process. The issue is fixed in version 2.1.7.
CVSS v3.1
Score 9.8critical
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
Velocity.js versions before 2.1.7 have an improper control of code generation vulnerability (CWE-94) due to incomplete filtering of property-read expressions in the template engine's code. While the earlier fix for CVE-2026-44966 filtered dangerous properties in the #set assignment handler, property-read expressions in src/compile/references.ts remained unfiltered. This allowed attacker-controlled templates to traverse constructor.constructor to the JavaScript Function constructor, enabling arbitrary code execution on the server. The vulnerability permits execution of shell commands and unauthorized access to environment variables, cloud credentials, and internal network resources. The vulnerability is resolved in version 2.1.7.
Potential Impact
Successful exploitation allows an unauthenticated attacker to execute arbitrary code on the server running Velocity.js, leading to full compromise of the server environment. This includes executing shell commands, accessing sensitive environment variables, cloud credentials, and internal network resources, resulting in complete confidentiality, integrity, and availability loss.
Mitigation Recommendations
Upgrade Velocity.js to version 2.1.7 or later, where this vulnerability is fixed. No other mitigations are indicated. Patch status is confirmed by the vendor advisory stating the issue is fixed in 2.1.7.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-08-13T14:04:09.604Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a7e08efbf8831d5399b79b6
Added to database: 08/13/2026, 18:11:59 UTC
Last enriched: 08/13/2026, 18:26:08 UTC
Last updated: 08/14/2026, 00:27:47 UTC
Views: 9
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.