patchminder
Proof of concept · CISA assessment CVE-2023-2142

Cross-site scriptingin Mozilla Nunjucks.

Published 26 Nov 2024 · Updated 27 Nov 2024 · Every fact sourced

JSONCite
Is it exploited?
Not confirmed

Proof of concept public (CISAThe US cyber defence agency. Its list names every hole it has seen used in real attacks. assessment).

Severity
Medium 6.1
CVSSA severity score from 0 to 10. 9 and higher is critical. 3.1 · CISAThe US cyber defence agency. Its list names every hole it has seen used in real attacks. assessment · no login needed
Attack likelihood
Low
EPSSA daily score from FIRST: the chance a hole is attacked in the next 30 days. 0.4% chance in 30 days · 4 Dec 2026
Fix
Available
Upgrade to 3.2.4 or later
In plain words

In Nunjucks versions prior to version 3.2.4, it was possible to bypass the restrictions which are provided by the autoescape functionality. If there are two user-controlled parameters on the same line used in the views, it was possible to inject cross site scripting payloads using the backslash \ character.

What to do now
  • Upgrade Nunjucks to 3.2.4 or later.
  • Upgrade nunjucks (npm) to 3.2.4 or later.
Versions

Affected and fixed versions

Product or package
Affected
Fixed in
Source
Nunjucks
before 3.2.4
3.2.4
CVE record
nunjucks (npm)
before 3.2.4
3.2.4
GitHub advisory

From the CVE record, NVD and package advisories. When no source has versions yet, this table says "not confirmed" instead of guessing.

Timeline

From first report to first attacks

  1. 18 Apr 2023
    CVE ID reserved by mozilla.
  2. 26 Nov 2024
    Published in the CVE List.
  3. 27 Nov 2024
    CVE record last updated.
Exploit code

Attack code anyone can find

Exploit maturity: Proof of concept (CISA assessment). CISA assessment (SSVC): exploitation poc.

Metasploit module
None known
Nuclei scan template
None known
Exploit-DB
None known
GitHub proof of concepts
None known

Listed so defenders can judge how urgent this is and test systems they are authorised to test. Patchminder does not host exploit code; links open the source page. Labels for GitHub repositories come from their public details and are never a promise about the code. Run anything only in an isolated lab.

Related

Same weakness: Cross-site scripting

All CWE-79 vulnerabilities

References
Cite this page

Patchminder. CVE-2023-2142: Cross-site scripting in Mozilla Nunjucks. https://patchminder.com/cve/cve-2023-2142/ (accessed 5 December 2026).