Bitcoin ABC 0.26.3
P2P Digital Currency
|
A class for ChaCha20 256-bit stream cipher developed by Daniel J. More...
#include <chacha20.h>
Public Member Functions | |
ChaCha20 () | |
ChaCha20 (const uint8_t *key, size_t keylen) | |
void | SetKey (const uint8_t *key, size_t keylen) |
set key with flexible keylength; 256bit recommended | |
void | SetIV (uint64_t iv) |
void | Seek (uint64_t pos) |
void | Keystream (uint8_t *c, size_t bytes) |
outputs the keystream of size <bytes> into | |
void | Crypt (const uint8_t *input, uint8_t *output, size_t bytes) |
enciphers the message <input> of length <bytes> and write the enciphered representation into <output> Used for encryption and decryption (XOR) | |
Private Attributes | |
uint32_t | input [16] |
A class for ChaCha20 256-bit stream cipher developed by Daniel J.
Bernstein https://cr.yp.to/chacha/chacha-20080128.pdf
Definition at line 15 of file chacha20.h.
ChaCha20::ChaCha20 | ( | ) |
enciphers the message <input> of length <bytes> and write the enciphered representation into <output> Used for encryption and decryption (XOR)
Definition at line 194 of file chacha20.cpp.
outputs the keystream of size <bytes> into
Definition at line 79 of file chacha20.cpp.
set key with flexible keylength; 256bit recommended
Definition at line 32 of file chacha20.cpp.
|
private |
Definition at line 17 of file chacha20.h.