core/crypto/sha3
sha3
Types
1Constants
8BLOCK_SIZE_224
BLOCK_SIZE_224 :: RATE_224SourceBLOCK_SIZE_224 is the SHA3-224 block size in bytes.
BLOCK_SIZE_256
BLOCK_SIZE_256 :: RATE_256SourceBLOCK_SIZE_256 is the SHA3-256 block size in bytes.
BLOCK_SIZE_384
BLOCK_SIZE_384 :: RATE_384SourceBLOCK_SIZE_384 is the SHA3-384 block size in bytes.
BLOCK_SIZE_512
BLOCK_SIZE_512 :: RATE_512SourceBLOCK_SIZE_512 is the SHA3-512 block size in bytes.
DIGEST_SIZE_224
DIGEST_SIZE_224 :: 28SourceDIGEST_SIZE_224 is the SHA3-224 digest size.
DIGEST_SIZE_256
DIGEST_SIZE_256 :: 32SourceDIGEST_SIZE_256 is the SHA3-256 digest size.
DIGEST_SIZE_384
DIGEST_SIZE_384 :: 48SourceDIGEST_SIZE_384 is the SHA3-384 digest size.
DIGEST_SIZE_512
DIGEST_SIZE_512 :: 64SourceDIGEST_SIZE_512 is the SHA3-512 digest size.
Procedures
8clone
clone :: proc(ctx: ^Context, other: ^Context)Sourceclone clones the Context other into ctx.
final
final :: proc(ctx: ^Context, hash: []u8, finalize_clone: bool)Sourcefinal finalizes the Context, writes the digest to hash, and calls reset on the Context.
If and only if (⟺) finalize_clone is set, final will work on a copy of the Context, which is useful for for calculating rolling digests.
init_224
init_224 :: proc(ctx: ^Context)Sourceinit_224 initializes a Context for SHA3-224.
init_256
init_256 :: proc(ctx: ^Context)Sourceinit_256 initializes a Context for SHA3-256.
init_384
init_384 :: proc(ctx: ^Context)Sourceinit_384 initializes a Context for SHA3-384.
init_512
init_512 :: proc(ctx: ^Context)Sourceinit_512 initializes a Context for SHA3-512.
reset
reset :: proc(ctx: ^Context)Sourcereset sanitizes the Context. The Context must be re-initialized to be used again.
update
update :: proc(ctx: ^Context, data: []u8)Sourceupdate adds more data to the Context.