Improve bls::SecretKey privacy (#1164)

* Improve bls::SecretKey privacy

* Add missed file

* Remove more methods from bls::SecretKey

* Add as_bytes() to SecretKey, remove as_raw

* Remove as_raw

* Add back as_raw

* Address review comments
This commit is contained in:
Paul Hauner
2020-05-19 11:23:08 +10:00
committed by GitHub
parent 314fae41fe
commit c93f9c351b
26 changed files with 102 additions and 295 deletions

View File

@@ -15,7 +15,7 @@ pub struct BlockProcessingBuilder<'a, T: EthSpec> {
impl<'a, T: EthSpec> BlockProcessingBuilder<'a, T> {
pub fn new(num_validators: usize, state_slot: Slot, spec: &'a ChainSpec) -> Self {
let mut state_builder =
TestingBeaconStateBuilder::from_default_keypairs_file_if_exists(num_validators, &spec);
TestingBeaconStateBuilder::from_deterministic_keypairs(num_validators, &spec);
state_builder.teleport_to_slot(state_slot);
let (state, keypairs) = state_builder.build();
let block_builder = TestingBeaconBlockBuilder::new(spec);

View File

@@ -22,7 +22,7 @@ pub struct BlockBuilder<T: EthSpec> {
impl<T: EthSpec> BlockBuilder<T> {
pub fn new(num_validators: usize, spec: &ChainSpec) -> Self {
let state_builder =
TestingBeaconStateBuilder::from_default_keypairs_file_if_exists(num_validators, &spec);
TestingBeaconStateBuilder::from_deterministic_keypairs(num_validators, &spec);
let block_builder = TestingBeaconBlockBuilder::new(spec);
Self {