Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wire: add previous revealed secrets hashes to RS message
For proper blaming behavior, peers who publish their secrets are blamed and removed from the following run if all secrets were revealed, but no other misbehavior was detected. In order to correctly pin the blame on the peers who disrupted the mix by initially revealing their secrets messages, this blaming will only be triggered when a reveal secrets message is received that does not reference any other received secrets messages. Because the secrets message hash now commits to these previous hashes by its signature, an additional method is added to return the commitment hash (to be published and verified in key exchange messages) that does not hash the previous messages (as they do not exist at the time of creating the key exchange). While here, an issue was discovered and corrected in the serialization of the MixVect type. When the vector has zero length, deserializing would return early after reading the first 0 dimension, but serialization was writing both the count and message size dimensions. This was corrected by changing the serialization method to return early if the count is zero.
- Loading branch information