Botan

MDx Hash Function

License
Botan is released under the Simplified BSD License (see LICENSE.md)

abstract class  MDxHashFunction: botan.hash.hash.HashFunction;

MDx Hash Function Base Class


this(size_t block_len, bool byte_end, bool bit_end, size_t cnt_size = 8);

Parameters
size_t block_len is the number of bytes per block
bool byte_end specifies if the hash uses big-endian bytes
bool bit_end specifies if the hash uses big-endian bits
size_t cnt_size specifies the size of the counter var in bytes

protected abstract void  compressN(const(ubyte)* blocks, size_t block_n);

Run the hash's compression function over a set of blocks

Parameters
const(ubyte)* blocks the input
size_t block_n the number of blocks

protected abstract void  copyOut(ubyte* buffer);

Copy the output to the buffer

Parameters
ubyte* buffer to put the output into

protected final void  writeCount(ubyte* output);

Write the count, if used, to this spot

Parameters
ubyte* output where to write the counter to