]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: testmgr - Add ChaCha20 test vectors from RFC7539
authorMartin Willi <martin@strongswan.org>
Mon, 1 Jun 2015 11:43:57 +0000 (13:43 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 4 Jun 2015 07:04:50 +0000 (15:04 +0800)
commitbc24db99f38a36db732e9f504d72ff69d4e0a179
tree8a15272cb024651d24779bef34c43774ca619bfe
parentf6d7212843a84087d2d629ff99d8cb91e5ccd14e
crypto: testmgr - Add ChaCha20 test vectors from RFC7539

We explicitly set the Initial block Counter by prepending it to the nonce in
Little Endian. The same test vector is used for both encryption and decryption,
ChaCha20 is a cipher XORing a keystream.

Signed-off-by: Martin Willi <martin@strongswan.org>
Acked-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/testmgr.c
crypto/testmgr.h