Description
Velocity.js is a JavaScript implementation of the Apache Velocity template engine. In 2.1.5 and earlier, a prototype pollution vulnerability was discovered in velocityjs. This issue occurs during the processing of #set directives in Velocity templates. If an application renders a template controlled by an attacker, it is possible to modify Object.prototype, potentially leading to Denial of Service (DoS) or Remote Code Execution (RCE) depending on the server environment.
Published: 2026-05-26
Score: 8.3 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability is a prototype pollution flaw triggered by the #set directive in Velocity.js. An attacker who can supply a template that includes a malicious #set will cause the JavaScript runtime to overwrite properties on Object.prototype. This manipulation can corrupt shared object state and lead to a denial of service or, depending on the execution environment, possible remote code execution. The flaw maps to CWE‑1321.

Affected Systems

Affected products are velocity.js version 2.1.5 and all earlier releases, distributed by shepherdwind. Any application that renders attacker‑controlled Velocity templates using these versions is at risk.

Risk and Exploitability

The score of 8.3 indicates a high‑severity flaw. No EPSS data is available, and the vulnerability is not yet listed in CISA KEV, although its impact warrants caution. Exploitation requires only the ability to influence the template; typical attack paths involve user‑generated content, form submissions, or API payloads that are parsed as Velocity templates.

Generated by OpenCVE AI on May 26, 2026 at 22:25 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade velocity.js to the latest version that addresses the #set prototype pollution flaw.
  • If an upgrade cannot be made immediately, disable or sanitize any use of the #set directive in templates that originate from untrusted sources.
  • Validate and whitelist template content to ensure that only trusted templates are rendered and that attacker‑controlled input cannot contain #set directives.

Generated by OpenCVE AI on May 26, 2026 at 22:25 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-j658-c2gf-x6pq Velocity.js has a Prototype Pollution vulnerability through #set path assignment
History

Tue, 02 Jun 2026 18:45:00 +0000

Type Values Removed Values Added
CPEs cpe:2.3:a:shepherdwind:velocity.js:*:*:*:*:*:node.js:*:*

Mon, 01 Jun 2026 17:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Wed, 27 May 2026 10:30:00 +0000

Type Values Removed Values Added
First Time appeared Shepherdwind
Shepherdwind velocity.js
Vendors & Products Shepherdwind
Shepherdwind velocity.js

Tue, 26 May 2026 21:45:00 +0000

Type Values Removed Values Added
Description Velocity.js is a JavaScript implementation of the Apache Velocity template engine. In 2.1.5 and earlier, a prototype pollution vulnerability was discovered in velocityjs. This issue occurs during the processing of #set directives in Velocity templates. If an application renders a template controlled by an attacker, it is possible to modify Object.prototype, potentially leading to Denial of Service (DoS) or Remote Code Execution (RCE) depending on the server environment.
Title Velocity.js: Prototype Pollution in #set path assignment
Weaknesses CWE-1321
References
Metrics cvssV3_1

{'score': 8.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L'}


Subscriptions

Shepherdwind Velocity.js
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-06-01T17:08:58.934Z

Reserved: 2026-05-08T16:23:33.263Z

Link: CVE-2026-44966

cve-icon Vulnrichment

Updated: 2026-06-01T17:08:54.371Z

cve-icon NVD

Status : Analyzed

Published: 2026-05-26T22:16:43.293

Modified: 2026-06-02T18:40:27.360

Link: CVE-2026-44966

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-05-27T10:08:19Z

Weaknesses
  • CWE-1321

    Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')