Skip to content

Upgrade zstd to 0.14 (zstd-safe 8) #170

Done

Description

@WingZer0o

Summary

Crate Current Target
zstd 0.13.6 0.14.5 (zstd-safe 8)

This is the decompression path we hardened in #107 and #108, so it needs a careful review rather than a plain bump.

Work

  • src/compression/zstd.rs: check zstd::stream::read::Decoder::with_buffer, the decoder window-log cap (2^27 bytes), copy_encode, and the output cap DEFAULT_MAX_DECOMPRESSED_SIZE (64 MiB) / decompress_with_limit.
  • src/error.rs: CasError::DecompressionLimitExceeded mapping stays the same. The CasError code mapping is an append-only ABI contract.
  • Keep default-features = false (no legacy pre-v0.8 frame decoders, Security (High): compression::zstd::decompress has no output size limit (decompression bomb) #107). Confirm 0.14 hasn't renamed or moved features.
  • Update the version-floor comment in Cargo.toml (it refers to RUSTSEC-2026-0391/0398/0403/0410 via zstd-safe 7.4.2 / zstd-sys 2.2.0) to describe the new floor.
  • Tests: decompression-bomb and limit tests still pass, and frames compressed by 0.7.0 still decompress.

Acceptance criteria

  • cargo build --release --locked and cargo test --release --locked pass on Linux, Windows and macOS.
  • NIST/FIPS KATs in tests/data/ and the Wycheproof tests still pass.
  • docs/EXAMPLES.md updated if any public signature changes.
  • PR title follows Conventional Commits (chore(deps): …, or feat!: / fix!: if the public API breaks). Don't bump the crate version or edit CHANGELOG.md by hand.

Activity

  1. added
    dependencies
    rust
    on Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    dependenciesrust

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions