pub struct SignerClient { /* private fields */ }Expand description
TCP signer client.
Implementations§
Source§impl SignerClient
impl SignerClient
Sourcepub fn connect(addr: &str) -> Result<Self>
pub fn connect(addr: &str) -> Result<Self>
Connect to coordinator at addr (e.g., “127.0.0.1:18432”).
Sourcepub fn register(&mut self, signer_id: &str, quorum_id: &str) -> Result<()>
pub fn register(&mut self, signer_id: &str, quorum_id: &str) -> Result<()>
Register this signer with the coordinator.
Sourcepub fn create_session(
&mut self,
quorum_id: &str,
scheme: &str,
message: &[u8],
threshold: u32,
num_parties: u32,
) -> Result<String>
pub fn create_session( &mut self, quorum_id: &str, scheme: &str, message: &[u8], threshold: u32, num_parties: u32, ) -> Result<String>
Create a new signing session on the coordinator.
Sourcepub fn submit_commitment(
&mut self,
session_id: &str,
signer_id: &str,
commitment_bytes: &[u8],
) -> Result<()>
pub fn submit_commitment( &mut self, session_id: &str, signer_id: &str, commitment_bytes: &[u8], ) -> Result<()>
Submit a commitment for a session.
Submit a share for a session. Returns the aggregated signature if this was the T-th share (threshold met).
Sourcepub fn get_status(&mut self, session_id: &str) -> Result<String>
pub fn get_status(&mut self, session_id: &str) -> Result<String>
Query session status.
Auto Trait Implementations§
impl Freeze for SignerClient
impl RefUnwindSafe for SignerClient
impl Send for SignerClient
impl Sync for SignerClient
impl Unpin for SignerClient
impl UnsafeUnpin for SignerClient
impl UnwindSafe for SignerClient
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more