Re: [PATCH v2 2/2] crypto: streebog - add Streebog test vectors
From: Vitaly Chikunov
Date: Tue Oct 16 2018 - 17:34:02 EST
On Wed, Oct 10, 2018 at 03:12:52PM +0300, Vitaly Chikunov wrote:
> Add testmgr and tcrypt tests and vectors for Streebog hash function
> from RFC 6986 and GOST R 34.11-2012.
>
> Signed-off-by: Vitaly Chikunov <vt@xxxxxxxxxxxx>
> ---
> crypto/tcrypt.c | 27 +++++++++++++++++++++
> crypto/testmgr.c | 12 ++++++++++
> crypto/testmgr.h | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> 3 files changed, 110 insertions(+)
>
> diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
> index bdde95e8d369..d66cb167daa2 100644
> --- a/crypto/tcrypt.c
> +++ b/crypto/tcrypt.c
> @@ -1914,6 +1915,14 @@ static int do_test(const char *alg, u32 type, u32 mask, int m, u32 num_mb)
> ret += tcrypt_test("sm3");
> break;
>
> + case 53:
> + ret += tcrypt_test("sb256");
> + break;
> +
> + case 54:
> + ret += tcrypt_test("sb512");
> + break;
> +
I am requested by Dmitry Eremin-Solenikov off-list to also add
hmac(sb256) and hmac(sb512) tests. I think this is a reasonable request
since IMA have such a mode of use and IMA is planned as one of the main
users of this hash. I may resend v3 with this, or as follow-up PATCH as
maintainers would prefer.
Thanks,