pub fn sign(bytes: &[u8], secret_key: &SecretKey) -> Signature {
    let (pub_key, secret_key) = get_raw_keypair_from_secret(secret_key);
    // let raw_signature = keypair.sign::<Sha512>(bytes);
    let raw_signature = secret_key.sign::<Sha512>(bytes, &pub_key);

    Signature(raw_signature.to_bytes())
}
/// Sign a data in bytes, return Signature.
Sign a data in bytes, return Signature.
Sign a data in bytes return Signature .
pub fn sign(bytes: &[u8], secret_key: &SecretKey) -> Signature {
    let (pub_key, secret_key) = get_raw_keypair_from_secret(secret_key);
    // let raw_signature = keypair.sign::<Sha512>(bytes);
    let raw_signature = secret_key.sign::<Sha512>(bytes, &pub_key);
    Signature(raw_signature.to_bytes())
}
pub fn sign ( bytes : & [ u8 ] , secret_key : & SecretKey ) -> Signature { let ( pub_key , secret_key ) = get_raw_keypair_from_secret ( secret_key ) ; // let raw_signature = keypair.sign::<Sha512>(bytes); let raw_signature = secret_key . sign :: < Sha512 > ( bytes , & pub_key ) ; Signature ( raw_signature . to_bytes ( ) ) }
Sign a data in bytes, return Signature.
Sign a data in bytes return Signature .
bytes
&[u8]
secret_key
&SecretKey
bytes
&[u8]
secret_key
&SecretKey