blake2bLong

private fnubyte[] blake2bLong(const(ubyte)[] input, uint outLen)

Computes the variable-length hash function H' of RFC 9106 Section 3.3. For outLen <= 64, the result is BLAKE2b-outLen(LE32(outLen) || input). For larger outputs, let r = ceil(outLen/32) - 2; the output is W_1 || W_2 || ... || W_r || V_(r+1), where each W_i is the first 32 bytes of the 64-byte digest V_i, the chain starts with V_1 = BLAKE2b-64(LE32(outLen) || input), each V_i = BLAKE2b-64(V_(i-1)), and the final V_(r+1) = BLAKE2b-(outLen - 32r)(V_r) uses the shorter digest length (so the tail is a full digest, never a truncation).

Parameters

inputThe input bit string.
outLenThe desired output length in bytes (>= 1).

Returns

outLen bytes of H' output.