kmac: fix customistation string overflow bug
authorPauli <pauli@openssl.org>
Fri, 9 Apr 2021 06:20:15 +0000 (16:20 +1000)
committerPauli <pauli@openssl.org>
Mon, 12 Apr 2021 04:59:09 +0000 (14:59 +1000)
commit13eaa4ecaab528e9fd815a1019406335d241d643
treee5a1ee5bc57eab255c595cc18d53b0d421309c38
parent810a169eb2b642e5ca1e337bc6a9847defea62da
kmac: fix customistation string overflow bug

Previously there was an off by two error allowing a stack buffer overrun.
Avoided this by allocating a correct sized buffer on the stack.  A side effect
is that the maximum size of the customisation string can be increased.

Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/14810)
providers/implementations/macs/kmac_prov.c