Repository navigation
chore(deps): move to the digest 0.11 RustCrypto stack (hashes, argon2/scrypt, ed25519-dalek 3, zstd 0.14) - #177
Merged
Merged
Conversation
Move the hash, HMAC and PBKDF2 crates onto the digest 0.11 stack: sha2 0.10 -> 0.11.2, sha3 0.10 -> 0.12.0, blake2 0.10 -> 0.11.0, hmac 0.12 -> 0.13.0, pbkdf2 0.12 -> 0.13.0. - Drop the `sha2-hkdf` alias now that `sha2` itself is 0.11, and switch the `sha2_hkdf::` imports in src/kdf/hkdf.rs, src/key_exchange/x25519.rs and the key_exchange/symmetric tests back to `sha2::`. - hmac 0.13 moved `new_from_slice` to the `KeyInit` trait; import it. - sha3 0.12 no longer exposes a block-level core, so `Sha3_256` does not satisfy `EagerHash` and can't be used with `Hmac` / `pbkdf2_hmac_array`. PBKDF2-HMAC-SHA3-256 now uses `pbkdf2::<SimpleHmac<Sha3_256>>`, which computes the same HMAC and writes straight into the returned Vec. The PBKDF2 known-answer vectors pass unchanged. - Targeted lockfile refreshes: hpke 0.15.2, uuid 1.29.3, zeroize 1.9.2 (zeroize_derive 1.5.0). No public API changes. Part of #167 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Move zstd 0.13.6 -> 0.14.5 (zstd-safe 7.4.2 -> 8.4.0; zstd-sys stays 2.2.0+zstd.1.6.0) with a targeted `cargo update -p zstd`. - Keep `default-features = false`: 0.14 has the same default set (`legacy`, `arrays`, `zdict_builder`) and only adds opt-in features (`vendored`, `cmake`, `rust-backend`, `with-rust-allocator`), so the pre-v0.8 legacy decoders stay out (#107). - Raise the floor to 0.14.5 and rewrite the Cargo.toml comment for it. - The decompression path is unchanged: `read::Decoder::with_buffer`, `window_log_max` (still sets ZSTD_d_windowLogMax) and the `take(limit + 1)` output cap behave as before. - Add a fixture frame compressed by cas-lib 0.7.1 (zstd 0.13.6) and check it still decompresses, and that the output limit still applies to it. Part of #170. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- ed25519-dalek 2.2 -> 3.0 (curve25519-dalek 5, sha2 0.11). Drop the `rand_core` feature: key generation now draws the 32-byte secret with getrandom::fill into a Zeroizing buffer and builds the key with SigningKey::from_bytes, which is what SigningKey::generate does. - Both verify functions keep verify_strict (#118); its logic is unchanged between 2.2.0 and 3.0.0. - Dev-dependency curve25519-dalek 4 -> 5; the tests need no API changes. - Add RFC 8032 section 7.1 known-answer tests (TEST 1-3) that pin the secret-key, public-key and signature encodings. They pass on both ed25519-dalek 2.2.0 and 3.0.0. curve25519-dalek 4.1.3 and fiat-crypto 0.2 leave the dependency tree. Part of #169 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…c and pbkdf2 to digest 0.11 chore(deps): upgrade sha2, sha3, blake2, hmac and pbkdf2 to digest 0.11
Both move to password-hash 0.6 (digest 0.11, rand_core 0.10 / getrandom 0.4). - argon2/scrypt: salts are now drawn by the crates' `hash_password` (password-hash's `try_generate_salt`, getrandom), so an RNG failure maps to CasError::PasswordHashingFailed instead of panicking. - scrypt 0.12 has no default features: enable `phc` and `getrandom`. Pin the default cost (ln=17, r=8, p=1) and the 32-byte output explicitly. - argon2 defaults (Argon2id v19, m=19456, t=2, p=1, 32-byte output) are unchanged in 0.6. - pbkdf2::derivation generates 16 bytes with getrandom and returns their 22-character PHC "B64" salt string, the same shape as before. - argon2 KDF salt generation stays on rand 0.8 (rand is #172). Adds regression tests that verify argon2 and scrypt PHC strings made by cas-lib 0.7.1 (argon2 0.5.3 / scrypt 0.11.0), and tests that pin the default parameters and the pbkdf2 salt shape. Part of #168 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d curve25519-dalek to 5 chore(deps): upgrade ed25519-dalek to 3.0 and curve25519-dalek to 5
Resolve the adjacent-line Cargo.toml conflict: keep #175's getrandom comment (now also naming PBKDF2 salts) and this branch's scrypt 0.12 line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
chore(deps): upgrade zstd to 0.14
…t to 0.12 chore(deps): upgrade argon2 to 0.6 and scrypt to 0.12
WingZer0o
marked this pull request as ready for review
November 27, 2026 16:14
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.
Summary
Moves cas-lib off the old RustCrypto generation (digest 0.10 / rand_core 0.6) onto the current one (digest 0.11 / rand_core 0.10), via one child PR per issue, each reviewed, CI-tested on Linux/Windows/macOS and merged into this branch:
sha2-hkdfalias; lockfile refresh (hpke 0.15.2, uuid 1.29.3, zeroize 1.9.2)Compatibility
docs/EXAMPLES.mduntouched.compressoutput bytes differ for small inputs, since zstd 0.14 records the content size in the frame header; still standard frames.PasswordHashingFailed; zstd allocation failures return errors.get_ed25519_key_pair()still panics if the OS RNG fails (unchanged behaviour, now documented).Not in this PR
cargo tree -iconfirms every remaining digest 0.10 / rand_core 0.6 / getrandom 0.2 / signature 2 crate is pulled in only by slh-dsa 0.0.3 or rand 0.8.Testing
Final branch (
6fa9f6a, all four child PRs merged) locally on Windows:cargo build --release --locked(no warnings),cargo test --release --locked234 passed / 0 failed,cargo audit --deny unsound --deny yankedclean. Each child PR passed CI on Linux, Windows and macOS (one earlier Windows run of #176 failed on acurlcrash while downloading Wycheproof vectors, unrelated to the change; the re-run passed).Closes #167
Closes #168
Closes #169
Closes #170
🤖 Generated with Claude Code