fix(deps): update dependency starlette to v1 [security]#142
Open
renovate[bot] wants to merge 1 commit into
Open
fix(deps): update dependency starlette to v1 [security]#142renovate[bot] wants to merge 1 commit into
renovate[bot] wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
<1.0.0,>=0.16.0→<1.1.0,>=1.0.1Starlette has missing Host header validation that poisons request.url.path, bypassing path-based security checks
CVE-2026-48710 / GHSA-86qp-5c8j-p5mr
More information
Details
Summary
In affected versions, the HTTP
Hostrequest header was not validated before being used to reconstructrequest.url. Because the routing algorithm relies on the raw HTTP path whilerequest.urlis rebuilt from theHostheader, a malformed header could makerequest.url.pathdiffer from the path that was actually requested. Middleware and endpoints that apply security restrictions based onrequest.url(rather than the rawscopepath) could therefore be bypassed.Details
When a client requests
http://example.com/foo, it sends:Affected versions reconstructed the URL by concatenating
http://{host}{path}and re-parsing the result. TheHostvalue is only valid as auri-host [ ":" port ]per RFC 9112 §3.2, whereuri-hostfollows the restrictedhostgrammar of RFC 3986 §3.2.2. When it contains characters outside that grammar - notably/,?, or#- those characters move the path/query/fragment boundaries during re-parsing, so the parsedrequest.url.pathno longer matches the path the server actually received. For example:reconstructs to
http://example.com/abc?bar=/foo, whose parsedpathis/abc- even though routing used the real path/foo. The router still dispatches to/fooand the endpoint executes, but any middleware or code that readsrequest.url.pathsees/abc, so path-based authorization checks can be bypassed.Impact
Any application running an affected version that relies on
request.url(orrequest.url.path) for security-sensitive decisions is affected. The most common case is middleware that gates access to certain path prefixes based onrequest.url.path. Deployments fronted by a proxy or load balancer are mitigated only if that proxy rejects or normalizes the malformedHostheader before forwarding and the application does not trust attacker-controlled host headers (e.g.X-Forwarded-Host) elsewhere.Mitigation
Upgrade to a patched version, which validates the
Hostheader against the grammar of RFC 9112 §3.2 / RFC 3986 §3.2.2 when constructingrequest.urland falls back toscope["server"]for malformed values.Severity
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:NReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Release Notes
Kludex/starlette (starlette)
v1.0.1: Version 1.0.1Compare Source
What's Changed
Hostheader when constructingrequest.urlby @Kludex in #3279Full Changelog: Kludex/starlette@1.0.0...1.0.1
v1.0.0: Version 1.0.0Compare Source
Starlette 1.0 is here! 🎉
After nearly eight years since its creation, Starlette has reached its first stable release.
A special thank you to @lovelydinosaur, the creator of Starlette, Uvicorn, HTTPX and MkDocs, whose work helped to lay the foundation for the modern async Python ecosystem. 🙏
Thank you to @adriangb, @graingert, @agronholm, @florimondmanca, @aminalaee, @tiangolo, @alex-oleshkevich, @abersheeran, and @uSpike for helping make Starlette what it is today. And to all my sponsors - especially @tiangolo, @huggingface, and @elevenlabs - thank you for your support!
Thank you to all 290+ contributors who have shaped Starlette over the years! ❤️
Read more on the blog post.
Check out the full release notes at https://www.starlette.io/release-notes/#100-march-22-2026
Full Changelog: Kludex/starlette@1.0.0rc1...1.0.0
v0.52.1: Version 0.52.1Compare Source
What's Changed
typing_extensionsin older Python versions by @Kludex in #3109Full Changelog: Kludex/starlette@0.52.0...0.52.1
v0.52.0: Version 0.52.0Compare Source
In this release,
Statecan be accessed using dictionary-style syntax for improved type safety (#3036).See Accessing State for more details.
Full Changelog: Kludex/starlette@0.51.0...0.52.0
v0.51.0: Version 0.51.0Compare Source
Added
allow_private_networkinCORSMiddleware#3065.Changed
DeprecationWarningfor wsgi module #3082.New Contributors
Full Changelog: Kludex/starlette@0.50.0...0.51.0
v0.50.0: Version 0.50.0Compare Source
Removed
Full Changelog: Kludex/starlette@0.49.3...0.50.0
v0.49.3: Version 0.49.3Compare Source
Fixed
Middlewaretype #3059.Full Changelog: Kludex/starlette@0.49.2...0.49.3
v0.49.2: Version 0.49.2Compare Source
Fixed
if-modified-sinceheader ifif-none-matchis present inStaticFiles#3044.Full Changelog: Kludex/starlette@0.49.1...0.49.2
v0.49.1: Version 0.49.1Compare Source
This release fixes a security vulnerability in the parsing logic of the
Rangeheader inFileResponse.You can view the full security advisory: GHSA-7f5h-v6xp-fcq8
Fixed
Full Changelog: Kludex/starlette@0.49.0...0.49.1
v0.49.0: Version 0.49.0Compare Source
Added
encodingparameter toConfigclass #2996.Request.cookies#3029.Literaltype forWebSocketEndpointencoding values #3027.Changed
Middlewarewhen usingBaseHTTPMiddleware#2976.New Contributors
Full Changelog: Kludex/starlette@0.48.0...0.49.0
v0.48.0: Version 0.48.0Compare Source
Added
Changed
New Contributors
Full Changelog: Kludex/starlette@0.47.3...0.48.0
v0.47.3: Version 0.47.3Compare Source
Fixed
asyncio.iscoroutinefunctionfor Python 3.12 and older by @mjpieters in encode#2984New Contributors
Full Changelog: Kludex/starlette@0.47.2...0.47.3
v0.47.2Compare Source
Fixed
UploadFilecheck for future rollover #2962.New Contributors
Full Changelog: Kludex/starlette@0.47.1...0.47.2
v0.47.1: Version 0.47.1Compare Source
Fixed
SelfinTestClient.__enter__#2951Full Changelog: Kludex/starlette@0.47.0...0.47.1
v0.47.0: Version 0.47.0Compare Source
Added
pathsendextension #2671.partitionedattribute toResponse.set_cookie#2501.Changed
methodsparameter type fromlist[str]toCollection[str]#2903.import typingbyfrom typing import ...in the whole codebase #2867.Fixed
ExceptionMiddleware.http_exceptionas async to prevent thread creation #2922.New Contributors
Full Changelog: Kludex/starlette@0.46.2...0.47.0
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.