Add a comment about why we hash the message and the set of nonce comm… (#407)
Add a comment about why we hash the message and the set of nonce commitments as part of creating the preimage for the binding factor
This commit is contained in:
parent
8defd2c058
commit
8b09d9d698
|
@ -242,6 +242,9 @@ where
|
|||
) -> Vec<(Identifier<C>, Vec<u8>)> {
|
||||
let mut binding_factor_input_prefix = vec![];
|
||||
|
||||
// The message is hashed with H4 to force the variable-length message
|
||||
// into a fixed-length byte string, same for hashing the variable-sized
|
||||
// (between runs of the protocol) set of group commitments, but with H5.
|
||||
binding_factor_input_prefix.extend_from_slice(C::H4(self.message.as_slice()).as_ref());
|
||||
binding_factor_input_prefix.extend_from_slice(
|
||||
C::H5(&round1::encode_group_commitments(self.signing_commitments())[..]).as_ref(),
|
||||
|
|
Loading…
Reference in New Issue