CVE-2026-25478: CWE-942: Permissive Cross-domain Policy with Untrusted Domains in litestar-org litestar
CVE-2026-25478 is a high-severity vulnerability in the litestar ASGI framework versions prior to 2. 20. 0. It arises from improper construction of the allowed_origins_regex used for CORS origin validation, where metacharacters in the allowlist are not escaped. This flaw allows malicious origins to bypass the intended restrictions, potentially enabling cross-domain attacks. Exploitation requires user interaction but no authentication, and it can lead to a breach of confidentiality by exposing sensitive data to untrusted domains. The vulnerability affects web applications using litestar for asynchronous server gateway interfaces, particularly those relying on CORS for security. Although no known exploits are currently in the wild, the vulnerability's nature and CVSS score of 7. 4 indicate a significant risk. European organizations using litestar in web services should prioritize upgrading to version 2.
AI Analysis
Technical Summary
CVE-2026-25478 is a vulnerability identified in the litestar asynchronous server gateway interface (ASGI) framework, specifically affecting versions prior to 2.20.0. The issue stems from the way litestar constructs the allowed_origins_regex for Cross-Origin Resource Sharing (CORS) validation. The allowed_origins_regex is built from configured allowlist values but fails to escape regex metacharacters properly. This improper escaping means that a maliciously crafted origin string can match the regex unexpectedly when the framework uses the fullmatch() method for validation. As a result, origins that should be blocked can bypass the CORS policy, allowing cross-domain requests from untrusted sources. This vulnerability corresponds to CWE-942, which relates to permissive cross-domain policies that trust unverified domains. The impact is primarily on confidentiality, as unauthorized domains may gain access to sensitive information through cross-origin requests. The CVSS v3.1 score is 7.4 (high), reflecting network attack vector, low attack complexity, no privileges required, but requiring user interaction, and a scope change with high confidentiality impact but no integrity or availability impact. The vulnerability was published on February 9, 2026, and fixed in litestar version 2.20.0. There are no known exploits in the wild yet, but the flaw poses a significant risk to applications relying on litestar's CORS implementation for security. Organizations using affected versions should upgrade promptly and review their CORS configurations to ensure no unintended origins are allowed due to regex misconfiguration.
Potential Impact
For European organizations, this vulnerability can lead to unauthorized data exposure through cross-origin requests, compromising confidentiality of sensitive information handled by web applications built on the litestar framework. Since litestar is an ASGI framework often used in Python-based asynchronous web services, organizations in sectors such as finance, healthcare, and government that rely on these technologies are at risk. The vulnerability allows attackers to craft malicious origins that bypass CORS restrictions, potentially enabling data theft or session hijacking if combined with other weaknesses. Although integrity and availability are not directly impacted, the breach of confidentiality can have severe regulatory and reputational consequences, especially under GDPR. The ease of exploitation (no privileges required and low complexity) increases the threat level. European companies with public-facing APIs or web applications using litestar should consider this vulnerability critical to address to prevent data leakage and maintain compliance with data protection laws.
Mitigation Recommendations
1. Upgrade all litestar instances to version 2.20.0 or later, where the vulnerability is fixed by properly escaping regex metacharacters in allowed_origins_regex. 2. Audit current CORS configurations to identify any overly permissive or regex-based origin allowlists and replace them with explicit, validated origin lists where possible. 3. Implement runtime monitoring and logging of cross-origin requests to detect anomalous or unexpected origins attempting access. 4. Employ Web Application Firewalls (WAFs) with rules to block suspicious cross-origin requests that do not match expected patterns. 5. Educate developers and security teams about the risks of regex-based origin validation and encourage use of safer CORS libraries or configurations. 6. Conduct penetration testing focused on CORS policies to verify that no unauthorized origins can bypass restrictions. 7. For critical applications, consider additional layers of authentication or token validation on cross-origin requests to reduce risk of unauthorized data access.
Affected Countries
Germany, United Kingdom, France, Netherlands, Sweden, Finland
CVE-2026-25478: CWE-942: Permissive Cross-domain Policy with Untrusted Domains in litestar-org litestar
Description
CVE-2026-25478 is a high-severity vulnerability in the litestar ASGI framework versions prior to 2. 20. 0. It arises from improper construction of the allowed_origins_regex used for CORS origin validation, where metacharacters in the allowlist are not escaped. This flaw allows malicious origins to bypass the intended restrictions, potentially enabling cross-domain attacks. Exploitation requires user interaction but no authentication, and it can lead to a breach of confidentiality by exposing sensitive data to untrusted domains. The vulnerability affects web applications using litestar for asynchronous server gateway interfaces, particularly those relying on CORS for security. Although no known exploits are currently in the wild, the vulnerability's nature and CVSS score of 7. 4 indicate a significant risk. European organizations using litestar in web services should prioritize upgrading to version 2.
AI-Powered Analysis
Technical Analysis
CVE-2026-25478 is a vulnerability identified in the litestar asynchronous server gateway interface (ASGI) framework, specifically affecting versions prior to 2.20.0. The issue stems from the way litestar constructs the allowed_origins_regex for Cross-Origin Resource Sharing (CORS) validation. The allowed_origins_regex is built from configured allowlist values but fails to escape regex metacharacters properly. This improper escaping means that a maliciously crafted origin string can match the regex unexpectedly when the framework uses the fullmatch() method for validation. As a result, origins that should be blocked can bypass the CORS policy, allowing cross-domain requests from untrusted sources. This vulnerability corresponds to CWE-942, which relates to permissive cross-domain policies that trust unverified domains. The impact is primarily on confidentiality, as unauthorized domains may gain access to sensitive information through cross-origin requests. The CVSS v3.1 score is 7.4 (high), reflecting network attack vector, low attack complexity, no privileges required, but requiring user interaction, and a scope change with high confidentiality impact but no integrity or availability impact. The vulnerability was published on February 9, 2026, and fixed in litestar version 2.20.0. There are no known exploits in the wild yet, but the flaw poses a significant risk to applications relying on litestar's CORS implementation for security. Organizations using affected versions should upgrade promptly and review their CORS configurations to ensure no unintended origins are allowed due to regex misconfiguration.
Potential Impact
For European organizations, this vulnerability can lead to unauthorized data exposure through cross-origin requests, compromising confidentiality of sensitive information handled by web applications built on the litestar framework. Since litestar is an ASGI framework often used in Python-based asynchronous web services, organizations in sectors such as finance, healthcare, and government that rely on these technologies are at risk. The vulnerability allows attackers to craft malicious origins that bypass CORS restrictions, potentially enabling data theft or session hijacking if combined with other weaknesses. Although integrity and availability are not directly impacted, the breach of confidentiality can have severe regulatory and reputational consequences, especially under GDPR. The ease of exploitation (no privileges required and low complexity) increases the threat level. European companies with public-facing APIs or web applications using litestar should consider this vulnerability critical to address to prevent data leakage and maintain compliance with data protection laws.
Mitigation Recommendations
1. Upgrade all litestar instances to version 2.20.0 or later, where the vulnerability is fixed by properly escaping regex metacharacters in allowed_origins_regex. 2. Audit current CORS configurations to identify any overly permissive or regex-based origin allowlists and replace them with explicit, validated origin lists where possible. 3. Implement runtime monitoring and logging of cross-origin requests to detect anomalous or unexpected origins attempting access. 4. Employ Web Application Firewalls (WAFs) with rules to block suspicious cross-origin requests that do not match expected patterns. 5. Educate developers and security teams about the risks of regex-based origin validation and encourage use of safer CORS libraries or configurations. 6. Conduct penetration testing focused on CORS policies to verify that no unauthorized origins can bypass restrictions. 7. For critical applications, consider additional layers of authentication or token validation on cross-origin requests to reduce risk of unauthorized data access.
Affected Countries
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-02-02T16:31:35.820Z
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 698a36074b57a58fa16ab1d4
Added to database: 2/9/2026, 7:31:19 PM
Last enriched: 2/17/2026, 9:43:31 AM
Last updated: 2/21/2026, 12:22:08 AM
Views: 59
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Related Threats
CVE-2026-27203: CWE-15: External Control of System or Configuration Setting in YosefHayim ebay-mcp
HighCVE-2026-27168: CWE-122: Heap-based Buffer Overflow in HappySeaFox sail
HighCVE-2026-27134: CWE-287: Improper Authentication in strimzi strimzi-kafka-operator
HighCVE-2026-27190: CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in denoland deno
HighCVE-2026-27026: CWE-770: Allocation of Resources Without Limits or Throttling in py-pdf pypdf
MediumActions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.