|
15 | 15 |
|
16 | 16 | use schnorrkel::{derive::Derivation, Keypair}; |
17 | 17 |
|
18 | | -use randomness::{adapters::RngCore08Adapter, CryptoRng}; |
| 18 | +use randomness::{adapters::Rng08Adapter, CryptoRng}; |
19 | 19 | use serialization::{Decode, Encode}; |
20 | 20 |
|
21 | 21 | use crate::key::hdkd::{ |
@@ -123,7 +123,7 @@ pub struct SchnorrkelPrivateKey { |
123 | 123 |
|
124 | 124 | impl SchnorrkelPrivateKey { |
125 | 125 | pub fn new<R: CryptoRng>(rng: &mut R) -> (SchnorrkelPrivateKey, SchnorrkelPublicKey) { |
126 | | - let sk = schnorrkel::SecretKey::generate_with(&mut RngCore08Adapter(rng)); |
| 126 | + let sk = schnorrkel::SecretKey::generate_with(&mut Rng08Adapter(rng)); |
127 | 127 | let pk = sk.to_public(); |
128 | 128 | let sk = Self { key: sk }; |
129 | 129 | let pk = SchnorrkelPublicKey { key: pk }; |
@@ -265,7 +265,7 @@ mod tests { |
265 | 265 | fn vrf_internal_simple() { |
266 | 266 | let mut csprng = make_true_rng(); |
267 | 267 |
|
268 | | - let keypair1 = Keypair::generate_with(&mut RngCore08Adapter(&mut csprng)); |
| 268 | + let keypair1 = Keypair::generate_with(&mut Rng08Adapter(&mut csprng)); |
269 | 269 |
|
270 | 270 | let ctx = signing_context(b"yoo!"); |
271 | 271 | let msg = b"meow"; |
@@ -299,7 +299,7 @@ mod tests { |
299 | 299 | "VRF verification with incorrect message passed!" |
300 | 300 | ); |
301 | 301 |
|
302 | | - let keypair2 = Keypair::generate_with(&mut RngCore08Adapter(&mut csprng)); |
| 302 | + let keypair2 = Keypair::generate_with(&mut Rng08Adapter(&mut csprng)); |
303 | 303 | assert!( |
304 | 304 | keypair2.public.vrf_verify(ctx.bytes(msg), out1, &proof1).is_err(), |
305 | 305 | "VRF verification with incorrect signer passed!" |
|
0 commit comments