pub fn derive_key(&self, customize: impl FnOnce(&mut Transcript)) -> Scalar {
        let mut t = Transcript::new(b"Keytree.derivation");
        t.commit_bytes(b"pt", self.precompressed_pubkey.as_bytes());
        t.commit_bytes(b"dk", &self.dk);

        // change the derivation path for this key
        customize(&mut t);

        // squeeze a challenge scalar
        let f = t.challenge_scalar(b"f.leaf");
        self.scalar + f
    }
/// Returns a leaf private key. Users must provide customize, in order to
/// separate sibling keys from one another through unique derivation paths.
Returns a leaf private key. Users must provide customize, in order to
separate sibling keys from one another through unique derivation paths.
Returns a leaf private key . Users must provide customize in order to separate sibling keys from one another through unique derivation paths .
pub fn derive_key(&self, customize: impl FnOnce(&mut Transcript)) -> Scalar {
        let mut t = Transcript::new(b"Keytree.derivation");
        t.commit_bytes(b"pt", self.precompressed_pubkey.as_bytes());
        t.commit_bytes(b"dk", &self.dk);
        // change the derivation path for this key
        customize(&mut t);
        // squeeze a challenge scalar
        let f = t.challenge_scalar(b"f.leaf");
        self.scalar + f
    }
pub fn derive_key ( & self , customize : impl FnOnce ( & mut Transcript ) ) -> Scalar { let mut t = Transcript :: new ( b" " ) ; t . commit_bytes ( b" " , self . precompressed_pubkey . as_bytes ( ) ) ; t . commit_bytes ( b" " , & self . dk ) ; // change the derivation path for this key customize ( & mut t ) ; // squeeze a challenge scalar let f = t . challenge_scalar ( b" " ) ; self . scalar + f }
Returns a leaf private key.
Returns a leaf private key .
&self
customize
impl FnOnce(&mut Transcript)
&self
customize
impl FnOnce(&mut Transcript)