Skip to content

std.crypto.hash.sha3: add TurboSHAKE #14824

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 7, 2023
Merged

Conversation

jedisct1
Copy link
Contributor

@jedisct1 jedisct1 commented Mar 6, 2023

TurboSHAKE is a round-reduced version of SHAKE which is being standardized by CFRG.

It offers the same practical security as SHA3 and SHAKE. Its security builds up on the scrutiny that Keccak has received since its publication.

Unlike SHA3 (but not unlike SHAKE), the output can be of any size.

TurboSHAKE also offers higher performance - It is nearly twice as fast as SHAKE.

         sha3-256:        571 MiB/s
         sha3-512:        316 MiB/s
        shake-128:        723 MiB/s
   turboshake-128:       1334 MiB/s

Why it matters: TurboSHAKE is the fastest secure hash function we'll have in Zig when compiling for the baseline CPU.

Since we already had SHAKE, TurboSHAKE is a trivial addition, and it will immediately benefit from the further optimizations we'll do to Keccak.

TurboSHAKE is a round-reduced version of SHAKE which is being
standardized by CFRG.

It offers the same practical security as SHA3 and SHAKE. Its security
builds up on the scrutiny that Keccak has received since its
publication.

Unlike SHA3 (but not unlike SHAKE), the output can be of any size.

TurboSHAKE also offers higher performance - It is nearly twice as
fast as SHAKE.

         sha3-256:        571 MiB/s
         sha3-512:        316 MiB/s
        shake-128:        723 MiB/s
   turboshake-128:       1334 MiB/s

Why it matters: TurboSHAKE is the fastest secure hash function we'll
have in Zig when compiling for the `baseline` CPU.

Since we already had SHAKE, TurboSHAKE is a trivial addition, and
it will immediately benefit from the further optimizations we'll
do to Keccak.
@jedisct1 jedisct1 merged commit 36d47dd into ziglang:master Mar 7, 2023
@jedisct1 jedisct1 deleted the turboshake branch March 7, 2023 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant