Repository navigation
Fix path traversal when downloading objects to a directory - #2206
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## trunk #2206 +/- ##
==========================================
+ Coverage 83.56% 83.57% +0.01%
==========================================
Files 352 352
Lines 82069 82082 +13
Branches 8800 8802 +2
==========================================
+ Hits 68579 68594 +15
+ Misses 10613 10612 -1
+ Partials 2877 2876 -1
🚀 New features to boost your workflow:
|
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.
Fix path traversal when downloading objects to a directory
Description
Fix path traversal when downloading objects to a directory
When download_object saves an object to a directory, it now uses only the object’s basename as the local filename. This prevents provider-supplied object names containing path traversal components from writing files outside the intended destination directory.
Adds a regression test covering an object name with ../ components.
Status
Checklist (tick everything that applies)