Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Repeated separators remain a cross-key deletion alias despite the new validation.
1 open finding
What changed in this PR
Hardens s3s-fs object-path handling and reports invalid batch-delete entries individually.
Changes:
- Rejects dot-segment and absolute object paths.
- Preserves valid batch deletions around rejected entries.
- Adds path-validation and deletion regressions.
| File | Description |
|---|---|
crates/s3s-fs/src/fs.rs |
Validates object paths and adds unit tests. |
crates/s3s-fs/src/s3.rs |
Returns per-key deletion errors and adds regression coverage. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Reject dot segments, repeated separators and absolute or platform paths before filesystem normalization. Batch deletion reports invalid keys individually and continues with valid entries. Assisted-by: GPT-6
overtrue
force-pushed
the
overtrue/fix-fs-object-path-aliases
branch
from
October 9, 2026 14:07
575de4f to
0d7fa1d
Compare
overtrue
marked this pull request as ready for review
October 9, 2026 21:42
Nugine
self-requested a review
October 10, 2026 04:54
This branch has not been deployed
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.

AI-assisted; human review is pending.
Summary
s3s-fsnormalizes object keys into filesystem paths, so deleting a key such asallowed/../victimcan remove a different object. Reject dot segments, repeated separators and absolute paths before resolving them, and return per-key errors in batch deletion.Changes
Behavior
The filesystem backend rejects these keys with
InvalidArgument. Windows backslash keys are also rejected because they alias forward-slash paths on that platform. Dot filenames such as.configandreport..txt, nested keys and directory objects remain accepted. Unix backslash filenames and other backends keep the existing S3 key rules.Tests
just dev: passed; 3,609 tests passed, 5 existing tests ignored.just ci-rust: passed, including codegen idempotence and the clean-tree check.cargo +nightly clippy --workspace --all-targets --all-features -- -D warnings: passed (exit 0).The local runs use macOS. Windows-specific path cases are included for CI.
AI
GPT-6 assisted with the investigation, patch and tests. The checks above ran locally; human review is pending.