1 // Copyright (c) 2017 The Bitcoin Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 #ifndef BITCOIN_CRYPTO_CHACHA20_H
6 #define BITCOIN_CRYPTO_CHACHA20_H
11 /** A PRNG class for ChaCha20. */
19 ChaCha20(const unsigned char* key
, size_t keylen
);
20 void SetKey(const unsigned char* key
, size_t keylen
);
21 void SetIV(uint64_t iv
);
22 void Seek(uint64_t pos
);
23 void Output(unsigned char* output
, size_t bytes
);
26 #endif // BITCOIN_CRYPTO_CHACHA20_H