Update to bls version 0.7.0
This commit is contained in:
parent
44657d44c4
commit
c991f4631d
@ -5,10 +5,11 @@ authors = ["Paul Hauner <paul@paulhauner.com>"]
|
|||||||
edition = "2018"
|
edition = "2018"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
bls-aggregates = { git = "https://github.com/sigp/signature-schemes", tag = "0.6.1" }
|
bls-aggregates = { git = "https://github.com/sigp/signature-schemes", tag = "0.7.0" }
|
||||||
cached_tree_hash = { path = "../cached_tree_hash" }
|
cached_tree_hash = { path = "../cached_tree_hash" }
|
||||||
hashing = { path = "../hashing" }
|
hashing = { path = "../hashing" }
|
||||||
hex = "0.3"
|
hex = "0.3"
|
||||||
|
rand = "0.5"
|
||||||
serde = "1.0"
|
serde = "1.0"
|
||||||
serde_derive = "1.0"
|
serde_derive = "1.0"
|
||||||
serde_hex = { path = "../serde_hex" }
|
serde_hex = { path = "../serde_hex" }
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
extern crate rand;
|
||||||
|
|
||||||
use super::BLS_SECRET_KEY_BYTE_SIZE;
|
use super::BLS_SECRET_KEY_BYTE_SIZE;
|
||||||
use bls_aggregates::SecretKey as RawSecretKey;
|
use bls_aggregates::SecretKey as RawSecretKey;
|
||||||
use hex::encode as hex_encode;
|
use hex::encode as hex_encode;
|
||||||
@ -16,7 +18,7 @@ pub struct SecretKey(RawSecretKey);
|
|||||||
|
|
||||||
impl SecretKey {
|
impl SecretKey {
|
||||||
pub fn random() -> Self {
|
pub fn random() -> Self {
|
||||||
SecretKey(RawSecretKey::random())
|
SecretKey(RawSecretKey::random(&mut rand::thread_rng()))
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Returns the underlying point as compressed bytes.
|
/// Returns the underlying point as compressed bytes.
|
||||||
|
Loading…
Reference in New Issue
Block a user