Summary
It was discovered that Jinja2 incorrectly handled certain HTML attributes
that were accepted by the xmlattr filter. An attacker could use this issue
to inject arbitrary HTML attribute keys and values to potentially execute
a cross-site scripting (XSS) attack.
Fixed packages 6
| Release | Package | Fixed in |
|---|---|---|
| Ubuntu · 20.04 LTS 20.04:LTS | jinja2 | 2.10.1-2ubuntu0.3 |
| Ubuntu · 22.04 LTS 22.04:LTS | jinja2 | 3.0.3-1ubuntu0.2 |
| Ubuntu · 24.04 LTS 24.04:LTS | jinja2 | 3.1.2-1ubuntu1.1 |
| Ubuntu · Pro 14.04 LTS Pro:14.04:LTS | jinja2 | 2.7.2-2ubuntu0.1~esm3 |
| Ubuntu · Pro 16.04 LTS Pro:16.04:LTS | jinja2 | 2.8-1ubuntu0.1+esm3 |
| Ubuntu · Pro 18.04 LTS Pro:18.04:LTS | jinja2 | 2.10-1ubuntu0.18.04.1+esm2 |
Vulnerabilities 1
-
Medium 5.4CVE-2024-34064 Public exploit
Jinja vulnerable to HTML attribute injection when passing user input as keys to xmlattr filter
Jinja is an extensible templating engine. The `xmlattr` filter in affected versions of Jinja accepts keys containing non-attribute characters. XML/HTML attributes cannot contain spaces, `/`, `>`, or `=`, as each would then be interpreted as starting a separat…
References
-
report
https://ubuntu.com/security/CVE-2024-34064