ChaCha20: move working state from ctx to stack

No need to keep it around.
This commit is contained in:
Manuel Pégourié-Gonnard 2018-05-24 17:23:41 +02:00
parent 9620f9b99e
commit 98fae6d800
2 changed files with 26 additions and 29 deletions

View file

@ -54,8 +54,7 @@ extern "C" {
typedef struct
{
uint32_t initial_state[16]; /*! The initial state (before round operations). */
uint32_t working_state[16]; /*! The working state (after round operations). */
uint32_t state[16]; /*! The state (before round operations). */
uint8_t keystream8[64]; /*! Leftover keystream bytes. */
size_t keystream_bytes_used; /*! Number of keystream bytes already used. */
}