-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Refactor Keccak256Transcript and update tests (#191)
* refactor: change the order of Keccak Squeeze's input - Redefine the input sequence for the `compute_updated_state` within the `squeeze` method in `Keccak256Transcript`. - Modify the expected hash outcomes in the `test_keccak_transcript_with` function in `keccak.rs`. * refactor: Refactor Keccak256Transcript - Replaced the transcript vector with a `Keccak256` instance, improving data handling and memory usage. - Refactored `compute_updated_state` to work directly on a given `Keccak256` instance, reducing unnecessary object creation. - this change roughly amounts to putting the transcript at the start of squeeze's input array * refactor: simplify hasher_lo, hasher_hi * test: Enhance Keccak transcript with backward compatibility test - Introduces new helper functions to assist with the backward-compatibility intesting process (`compute_updated_state_for_testing`, `squeeze_for_testing`) - Adds a new test `test_keccak_transcript_incremental_vs_explicit` that checks for consistency between incremental and independent explicit transcript computations
- Loading branch information
1 parent
4b077bc
commit 0664244
Showing
1 changed file
with
111 additions
and
22 deletions.
There are no files selected for viewing
This file contains 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