Changeset View
Changeset View
Standalone View
Standalone View
src/secp256k1/src/testrand_impl.h
/********************************************************************** | /********************************************************************** | ||||
* Copyright (c) 2013-2015 Pieter Wuille * | * Copyright (c) 2013-2015 Pieter Wuille * | ||||
* Distributed under the MIT software license, see the accompanying * | * Distributed under the MIT software license, see the accompanying * | ||||
* file COPYING or http://www.opensource.org/licenses/mit-license.php.* | * file COPYING or http://www.opensource.org/licenses/mit-license.php.* | ||||
**********************************************************************/ | **********************************************************************/ | ||||
#ifndef _SECP256K1_TESTRAND_IMPL_H_ | #ifndef SECP256K1_TESTRAND_IMPL_H | ||||
#define _SECP256K1_TESTRAND_IMPL_H_ | #define SECP256K1_TESTRAND_IMPL_H | ||||
#include <stdint.h> | #include <stdint.h> | ||||
#include <string.h> | #include <string.h> | ||||
#include "testrand.h" | #include "testrand.h" | ||||
#include "hash.h" | #include "hash.h" | ||||
static secp256k1_rfc6979_hmac_sha256_t secp256k1_test_rng; | static secp256k1_rfc6979_hmac_sha256_t secp256k1_test_rng; | ||||
▲ Show 20 Lines • Show All 85 Lines • ▼ Show 20 Lines | while (bits < len * 8) { | ||||
} | } | ||||
} | } | ||||
} | } | ||||
static void secp256k1_rand256_test(unsigned char *b32) { | static void secp256k1_rand256_test(unsigned char *b32) { | ||||
secp256k1_rand_bytes_test(b32, 32); | secp256k1_rand_bytes_test(b32, 32); | ||||
} | } | ||||
#endif | #endif /* SECP256K1_TESTRAND_IMPL_H */ |