pub struct PublicKey { /* private fields */ }
Expand description
User facing interface to work with a public key.
Implementations§
source§impl PublicKey
impl PublicKey
pub fn new( primary_key: PublicKey, details: KeyDetails, public_subkeys: Vec<PublicSubkey> ) -> Self
pub fn sign<F>( self, sec_key: &impl SecretKeyTrait, key_pw: F ) -> Result<SignedPublicKey>where F: FnOnce() -> String + Clone,
Trait Implementations§
source§impl PartialEq<PublicKey> for PublicKey
impl PartialEq<PublicKey> for PublicKey
source§impl PublicKeyTrait for PublicKey
impl PublicKeyTrait for PublicKey
source§fn verify_signature(
&self,
hash: HashAlgorithm,
data: &[u8],
sig: &[Mpi]
) -> Result<()>
fn verify_signature( &self, hash: HashAlgorithm, data: &[u8], sig: &[Mpi] ) -> Result<()>
Verify a signed message.
Data will be hashed using
hash
, before verifying.