CVE-2026-48061
published medium CVSS 3.1 · 5.9Litestar: AllowedHostsMiddleware bypasses host validation via client-controlled X-Forwarded-Host header
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| litestar-org | — | litestar< 2.22.0 | Affected | Not stated | GitHub_M |
Description
Litestar is an Asynchronous Server Gateway Interface (ASGI) framework. In versions prior to 2.22.0, an attacker can bypass the allowed hosts validation by omitting the Host header and supplying an X-Forwarded-Host header set to a whitelisted domain. The AllowedHostsMiddleware trusts the X-Forwarded-Host header as a fallback when the Host header is absent. Since X-Forwarded-Host is a client-controllable header, this enables host header injection attacks such as password reset poisoning, cache poisoning, and server-side request routing manipulation. Any application using AllowedHostsConfig is affected when deployed without a reverse proxy that strips X-Forwarded-Host, or when accepting HTTP/1.0 connections. This issue has been fixed in version 2.22.0.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 3.1
- Base score
- 5.9 / 10
- Severity
- medium
- Provider
- GitHub_M · cna
- Vector string
- CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| litestar-org | litestar | < 2.22.0 (affected) | GitHub_M · cna |
Weaknesses
1- CWE-644 CWE-644: Improper Neutralization of HTTP Headers for Scripting Syntax
References
2Provider assertions
2GitHub_M · cna
Litestar: AllowedHostsMiddleware bypasses host validation via client-controlled X-Forwarded-Host header
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 6ee245a3c3ec275d6e8f401945bf86441a59e06493ac5b3ee57c7f703be53bb4
- Ingested
- 23 Sep 2026, 09:17:17 UTC
- Source record
- Official CVE record