pub trait SignatureScheme {
// Required methods
fn sign<Rng: CryptoRngCore>(
self,
rng: Option<&mut Rng>,
priv_key: &RsaPrivateKey,
hashed: &[u8],
) -> Result<Vec<u8>>;
fn verify(
self,
pub_key: &RsaPublicKey,
hashed: &[u8],
sig: &[u8],
) -> Result<()>;
}
Expand description
Digital signature scheme.
Required Methods§
sourcefn sign<Rng: CryptoRngCore>(
self,
rng: Option<&mut Rng>,
priv_key: &RsaPrivateKey,
hashed: &[u8],
) -> Result<Vec<u8>>
fn sign<Rng: CryptoRngCore>( self, rng: Option<&mut Rng>, priv_key: &RsaPrivateKey, hashed: &[u8], ) -> Result<Vec<u8>>
Sign the given digest.
Object Safety§
This trait is not object safe.