diff options
author | Kazuki Yamaguchi <k@rhe.jp> | 2016-12-30 00:59:56 +0900 |
---|---|---|
committer | Kazuki Yamaguchi <k@rhe.jp> | 2016-12-30 00:59:56 +0900 |
commit | a002e355efa5c6f1d75298124fe1296454053393 (patch) | |
tree | 429f0dbf1285f13ad8594dd278cb58bc1cb8d5f0 | |
parent | 67adf0a7c273a82901ce8705ae8d71ee2f1c959c (diff) | |
download | openssl-topic/chacha20-flags.tar.gz |
Add missing flags for EVP_chacha20()topic/chacha20-flags
ChaCha20 code uses its own custom cipher_data. Add EVP_CIPH_CUSTOM_IV
and EVP_CIPH_ALWAYS_CALL_INIT so that the key and the iv can be set by
different calls of EVP_CipherInit_ex().
-rw-r--r-- | crypto/evp/e_chacha20_poly1305.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/evp/e_chacha20_poly1305.c b/crypto/evp/e_chacha20_poly1305.c index 952bd3fca7..befd805e35 100644 --- a/crypto/evp/e_chacha20_poly1305.c +++ b/crypto/evp/e_chacha20_poly1305.c @@ -127,7 +127,7 @@ static const EVP_CIPHER chacha20 = { 1, /* block_size */ CHACHA_KEY_SIZE, /* key_len */ CHACHA_CTR_SIZE, /* iv_len, 128-bit counter in the context */ - 0, /* flags */ + EVP_CIPH_CUSTOM_IV | EVP_CIPH_ALWAYS_CALL_INIT, chacha_init_key, chacha_cipher, NULL, |