Repository navigation
deps(harness): zip 2 -> 9 (RUSTSEC-2026-0369, RUSTSEC-2026-0548) #620
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -93,7 +93,12 @@ fn inspect_zip(bytes: &[u8], limits: &ArchiveLimits) -> Result<ArchiveListing, A | |
| if !add_entry( | ||
| &mut list, | ||
| ArchiveEntry { | ||
| name: file.name().to_string(), | ||
| // zip 9 reports a name it cannot decode instead of guessing; an | ||
| // entry whose name cannot be read refuses the archive. | ||
| name: file | ||
| .name() | ||
| .map_err(|e| ArchiveError::Invalid(e.to_string()))? | ||
|
Comment on lines
+98
to
+100
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Validate UTF-8 names before accepting them. If a UTF-8-flagged name contains
|
||
| .into_owned(), | ||
|
Comment on lines
+98
to
+101
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Preserve CP437 names in valid archives. For an entry without the UTF-8 flag, the valid CP437 bytes
|
||
| kind, | ||
| declared_size: size, | ||
| }, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Require a patched ZIP version.
version = "9"permits zip 9.0.4, which is affected by GHSA-m665-v7pm-7grj. The advisory identifies 9.0.5 as the first patched version. A resolution using 9.0.4 therefore does not meet this PR’s dependency-remediation objective. Require at least9.0.5. (github.com)