RPC method for clearing the engine signer (#10920)

* RPC method parity_clearEngineSigner

Add RPC method parity_clearEngineSigner
Fixes https://github.com/poanetwork/parity-ethereum/issues/113

* corrected the return type of clear_author

* review comment responses and a rebase fix

* removed a spurrious warning

* moved clear_signer functionality to set_signer

* Merge clear_author into MinerService::set_author.

* Add trace logs to Clique::set_signer.

* Clique: Don't lock signer multiple times.
This commit is contained in:
Vladimir Komendantskiy
2019-10-09 13:42:51 +01:00
committed by David
parent a404dd5415
commit 93fbbb9aaf
10 changed files with 140 additions and 59 deletions

View File

@@ -293,7 +293,7 @@ pub trait Engine: Sync + Send {
fn handle_message(&self, _message: &[u8]) -> Result<(), EngineError> { Err(EngineError::UnexpectedMessage) }
/// Register a component which signs consensus messages.
fn set_signer(&self, _signer: Box<dyn EngineSigner>) {}
fn set_signer(&self, _signer: Option<Box<dyn EngineSigner>>) {}
/// Sign using the EngineSigner, to be used for consensus tx signing.
fn sign(&self, _hash: H256) -> Result<Signature, Error> { unimplemented!() }