CVE-2022-29078Ejs Command Injection
ejs template injection vulnerability
Published Apr 26, 2022 · Updated Oct 20, 2026 · Also known as DEBIAN-CVE-2022-29078, GHSA-phwq-j96m-2c2q, ROOT-APP-NPM-CVE-2022-29078, UBUNTU-CVE-2022-29078
Key Facts
Patch immediately- CVE-2022-29078 is a critical-severity vulnerability (CVSS 9.8 v3.1) affecting Ejs, node-ejs (debian), @rootio/ejs (root).
- It is exploited in the wild, listed in CIRCL KEV, Industry KEV feed since Sep 18, 2024. No public exploit code is known.
- EPSS estimates a 33% probability of exploitation in the next 30 days.
- Fixed versions are available, including @rootio/ejs 2.7.4-root.io.1, Ejs 2.7.4-aikido.1, Ejs 3.1.7.
- Brandefense priority: patch immediately, because it is listed as exploited in the wild.
Scores
CVSS v3.1
9.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS (30-day exploit likelihood)
33%
Higher than 98.3% of all scored CVEs
Exploit maturity
Exploited (KEV)
ATLAS score
57/100
Publication score, see How it works
Exploitation Verdict
KEV listed
Sep 18, 2024
876 days after publication
Federal due date
None
No federal due date
Ransomware use
Not reported
Attributed actors
None named
Exploit & Defence Guidance
Exploit maturity
Exploited (KEV)
Public exploit code
0
Proof-of-concept links
In-the-wild evidence
10
Reports of active use
Advisories And Exploit References
- advisoryhttps://www.cve.org/CVERecord?id=CVE-2022-29078
- advisoryhttps://nvd.nist.gov/vuln/detail/CVE-2022-29078
- advisoryhttps://security-tracker.debian.org/tracker/CVE-2022-29078
- advisoryhttps://ubuntu.com/security/CVE-2022-29078
- advisoryGHSA advisory
- advisoryhttps://security.netapp.com/advisory/ntap-20220804-0001/
Description
The ejs (aka Embedded JavaScript templates) package 3.1.6 for Node.js allows server-side template injection in settings[view options][outputFunctionName]. This is parsed as an internal option, and overwrites the outputFunctionName option with an arbitrary OS command (which is executed upon template compilation).
Known-Exploited Catalog Listings
| Catalog | Added | Remediation due | Ransomware use |
|---|---|---|---|
| CIRCL KEV | Sep 18, 2024 | n/a | Not reported |
| Industry KEV feed | Sep 18, 2024 | n/a | Not reported |
Affected Products
18 affected entries in total| Product | Affected versions | Fixed in |
|---|---|---|
| EjsEjs | 3.1.6 | 3.1.7 |
| node-ejsdebian | See advisory | 2.5.7-3+deb11u1 |
| @rootio/ejsroot | See advisory | 2.7.4-root.io.1 |
Patched Releases
@rootio/ejs
2.7.4-root.io.1
Ejs
2.7.4-aikido.1, 3.1.7
node-ejs
2.5.7-3+deb11u1, 3.1.7-1
Timeline
Publicly disclosed
Apr 26, 2022
Added to CIRCL KEV
Sep 18, 2024
Added to Industry KEV feed
Sep 18, 2024
Last updated
Oct 20, 2026
Weakness Type
- CWE-74 Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
- CWE-77 Improper Neutralization of Special Elements used in a Command ('Command Injection')
- CWE-94 Improper Control of Generation of Code ('Code Injection')
References
- advisorycve.org · CVERecord
- advisorynvd.nist.gov · CVE-2022-29078
- advisorysecurity-tracker.debian.org · CVE-2022-29078
- advisoryubuntu.com · CVE-2022-29078
- advisoryGHSA advisory
FAQ
Common Questions.
The ejs (aka Embedded JavaScript templates) package 3.1.6 for Node.js allows server-side template injection in settings[view options][outputFunctionName].
Affected: Ejs versions 3.1.6; node-ejs (debian); @rootio/ejs (root). The full list is in the CVE brief.
It is exploited in the wild, listed in CIRCL KEV, Industry KEV feed since Sep 18, 2024.
No, it is not currently listed in the CISA Known Exploited Vulnerabilities catalog.
No public exploit code is known.
Fixed versions are available, including @rootio/ejs 2.7.4-root.io.1, Ejs 2.7.4-aikido.1, Ejs 3.1.7.
Brandefense priority: patch immediately, because it is listed as exploited in the wild.
Is CVE-2022-29078 On Your Attack Surface?
Brandefense matches it against the products discovered on your perimeter and opens a finding the day a CVE like this is listed.
Request A Demo