/// Verifies an individual signature against the provided public key.
///
/// # Returns
/// * OK, if `signature` is a valid BLS signature on `message`
/// * Err, otherwise
Verifies an individual signature against the provided public key.
Verifies an individual signature against the provided public key .
pub fn verify_individual_sig(
    message: &[u8],
    signature: IndividualSignature,
    public_key: PublicKey,
) -> CryptoResult<()> {
    verify(message, signature, public_key).map_err(|_| CryptoError::SignatureVerification {
        algorithm: AlgorithmId::ThresBls12_381,
        public_key_bytes: PublicKeyBytes::from(public_key).0.to_vec(),
        sig_bytes: IndividualSignatureBytes::from(signature).0.to_vec(),
        internal_error: "Invalid individual threshold signature".to_string(),
    })
}
pub fn verify_individual_sig ( message : & [ u8 ] , signature : IndividualSignature , public_key : PublicKey , ) -> CryptoResult < ( ) > { verify ( message , signature , public_key ) . map_err ( | _ | CryptoError :: SignatureVerification { algorithm : AlgorithmId :: ThresBls12_381 , public_key_bytes : PublicKeyBytes :: from ( public_key ) . 0 . to_vec ( ) , sig_bytes : IndividualSignatureBytes :: from ( signature ) . 0 . to_vec ( ) , internal_error : " " . to_string ( ) , } ) }
Verifies an individual signature against the provided public key.
Verifies an individual signature against the provided public key .
OK, if `signature` is a valid BLS signature on `message`
Err, otherwise
OK if ` signature ` is a valid BLS signature on ` message ` Err otherwise
message
&[u8]
signature
IndividualSignature
public_key
PublicKey