diff options
author | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2014-05-11 12:00:19 +0300 |
---|---|---|
committer | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2014-05-11 12:00:19 +0300 |
commit | 23f33d57c9b6f2295a8ddfc9a8eee5a2c30cf406 (patch) | |
tree | a03d24f0dd7c6f9eea72030606f702a3b209775c /doc | |
parent | 246b7aaae1ee459f440260bbc4ec2c01c5dc3362 (diff) | |
download | libgcrypt-23f33d57c9b6f2295a8ddfc9a8eee5a2c30cf406.tar.gz |
Add ChaCha20 stream cipher
* cipher/Makefile.am: Add 'chacha20.c'.
* cipher/chacha20.c: New.
* cipher/cipher.c (cipher_list): Add ChaCha20.
* configure.ac: Add ChaCha20.
* doc/gcrypt.texi: Add ChaCha20.
* src/cipher.h (_gcry_cipher_spec_chacha20): New.
* src/gcrypt.h.in (GCRY_CIPHER_CHACHA20): Add new algo.
* tests/basic.c (MAX_DATA_LEN): Increase to 128 from 100.
(check_stream_cipher): Add ChaCha20 test-vectors.
(check_ciphers): Add ChaCha20.
--
Patch adds Bernstein's ChaCha20 cipher to libgcrypt. Implementation is based
on public domain implementations.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/gcrypt.texi | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/doc/gcrypt.texi b/doc/gcrypt.texi index c5c3b452..d202b8b4 100644 --- a/doc/gcrypt.texi +++ b/doc/gcrypt.texi @@ -1564,6 +1564,10 @@ This is the Salsa20/12 - reduced round version of Salsa20 stream cipher. The GOST 28147-89 cipher, defined in the respective GOST standard. Translation of this GOST into English is provided in the RFC-5830. +@item GCRY_CIPHER_CHACHA20 +@cindex ChaCha20 +This is the ChaCha20 stream cipher. + @end table @node Available cipher modes @@ -1720,9 +1724,9 @@ vector is passed as the buffer @var{K} of length @var{l} bytes and copied to internal data structures. The function checks that the IV matches the requirement of the selected algorithm and mode. -This function is also used with the Salsa20 stream cipher to set or -update the required nonce. In this case it needs to be called after -setting the key. +This function is also used with Salsa20 and ChaCha20 stream ciphers +to set or update the required nonce. In this case it needs to be +called after setting the key. This function is also used with the AEAD cipher modes to set or update the required nonce. |