fn verify_weak<P: AsRef<[u8]>, M: AsRef<[u8]>>(sig: &[u8], message: M, pubkey: P) -> bool {
		let signature: schnorrkel::Signature = match schnorrkel::Signature::from_bytes(sig) {
			Ok(some_signature) => some_signature,
			Err(_) => return false
		};
		match PublicKey::from_bytes(pubkey.as_ref()) {
			Ok(pk) => pk.verify(
				signing_context(SIGNING_CTX).bytes(message.as_ref()), &signature
			),
			Err(_) => false,
		}
	}
/// Verify a signature on a message. Returns true if the signature is good.
Verify a signature on a message. Returns true if the signature is good.
Verify a signature on a message . Returns true if the signature is good .
fn verify_weak<P: AsRef<[u8]>, M: AsRef<[u8]>>(sig: &[u8], message: M, pubkey: P) -> bool {
		let signature: schnorrkel::Signature = match schnorrkel::Signature::from_bytes(sig) {
			Ok(some_signature) => some_signature,
			Err(_) => return false
		};
		match PublicKey::from_bytes(pubkey.as_ref()) {
			Ok(pk) => pk.verify(
				signing_context(SIGNING_CTX).bytes(message.as_ref()), &signature
			),
			Err(_) => false,
		}
	}
fn verify_weak < P : AsRef < [ u8 ] > , M : AsRef < [ u8 ] > > ( sig : & [ u8 ] , message : M , pubkey : P ) -> bool { let signature : schnorrkel :: Signature = match schnorrkel :: Signature :: from_bytes ( sig ) { Ok ( some_signature ) => some_signature , Err ( _ ) => return false } ; match PublicKey :: from_bytes ( pubkey . as_ref ( ) ) { Ok ( pk ) => pk . verify ( signing_context ( SIGNING_CTX ) . bytes ( message . as_ref ( ) ) , & signature ) , Err ( _ ) => false , } }
Verify a signature on a message.
Verify a signature on a message .
sig
&[u8]
message
M
pubkey
P
sig
&[u8]
message
M
pubkey
P