CVE-2026-48060
High · 8.1CVSS
8.1
EPSS
0.4%
Published
Jul 28, 2026
CISA due date
—
Cloudanix analysis
A flaw in how the web framework handles security cookies inside page templates can let attackers run harmful code in users' browsers.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Data Exposure
- Component
- Web Framework
- Class
- XSS
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Template rendering of the CSRF cookie value bypasses automatic HTML escaping, allowing injected script or markup from the cookie to execute in the victim's browser context when the template follows documented inline configuration patterns.
Why it matters to the business
Attackers can run arbitrary code in authenticated users' browsers, leading to session hijacking, unauthorized actions, or data theft within the application.
How an attack unfolds
An attacker crafts a CSRF cookie containing HTML or JavaScript payloads, delivers it to a victim via a malicious link or prior request, and the victim's browser renders the unescaped cookie content from the template, executing the payload under the application's origin.
How to fix it
Upgrade all Litestar installations to version 2.20.0 or later; review and update any custom template configurations that render CSRF tokens inline; enable Content-Security-Policy headers as an additional layer.
How to confirm the fix worked
Confirm the installed version is 2.20.0 or newer; test by setting a CSRF cookie containing <script>alert(1)</script> and verifying it is escaped in rendered output; run existing CSRF and template test suites.
Typical attack path
- Craft a CSRF cookie value containing HTML or script tags
- Deliver the cookie to a victim through phishing, malicious site, or prior interaction
- Victim loads a page that renders the CSRF cookie via the template engine
- Browser executes the injected script in the application's context
How to detect it
Review web server and application logs for requests containing CSRF cookies with HTML entities or script tags; inspect template rendering paths that include the CSRF cookie value; correlate with unexpected client-side behavior reports.
What your security team should do
- Immediately upgrade to Litestar 2.20.0 across all environments
- Audit template usage for inline CSRF token rendering and apply escaping where needed
- Add CSP headers to limit script execution sources
- Monitor for unusual cookie values containing HTML entities in application logs
The record
Litestar is an Asynchronous Server Gateway Interface (ASGI) framework. Prior to version 2.20.0, Litestar instances which use a template engine in conjunction with CSRF protection are vulnerable to HTML Injection which can be escalated to Cross Site Scripting due to the contents of the CSRF cookie being excluded from automatic escaping by the template engine when configured inline with documentation recommendations. This issue has been patched in version 2.20.0.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|
Related vulnerabilities
- CVE-2026-115541 HumHub Community Edition 1.19.0 contains a stored cross-site scripting vulnerability in… CWE-79
- CVE-2026-82160 Dell Wyse Management Suite, versions prior to 2609.0.0.155, contain an Improper… CWE-79
- CVE-2026-82161 Dell Wyse Management Suite, versions prior to 2609.0.0.155, contain an Improper… CWE-79
- CVE-2026-82158 Dell Wyse Management Suite, versions prior to 2609.0.0.155, contain an Improper… CWE-79
- CVE-2026-82159 Dell Wyse Management Suite, versions prior to 2609.0.0.155, contain an Improper… CWE-79
- CVE-2025-71451 Vembu BDRSuite before 7.6.0 contains an unauthenticated cross-site scripting… CWE-79
- CVE-2025-71452 Vembu BDRSuite before 7.6.0 contains an unauthenticated cross-site scripting… CWE-79
- CVE-2026-63197 traQ is a messenger application built for Digital Creators Club traP. CWE-79