Skip to content

Commit

Permalink
only require Merkleized for signature ops
Browse files Browse the repository at this point in the history
  • Loading branch information
ralexstokes committed Oct 12, 2023
1 parent 7a5bcde commit 61ac58c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ethereum-consensus/src/signing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pub struct SigningData {
pub domain: Domain,
}

pub fn compute_signing_root<T: SimpleSerialize>(
pub fn compute_signing_root<T: Merkleized>(
ssz_object: &mut T,
domain: Domain,
) -> Result<Root, Error> {
Expand All @@ -21,7 +21,7 @@ pub fn compute_signing_root<T: SimpleSerialize>(
s.hash_tree_root().map_err(Error::Merkleization)
}

pub fn sign_with_domain<T: SimpleSerialize>(
pub fn sign_with_domain<T: Merkleized>(
data: &mut T,
signing_key: &SecretKey,
domain: Domain,
Expand All @@ -30,7 +30,7 @@ pub fn sign_with_domain<T: SimpleSerialize>(
Ok(signing_key.sign(signing_root.as_ref()))
}

pub fn verify_signed_data<T: SimpleSerialize>(
pub fn verify_signed_data<T: Merkleized>(
data: &mut T,
signature: &BlsSignature,
public_key: &BlsPublicKey,
Expand Down

0 comments on commit 61ac58c

Please sign in to comment.