ZcashFoundation / frost

Rust implementation of FROST (Flexible Round-Optimised Schnorr Threshold signatures) by the Zcash Foundation
https://frost.zfnd.org
Other
133 stars 50 forks source link

Improve documentation regarding which Identifiers to use in aggregate() #697

Open conradoplg opened 2 months ago

conradoplg commented 2 months ago

For reference, see this comment in Discord

Good question! It shouldn't include the Identifier because that would allow the participant to lie about who they are and evade cheater detection. The "right way" to do it is for the Coordinator to get the Identifier from an Identity->Identifier mapping that it must keep, which depends on whatever authentication mechanism is used to send messages. For example, if there is an encrypted channel and the participant signs its messages with its private key, then the Coordinator would need a public key -> Identifier mapping and find the the Identifier from the public key being used to verify the participant's message. (If you don't care about cheater detection, you can disable the "cheater-detection" feature from the crates, and then you can pass an empty map in PublicKeyPackage::verifying_shares... though I've just realized you still have to get identifiers from somewhere in the signature_shares, so we might improve that in the future)