Repository navigation
Conversation
Signed-off-by: Neemias Cormino Manso <130704790+n33miaz@users.noreply.github.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
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.
What changes
crates/launcher/src/verify.rs: inverify_package, cap the per-file read limit passed tohash_filetolimits.max_file_bytes.min(limits.max_total_bytes.saturating_sub(total)), preserving the existingVerifyError::TooLargediagnostic.crates/launcher/src/verify_tests.rs:refuses_case_variant_extra_file_alongside_listed_fileto detect filesystem case sensitivity at runtime (dir.0.join("bin/DAEMON").exists()) and skip cleanly on case-insensitive filesystems instead of gating ontarget_os = "linux".refuses_file_exceeding_remaining_total_budgetto verifyVerifyError::TooLargewhen a file exceedsmax_total_byteswhile staying undermax_file_bytes.Why
verify_packageread up tolimits.max_file_bytesbefore checkingtotal > limits.max_total_bytes, allowing a file larger than the remaining budget to be read in full.refuses_case_variant_extra_file_alongside_listed_fileassumed Linux implies a case-sensitive filesystem.How to validate
cargo test -p ads-launchercargo fmt --all --checkcargo clippy -p ads-launcher --all-targets -- -D warningsRegression test: crates/launcher/src/verify_tests.rs::refuses_file_exceeding_remaining_total_budget fails without the fix
Refs #589