MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / from_secret_key

Method from_secret_key

atomic-identity/src/keypair.rs:221–224  ·  view source on GitHub ↗

Create a key pair from a secret key

(secret: SecretKey)

Source from the content-addressed store, hash-verified

219
220 /// Create a key pair from a secret key
221 pub fn from_secret_key(secret: SecretKey) -> Self {
222 let public = secret.public_key();
223 KeyPair { secret, public }
224 }
225
226 /// Sign a message with the secret key
227 pub fn sign(&self, message: &[u8]) -> [u8; 64] {

Callers

nothing calls this directly

Calls 1

public_keyMethod · 0.45

Tested by

no test coverage detected