fix(deps): pin starlette>=1.0.1 to fix BadHost (CVE-2026-48710)#438
Conversation
📝 WalkthroughWalkthroughAdds release notes for v0.30.2 and updates dependency constraints: pins ChangesRelease 0.30.2
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
0847660 to
7b7a0cb
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@CHANGELOG.md`:
- Line 13: Update the CHANGELOG entry that pins "starlette>=1.0.1" and claims
"fastapi >=0.133" by removing or correcting the unsupported FastAPI floor:
locate the sentence containing the FastAPI floor reference (`>=0.133`) and
either replace it with the exact FastAPI release that actually adopted Starlette
1.0+ (verify via PR `#14987` / FastAPI release notes) or change the wording to
state "a FastAPI release that includes Starlette 1.0+ support" / "ensure FastAPI
is a release compatible with Starlette 1.0+" so the rationale only claims the
verified mapping rather than the unsupported `>=0.133` number.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 9c40c4cc-11fa-4f42-bbef-2e3af1cc6afb
📒 Files selected for processing (2)
CHANGELOG.mdpyproject.toml
Summary
Remediates BadHost (CVE-2026-48710), a Host-header path-confusion vulnerability in Starlette ≤ 1.0.0 that can bypass path-based authorization. The fix lives in Starlette 1.0.1.
FastAPI does not cap Starlette (even latest
0.136.3only requiresstarlette>=0.46.0), so bumping FastAPI alone does not guarantee a fixed Starlette, and an explicit floor is required.nc_py_apialso importsstarlettedirectly (_session.py,ex_app/integration_fastapi.py), so declaring it is correct regardless.Changes
pyproject.tomlstarlette>=1.0.1(the BadHost fix)fastapi>=0.133(the first FastAPI release compatible with Starlette 1.0+)CHANGELOG.md:0.30.2section:Security: the BadHost pinChanged:download_directory_as_ziparchive entry order is no longer guaranteed (server-side, per perf: remove unneeded sort in getFolderContentsById nextcloud/server#60225)The version bump (
_version.pyto0.30.2) is intentionally omitted here; it lands in the[publish]commit onmainafter merge.Compatibility
>=3.10(FastAPI 0.133+ and Starlette 1.x both require>=3.10).1.0.0to1.2.1;import nc_py_apisucceeds.