module BLAKE256:S
BLAKE256 is the BLAKE2b hash function producing
256-bit (32-byte) digests. It is cryptographically secure,
and the digests are large enough to thwart brute-force attacks.
typet =string
The type of digests.
val hash_length : intThe length of digests, in bytes.
val compare : t -> t -> intCompare two digests, with the same specification as
compare.
val equal : t -> t -> boolTest two digests for equality.
val string : string -> tReturn the digest of the given string.
val bytes : bytes -> tReturn the digest of the given byte sequence.
val substring : string -> int -> int -> tsubstring s ofs len returns the digest of the substring
of s starting at index ofs and containing len characters.
val subbytes : bytes -> int -> int -> tsubbytes s ofs len returns the digest of the subsequence
of s starting at index ofs and containing len bytes.
val channel : in_channel -> int -> tRead characters from the channel and return their digest.
See Digest.channel for the full specification.
val file : string -> tReturn the digest of the file whose name is given.
val output : out_channel -> t -> unitWrite a digest on the given output channel.
val input : in_channel -> tRead a digest from the given input channel.
val to_hex : t -> stringReturn the printable hexadecimal representation of the given digest.
Invalid_argument if the length of the argument
is not hash_length,val of_hex : string -> tConvert a hexadecimal representation back into the corresponding digest.
Invalid_argument if the length of the argument
is not 2 * hash_length, or if the arguments contains non-hexadecimal
characters.