[openssl-dev] Variable length of digest

Viktor Dukhovni openssl-users at dukhovni.org
Thu Dec 24 08:00:08 UTC 2015


On Thu, Dec 24, 2015 at 10:45:37AM +0300, Dmitry Belyavsky wrote:

> > > That's an interesting question. What digest requires this? Is the output
> > > length arbitrary or do the standards specify a maximum size?
> 
> I mean the gost-mac digest (implemented in the ccgost engine,
> engines/ccgost/gost_crypt.c).
> It allows the output to vary from 1 to 8 bytes, though 4 bytes is the most
> common value.

This is surely much too short to be a stand-alone cryptographic
hash algorithm.  It sounds more like a mac for an AEAD construction,
in which case EVP_MD is not the right interface I think.  Would this
be better handled as a new block cipher "mode"?

What sort of beast is this, and what actually determines the length?

-- 
	Viktor.


More information about the openssl-dev mailing list