Hacl: expose hashing constants
This commit is contained in:
parent
1a93df75ae
commit
a3cfcc091a
4
vendors/ocaml-hacl/src/hacl.ml
vendored
4
vendors/ocaml-hacl/src/hacl.ml
vendored
@ -50,6 +50,10 @@ module Hash = struct
|
|||||||
mutable pos : int ;
|
mutable pos : int ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let bytes = S.bytes
|
||||||
|
let blockbytes = S.blockbytes
|
||||||
|
let statebytes = S.statebytes
|
||||||
|
|
||||||
let init () =
|
let init () =
|
||||||
let state = Bigstring.create S.statebytes in
|
let state = Bigstring.create S.statebytes in
|
||||||
let buf = Bigstring.create S.blockbytes in
|
let buf = Bigstring.create S.blockbytes in
|
||||||
|
8
vendors/ocaml-hacl/src/hacl.mli
vendored
8
vendors/ocaml-hacl/src/hacl.mli
vendored
@ -31,6 +31,10 @@ module Hash : sig
|
|||||||
module SHA256 : sig
|
module SHA256 : sig
|
||||||
type state
|
type state
|
||||||
|
|
||||||
|
val bytes : int
|
||||||
|
val blockbytes : int
|
||||||
|
val statebytes : int
|
||||||
|
|
||||||
(** Incremental Interface *)
|
(** Incremental Interface *)
|
||||||
|
|
||||||
val init : unit -> state
|
val init : unit -> state
|
||||||
@ -54,6 +58,10 @@ module Hash : sig
|
|||||||
module SHA512 : sig
|
module SHA512 : sig
|
||||||
type state
|
type state
|
||||||
|
|
||||||
|
val bytes : int
|
||||||
|
val blockbytes : int
|
||||||
|
val statebytes : int
|
||||||
|
|
||||||
(** Incremental Interface *)
|
(** Incremental Interface *)
|
||||||
|
|
||||||
val init : unit -> state
|
val init : unit -> state
|
||||||
|
Loading…
Reference in New Issue
Block a user