package core:crypto/jh

Types

Jh_Context ¶

Jh_Context :: struct {
	hashbitlen:    int,
	databitlen:    u64,
	buffer_size:   u64,
	H:             [128]u8,
	A:             [256]u8,
	roundconstant: [64]u8,
	buffer:        [64]u8,
}

Constants

DIGEST_SIZE_224 ¶

DIGEST_SIZE_224 :: 28

DIGEST_SIZE_256 ¶

DIGEST_SIZE_256 :: 32

DIGEST_SIZE_384 ¶

DIGEST_SIZE_384 :: 48

DIGEST_SIZE_512 ¶

DIGEST_SIZE_512 :: 64

Variables

ROUNDCONSTANT_ZERO ¶

ROUNDCONSTANT_ZERO: [64]u8 = …

SBOX ¶

SBOX: [2][16]u8 = …

Procedures

E8 ¶

E8 :: proc "odin" (ctx: ^Jh_Context) {…}

E8_finaldegroup ¶

E8_finaldegroup :: proc "odin" (ctx: ^Jh_Context) {…}

E8_initialgroup ¶

E8_initialgroup :: proc "odin" (ctx: ^Jh_Context) {…}

F8 ¶

F8 :: proc "odin" (ctx: ^Jh_Context) {…}

R8 ¶

R8 :: proc "odin" (ctx: ^Jh_Context) {…}

final ¶

final :: proc "odin" (ctx: ^Jh_Context, hash: []u8) {…}

hash_bytes_224 ¶

hash_bytes_224 :: proc "odin" (data: []u8) -> [28]u8 {…}
 

hash_bytes_224 will hash the given input and return the computed hash

hash_bytes_256 ¶

hash_bytes_256 :: proc "odin" (data: []u8) -> [32]u8 {…}
 

hash_bytes_256 will hash the given input and return the computed hash

hash_bytes_384 ¶

hash_bytes_384 :: proc "odin" (data: []u8) -> [48]u8 {…}
 

hash_bytes_384 will hash the given input and return the computed hash

hash_bytes_512 ¶

hash_bytes_512 :: proc "odin" (data: []u8) -> [64]u8 {…}
 

hash_bytes_512 will hash the given input and return the computed hash

hash_bytes_to_buffer_224 ¶

hash_bytes_to_buffer_224 :: proc "odin" (data, hash: []u8) {…}
 

hash_bytes_to_buffer_224 will hash the given input and write the computed hash into the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_bytes_to_buffer_256 ¶

hash_bytes_to_buffer_256 :: proc "odin" (data, hash: []u8) {…}
 

hash_bytes_to_buffer_256 will hash the given input and write the computed hash into the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_bytes_to_buffer_384 ¶

hash_bytes_to_buffer_384 :: proc "odin" (data, hash: []u8) {…}
 

hash_bytes_to_buffer_384 will hash the given input and write the computed hash into the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_bytes_to_buffer_512 ¶

hash_bytes_to_buffer_512 :: proc "odin" (data, hash: []u8) {…}
 

hash_bytes_to_buffer_512 will hash the given input and write the computed hash into the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_file_224 ¶

hash_file_224 :: proc "odin" (hd: os.Handle, load_at_once: bool = false) -> ([28]u8, bool) {…}
 

hash_file_224 will read the file provided by the given handle and compute a hash

hash_file_256 ¶

hash_file_256 :: proc "odin" (hd: os.Handle, load_at_once: bool = false) -> ([32]u8, bool) {…}
 

hash_file_256 will read the file provided by the given handle and compute a hash

hash_file_384 ¶

hash_file_384 :: proc "odin" (hd: os.Handle, load_at_once: bool = false) -> ([48]u8, bool) {…}
 

hash_file_384 will read the file provided by the given handle and compute a hash

hash_file_512 ¶

hash_file_512 :: proc "odin" (hd: os.Handle, load_at_once: bool = false) -> ([64]u8, bool) {…}
 

hash_file_512 will read the file provided by the given handle and compute a hash

hash_stream_224 ¶

hash_stream_224 :: proc "odin" (s: io.Stream) -> ([28]u8, bool) {…}
 

hash_stream_224 will read the stream in chunks and compute a hash from its contents

hash_stream_256 ¶

hash_stream_256 :: proc "odin" (s: io.Stream) -> ([32]u8, bool) {…}
 

hash_stream_256 will read the stream in chunks and compute a hash from its contents

hash_stream_384 ¶

hash_stream_384 :: proc "odin" (s: io.Stream) -> ([48]u8, bool) {…}
 

hash_stream_384 will read the stream in chunks and compute a hash from its contents

hash_stream_512 ¶

hash_stream_512 :: proc "odin" (s: io.Stream) -> ([64]u8, bool) {…}
 

hash_stream_512 will read the stream in chunks and compute a hash from its contents

hash_string_224 ¶

hash_string_224 :: proc "odin" (data: string) -> [28]u8 {…}
 

hash_string_224 will hash the given input and return the computed hash

hash_string_256 ¶

hash_string_256 :: proc "odin" (data: string) -> [32]u8 {…}
 

hash_string_256 will hash the given input and return the computed hash

hash_string_384 ¶

hash_string_384 :: proc "odin" (data: string) -> [48]u8 {…}
 

hash_string_384 will hash the given input and return the computed hash

hash_string_512 ¶

hash_string_512 :: proc "odin" (data: string) -> [64]u8 {…}
 

hash_string_512 will hash the given input and return the computed hash

hash_string_to_buffer_224 ¶

hash_string_to_buffer_224 :: proc "odin" (data: string, hash: []u8) {…}
 

hash_string_to_buffer_224 will hash the given input and assign the computed hash to the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_string_to_buffer_256 ¶

hash_string_to_buffer_256 :: proc "odin" (data: string, hash: []u8) {…}
 

hash_string_to_buffer_256 will hash the given input and assign the computed hash to the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_string_to_buffer_384 ¶

hash_string_to_buffer_384 :: proc "odin" (data: string, hash: []u8) {…}
 

hash_string_to_buffer_384 will hash the given input and assign the computed hash to the second parameter. It requires that the destination buffer is at least as big as the digest size

hash_string_to_buffer_512 ¶

hash_string_to_buffer_512 :: proc "odin" (data: string, hash: []u8) {…}
 

hash_string_to_buffer_512 will hash the given input and assign the computed hash to the second parameter. It requires that the destination buffer is at least as big as the digest size

init ¶

init :: proc "odin" (ctx: ^Jh_Context) {…}

update ¶

update :: proc "odin" (ctx: ^Jh_Context, data: []u8) {…}

update_roundconstant ¶

update_roundconstant :: proc "odin" (ctx: ^Jh_Context) {…}

Procedure Groups

Source Files

Generation Information

Generated with odin version dev-2023-03 (vendor "odin") Windows_amd64 @ 2023-03-29 21:09:05.455105100 +0000 UTC