Searched refs:ECDHPrivateKey (Results 1 – 2 of 2) sorted by relevance
27 pub struct ECDHPrivateKey(ECKey); struct29 impl ECDHPrivateKey { impl31 pub fn generate() -> Result<ECDHPrivateKey> { in generate()32 ec_key_generate_key().map(ECDHPrivateKey).context(ks_err!("generation failed")) in generate()36 pub fn from_private_key(buf: &[u8]) -> Result<ECDHPrivateKey> { in from_private_key() argument37 ec_key_parse_private_key(buf).map(ECDHPrivateKey).context(ks_err!("parsing failed")) in from_private_key()116 let recipient = ECDHPrivateKey::generate()?; in test_crypto_roundtrip()118 ECDHPrivateKey::encrypt_message(&recipient.public_key()?, message)?; in test_crypto_roundtrip()119 let recipient = ECDHPrivateKey::from_private_key(&recipient.private_key()?)?; in test_crypto_roundtrip()
23 ec_crypto::ECDHPrivateKey,457 ECDHPrivateKey::from_private_key(&key.key) in unwrap_key_with_key()650 ECDHPrivateKey::encrypt_message(public_key, key_blob) in encrypt_with_hybrid_super_key()758 ECDHPrivateKey::generate().context(ks_err!("Failed to generate ECDH key"))?; in create_super_key()