Skip to content

Bump zip from 8.6.0 to 9.0.0 - #2454

Open
dependabot[bot] wants to merge 3 commits into
mainfrom
dependabot/cargo/zip-9.0.0
Open

dependabot[bot] wants to merge 3 commits into
mainfrom
dependabot/cargo/zip-9.0.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

Bumps zip from 8.6.0 to 9.0.0.

Release notes

Sourced from zip's releases.

v9.0.0

🚀 Features

  • add ZipFileBuilder for parallelizing compression (#911)
  • add method by_index_with_data_descriptor (#994)
  • add len, is_empty and entry to ZipArchiveMetadata (#1015)
  • read data descriptor from binary (#990)
  • add comment and test for ZipStreamReader and symlinks (#985)
  • (write) add ZipWriter::hide_file for in-place entry deletion (#924)
  • add compression (#948)
  • add test to in place modification (#945)
  • move CustomExtraField to own file (#941)
  • add a test on enum size (#939)
  • use ZipFileEntry instead of ZipStreamFileMetadata (#935)
  • add ZipFileEntry with no Reader (#933)
  • change aes_mode to aes_settings() in ZipFileData (#925)
  • cleanup and harmonize extra fields (#923)
  • Rewrite zip64 extra (#913)

🐛 Bug Fixes

  • reading an empty AES entry again at EOF returns Ok(0) (#1024)
  • reject ZIP64 sizes that overflow u64 when computing data end offsets (#1036)
  • apply central directory metadata in ZipStreamReader, only to written entries (#1030)
  • consume the whole extended timestamp field in the central header (#1016)
  • parse the central header of the extended timestamp (#1002)
  • don't pre-allocate the declared size in the legacy decoders (#991)
  • Symlink with very large declared size could lead to out-of-memory panic (#984)
  • copy extra fields in raw_copy_file (#955) (#982)
  • add unix_mode when copy_raw_file (#981)
  • rewrite documentation of add_symlink_from_path (#979)
  • ignore a ZIP64 extra field that no sentinel asked for (#962)
  • do not set data descriptor if directory (#973)
  • expose flags function for easier access (#972)
  • preserve unix permission in raw_copy_file (#956)
  • clippy warning on nightly (#960)
  • remove extra alloc used to copy (#938)
  • lazy allocation on error case (#937)
  • fix data alignment (#929)

🚜 Refactor

  • move extract to own file (#1009)
  • cleanup permissions related code (#961)
  • remove feature gate (#949)
  • create ZipFileFlags to wrap flags (#947)
  • remove unused trait (#946)
  • access crate::format with zip::unstable::format (#944)
  • harmonize functions to format/functions.rs (#943)
  • rewrite make_reader() function (#936)

... (truncated)

Changelog

Sourced from zip's changelog.

9.0.0 - 2026-10-08

🚀 Features

  • add ZipFileBuilder for parallelizing compression (#911)
  • add method by_index_with_data_descriptor (#994)
  • add len, is_empty and entry to ZipArchiveMetadata (#1015)
  • read data descriptor from binary (#990)
  • add comment and test for ZipStreamReader and symlinks (#985)
  • (write) add ZipWriter::hide_file for in-place entry deletion (#924)
  • add compression (#948)
  • use ZipFileEntry instead of ZipStreamFileMetadata (#935)
  • add ZipFileEntry with no Reader (#933)
  • change aes_mode to aes_settings() in ZipFileData (#925)

🐛 Bug Fixes

  • reading an empty AES entry again at EOF returns Ok(0) (#1024)
  • reject ZIP64 sizes that overflow u64 when computing data end offsets (#1036)
  • apply central directory metadata in ZipStreamReader, only to written entries (#1030)
  • consume the whole extended timestamp field in the central header (#1016)
  • parse the central header of the extended timestamp (#1002)
  • don't pre-allocate the declared size in the legacy decoders (#991)
  • Symlink with very large declared size could lead to out-of-memory panic (#984)
  • copy extra fields in raw_copy_file (#955) (#982)
  • add unix_mode when copy_raw_file (#981)
  • rewrite documentation of add_symlink_from_path (#979)
  • ignore a ZIP64 extra field that no sentinel asked for (#962)
  • do not set data descriptor if directory (#973)
  • expose flags function for easier access (#972)
  • preserve unix permission in raw_copy_file (#956)
  • clippy warning on nightly (#960)
  • remove extra alloc used to copy (#938)
  • lazy allocation on error case (#937)
  • fix data alignment (#929)

🚜 Refactor

  • move extract to own file (#1009)
  • cleanup permissions related code (#961)
  • remove feature gate (#949)
  • create ZipFileFlags to wrap flags (#947)
  • remove unused trait (#946)
  • access crate::format with zip::unstable::format (#944)
  • harmonize functions to format/functions.rs (#943)
  • rewrite make_reader() function (#936)
  • simplify initialize_local_block (#934)
  • move write options to write/options.rs (#931)
  • move spec to format (#932)
  • move Magic to format (#930)

... (truncated)

Commits
  • 2b1c424 chore: release v9.0.0 (#940)
  • 759993f fix: reading an empty AES entry again at EOF returns Ok(0) (#1024)
  • acd09d3 fix: reject ZIP64 sizes that overflow u64 when computing data end offsets (#1...
  • 8eab8e3 ci(deps): bump codelytv/pr-size-labeler from 1.11.0 to 1.11.1 (#1034)
  • 53bdadc fix: apply central directory metadata in ZipStreamReader, only to written ent...
  • f86c8be ci: Add endianness_miri as requirement before build_and_test (#1037)
  • a72b210 chore: Fix high-level symlink extraction logic, disable some tests in miri, a...
  • 96c1693 test: Fix typo in comment for symlink test
  • 2a87f64 Merge commit from fork
  • a82b390 ci: Fix: Change trigger event for size_labels.yml to pull_request_target (#1032)
  • Additional commits viewable in compare view

[[Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zip&package-manager=cargo&previous-version=8.6.0&new-version=9.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting ·@·d·ependabot r·ebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • ·@·d·ependabot r·ebase will rebase this PR
  • ·@·d·ependabot r·ecreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • ·@·d·ependabot i·gnore t·his major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • ·@·d·ependabot i·gnore t·his minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • ·@·d·ependabot i·gnore t·his dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    You can disable automated security fix PRs for this repo from the Security Alerts page.

Generated by Claude Code

Bumps [zip](https://github.com/zip-rs/zip2) from 8.6.0 to 9.0.0.
- [Release notes](https://github.com/zip-rs/zip2/releases)
- [Changelog](https://github.com/zip-rs/zip2/blob/master/CHANGELOG.md)
- [Commits](zip-rs/zip2@v8.6.0...v9.0.0)

---
updated-dependencies:
- dependency-name: zip
  dependency-version: 9.0.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file rust Pull requests that update rust code labels Dec 2, 2026
@socket-security

socket-security Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcargo/​zip@​8.6.0 ⏵ 9.0.0100 +12599 +6100100

View full report

@socket-security-staging

socket-security-staging Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcargo/​zip@​8.6.0 ⏵ 9.0.0100 +12599 +6100100

View full report

Assisted-by: Claude Code:claude-opus-5-5
zip 9.0.0 makes ZipFile::name(), ZipArchive::file_names() and
name_for_index() return a Result. The error comes only from decoding a
non-UTF-8 name as CP437, and that branch cannot fail on real input, so
each call site passes the error up the way it already reports an
unreadable entry. A jar whose name cannot be decoded is still read raw,
and counts as possibly signed so it gets the stricter checks. Tests
unwrap.

Assisted-by: Claude Code:claude-opus-5-5
@mikolalysenko

Copy link
Copy Markdown
Collaborator

[agent] PR shepherd: this major bump needs a decision from a person.

What broke. zip 9.0.0 makes ZipFile::name(), ZipArchive::file_names() and name_for_index() return a Result, so socket-patch-core stopped compiling (clippy and ci-ok were red). I pushed 58dfab1, which merges main and moves every call site to the fallible API. The error can only come from the CP437 branch on input that can't occur, so no archive that was accepted before is refused now. cargo clippy --locked --workspace --all-features -- -D warnings passes locally.

What still fails, and why it is a question rather than a fix. zip 9 also changes how it decodes a name whose entry doesn't set the UTF-8 flag. 8.x decoded it as CP437. 9.0 tries UTF-8 first and falls back to CP437 only when the bytes aren't valid UTF-8 (ZipFileData::name in zip-9.0.0/src/types.rs). patch::jar_members::tests::a_member_is_found_by_the_raw_bytes_of_its_name checks that old premise and now fails: the reader returns org/x/Ünï.class where it used to return the CP437 spelling.

  • For jars this brings zip closer to what a JVM reads, so the raw-bytes fallback in Jar::member_names is hit less often.
  • For wheels and other archives, Python's zipfile still decodes an unflagged name as CP437. Paths that verify.rs, pypi_uv.rs and wheel_record.rs read from such an entry could now differ from what pip extracts.

Question: should socket-patch take zip 9's UTF-8-first decoding? If yes, the jar test's premise needs rewriting, and any wheel path check needs to read raw names (name_raw()) and decode them as CP437 itself. If no, keep zip at 8.x and tell Dependabot to ignore 9.x. I didn't change the test, because weakening it would hide exactly this difference.


Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent:needs-human dependencies Pull requests that update a dependency file rust Pull requests that update rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants