Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions cshake/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Internal implementation by removing unnecessary buffering ([#849])
- `Rate: BlockSizes` generic parameter to `const RATE: usize` ([#849])

### Removed
- Implementations of `BlockSizeUser` ([#856])

[#849]: https://github.com/RustCrypto/hashes/pull/849
[#855]: https://github.com/RustCrypto/hashes/pull/855
[#856]: https://github.com/RustCrypto/hashes/pull/856

## 0.1.1 (2026-04-19)
### Fixed
Expand Down
12 changes: 2 additions & 10 deletions cshake/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ pub use digest;
use core::fmt;
use digest::{
CollisionResistance, CustomizedInit, ExtendableOutput, HashMarker, Update, XofReader,
common::{AlgorithmName, BlockSizeUser},
consts::{U16, U32, U136, U168},
common::AlgorithmName,
consts::{U16, U32},
};
use keccak::{Keccak, State1600};
use sponge_cursor::SpongeCursor;
Expand Down Expand Up @@ -238,11 +238,3 @@ impl CollisionResistance for CShake128 {
impl CollisionResistance for CShake256 {
type CollisionResistance = U32;
}

impl BlockSizeUser for CShake128 {
type BlockSize = U168;
}

impl BlockSizeUser for CShake256 {
type BlockSize = U136;
}
4 changes: 4 additions & 0 deletions k12/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Internal implementation by removing unnecessary buffering ([#849])
- `Rate: BlockSizes` generic parameter to `const RATE: usize` ([#849])

### Removed
- Implementations of `BlockSizeUser` ([#856])

[#849]: https://github.com/RustCrypto/hashes/pull/849
[#856]: https://github.com/RustCrypto/hashes/pull/856

## 0.4.0 (2026-04-24)
### Added
Expand Down
12 changes: 2 additions & 10 deletions k12/src/custom/borrow.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
use core::fmt;
use digest::{
CollisionResistance, ExtendableOutput, ExtendableOutputReset, HashMarker, Reset, Update,
common::{AlgorithmName, BlockSizeUser},
consts::{U16, U32, U136, U168},
common::AlgorithmName,
consts::{U16, U32},
};

use crate::{Kt, KtReader, utils::length_encode};
Expand Down Expand Up @@ -109,11 +109,3 @@ impl CollisionResistance for CustomRefKt128<'_> {
impl CollisionResistance for CustomRefKt256<'_> {
type CollisionResistance = U32;
}

impl BlockSizeUser for CustomRefKt128<'_> {
type BlockSize = U168;
}

impl BlockSizeUser for CustomRefKt256<'_> {
type BlockSize = U136;
}
12 changes: 2 additions & 10 deletions k12/src/custom/owned.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ use core::fmt;
use digest::{
CollisionResistance, CustomizedInit, ExtendableOutput, ExtendableOutputReset, HashMarker,
Reset, Update,
common::{AlgorithmName, BlockSizeUser},
consts::{U16, U32, U136, U168},
common::AlgorithmName,
consts::{U16, U32},
};

use crate::{Kt, KtReader, utils::length_encode};
Expand Down Expand Up @@ -122,11 +122,3 @@ impl CollisionResistance for CustomKt256 {
// https://www.rfc-editor.org/rfc/rfc9861.html#section-7-8
type CollisionResistance = U32;
}

impl BlockSizeUser for CustomKt128 {
type BlockSize = U168;
}

impl BlockSizeUser for CustomKt256 {
type BlockSize = U136;
}
12 changes: 2 additions & 10 deletions k12/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ pub use digest;
use core::fmt;
use digest::{
CollisionResistance, ExtendableOutput, ExtendableOutputReset, HashMarker, Reset, Update,
common::{AlgorithmName, BlockSizeUser},
consts::{U16, U32, U136, U168},
common::AlgorithmName,
consts::{U16, U32},
};

mod consts;
Expand Down Expand Up @@ -181,11 +181,3 @@ impl CollisionResistance for Kt128 {
impl CollisionResistance for Kt256 {
type CollisionResistance = U32;
}

impl BlockSizeUser for Kt128 {
type BlockSize = U168;
}

impl BlockSizeUser for Kt256 {
type BlockSize = U136;
}
13 changes: 3 additions & 10 deletions sha3/src/shake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ use digest::{
CollisionResistance, ExtendableOutput, ExtendableOutputReset, HashMarker, Reset, Update,
XofReader,
common::{
AlgorithmName, BlockSizeUser,
AlgorithmName,
hazmat::{DeserializeStateError, SerializableState, SerializedState},
},
consts::{U16, U32, U136, U168, U201},
consts::{U16, U32, U201},
};
use keccak::{Keccak, State1600};
use sponge_cursor::SpongeCursor;
Expand Down Expand Up @@ -222,14 +222,7 @@ impl<const RATE: usize> Drop for ShakeReader<RATE> {
impl CollisionResistance for Shake128 {
type CollisionResistance = U16;
}

impl CollisionResistance for Shake256 {
type CollisionResistance = U32;
}

impl BlockSizeUser for Shake128 {
type BlockSize = U168;
}

impl BlockSizeUser for Shake256 {
type BlockSize = U136;
}
4 changes: 4 additions & 0 deletions turboshake/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Internal implementation by removing unnecessary buffering ([#849])
- `Rate: BlockSizes` generic parameter to `const RATE: usize` ([#849])

### Removed
- Implementations of `BlockSizeUser` ([#856])

[#849]: https://github.com/RustCrypto/hashes/pull/849
[#856]: https://github.com/RustCrypto/hashes/pull/856

## 0.6.0 (2026-04-24)
Note: the crate was transferred to RustCrypto from https://github.com/itzmeanjan/turboshake
Expand Down
12 changes: 2 additions & 10 deletions turboshake/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ use core::fmt;
use digest::{
CollisionResistance, ExtendableOutput, ExtendableOutputReset, HashMarker, Reset, Update,
XofReader,
common::{AlgorithmName, BlockSizeUser},
consts::{U16, U32, U136, U168},
common::AlgorithmName,
consts::{U16, U32},
};

/// Number of Keccak rounds used by TurboSHAKE.
Expand Down Expand Up @@ -211,11 +211,3 @@ impl<const DS: u8> CollisionResistance for TurboShake256<DS> {
// https://www.ietf.org/archive/id/draft-irtf-cfrg-kangarootwelve-17.html#section-7-8
type CollisionResistance = U32;
}

impl<const DS: u8> BlockSizeUser for TurboShake128<DS> {
type BlockSize = U168;
}

impl<const DS: u8> BlockSizeUser for TurboShake256<DS> {
type BlockSize = U136;
}
Loading