Description
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.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| Mozilla | Nunjucks | < 3.2.4 | 3.2.4 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | node-nunjucks | 3.2.4+~cs4.2.7-1 | — |
| Debian 13 | node-nunjucks | 3.2.4+~cs4.2.7-1 | — |
| Debian 12 | node-nunjucks | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | node-nunjucks | No fix yet | — |
| Ubuntu 26.04 LTS | node-nunjucks | No fix yet | — |
| Ubuntu 25.10 | node-nunjucks | No fix yet | — |
| Ubuntu 24.04 LTS | node-nunjucks | No fix yet | — |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| npm | nunjucks | < 3.2.4 | 3.2.4 | GHSA-x77j-w7wf-fjmw |
References
- https://bugzilla.mozilla.org/show_bug.cgi?id=1825980 issue-tracking
- https://github.com/mozilla/nunjucks/security/advisories/GHSA-x77j-w7wf-fjmw vendor-advisory