pub struct SharedRandomnessCommitment {
pub version: u32,
pub algorithm: String,
pub identity: String,
pub commit: String,
pub reveal: Option<String>,
}Expand description
A commitment to a shared random value from a directory authority.
As part of the shared randomness protocol, each participating authority commits to a random value before revealing it. This prevents authorities from choosing their random contribution based on others’ values.
§Protocol
- Each authority generates a random value and publishes a commitment (hash)
- After all commitments are collected, authorities reveal their values
- The revealed values are combined to produce the shared random value
§Fields
version: Protocol version (currently 1)algorithm: Hash algorithm used (e.g., “sha3-256”)identity: The authority’s identity fingerprintcommit: The commitment value (hash of the random value)reveal: The revealed random value (only present after reveal phase)
Fields§
§version: u32Protocol version number for the shared randomness protocol.
algorithm: StringHash algorithm used for the commitment (e.g., “sha3-256”).
identity: StringIdentity fingerprint of the committing authority.
commit: StringThe commitment value (hash of the random value being committed to).
reveal: Option<String>The revealed random value, present only after the reveal phase.
Trait Implementations§
Source§fn clone(&self) -> SharedRandomnessCommitment
fn clone(&self) -> SharedRandomnessCommitment
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more