pub trait KeyAgreement:
Identified
+ Send
+ Sync {
// Required method
fn agree(
&self,
private_key_hex: &str,
peer_public_key_hex: &str,
) -> Result<String>;
}Expand description
密钥协商:以己方私钥与对方公钥导出共享秘密(ECDH / X25519)。
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".