CVE-2026-107845 Contao: Cross-site scripting in the comments bundle
An unauthenticated attacker can inject scripts via comment metadata that execute in the backend when moderators view comments, potentially leading to session hijacking.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2026-107845?
CVE-2026-107845 is a critical cross-site scripting vulnerability in contao, published on 9 Oct 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
Contao is an Open Source CMS. From version 4.0.0 until 5.3.50 and 5.7.12, an unauthenticated visitor can submit a comment whose email or website metadata is rendered without sufficient attribute and URL encoding by listComments() in comments-bundle/contao/dca/tl_comments.php. When a backend user opens the Comments module, attacker-controlled script can execute in the Contao backend origin under that user's session. Unpublished comments remain visible to moderators, so moderation does not prevent exposure. This issue is fixed in versions 5.3.50 and 5.7.12.
Which versions are affected by CVE-2026-107845?
4 open source packages ship an affected version, including contao/comments-bundle.
| Package | Affected | Fixed in |
|---|---|---|
contao/comments-bundle Packagist | From 4.0.0 | 5.3.50 |
contao/comments-bundle Packagist | From 4.0.0 | 5.3.50 |
contao/comments-bundle Packagist | From 5.4.0-RC1 | 5.7.12 |
contao/comments-bundle Packagist | From 5.4.0-RC1 | 5.7.12 |
How do I fix CVE-2026-107845?
Upgrade contao/comments-bundle to a fixed version for your release line: 5.3.50 or 5.7.12.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2026-107845 being exploited?
There is no known exploitation of CVE-2026-107845 in the wild and no public exploit code.
Sources
Also known as GHSA-628f-v4f6-p37r.