package core:crypto/streebog
Index
Types (1)
Constants (2)
Variables (4)
Procedures (25)
Types
Streebog_Context ¶
Streebog_Context :: struct { buffer: [64]u8, h: [64]u8, n: [64]u8, sigma: [64]u8, v_0: [64]u8, v_512: [64]u8, buf_size: u64, hash_size: int, is256: bool, }
Constants
DIGEST_SIZE_256 ¶
DIGEST_SIZE_256 :: 32
DIGEST_SIZE_512 ¶
DIGEST_SIZE_512 :: 64
Variables
STREEBOG_A ¶
STREEBOG_A: [64]u64 = …
STREEBOG_C ¶
STREEBOG_C: [12][64]u8 = …
Procedures
add_mod_512 ¶
add_mod_512 :: proc "odin" (first_vector, second_vector, result_vector: []u8) {…}
final ¶
final :: proc "odin" (ctx: ^Streebog_Context, hash: []u8) {…}
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_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_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_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_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_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_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_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_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_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_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_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: ^Streebog_Context) {…}
padding ¶
padding :: proc "odin" (ctx: ^Streebog_Context) {…}
stage2 ¶
stage2 :: proc "odin" (ctx: ^Streebog_Context, m: []u8) {…}
update ¶
update :: proc "odin" (ctx: ^Streebog_Context, data: []u8) {…}
Procedure Groups
hash_256 ¶
hash_256 :: proc{ hash_stream_256, hash_file_256, hash_bytes_256, hash_string_256, hash_bytes_to_buffer_256, hash_string_to_buffer_256, }
hash_512 ¶
hash_512 :: proc{ hash_stream_512, hash_file_512, hash_bytes_512, hash_string_512, hash_bytes_to_buffer_512, hash_string_to_buffer_512, }
Source Files
Generation Information
Generated with odin version dev-2023-03 (vendor "odin") Windows_amd64 @ 2023-03-29 21:09:05.460689000 +0000 UTC