[−][src]Struct bulletproofs::range_proof_mpc::dealer::DealerAwaitingProofShares
A dealer which has sent the PolyChallenge
to the parties and
is waiting to aggregate their ProofShare
s into a
RangeProof
.
Fields
n: usize
m: usize
transcript: &'a mut Transcript
initial_transcript: Transcript
bp_gens: &'b BulletproofGens
pc_gens: &'b PedersenGens
bit_challenge: BitChallenge
bit_commitments: Vec<BitCommitment>
poly_challenge: PolyChallenge
poly_commitments: Vec<PolyCommitment>
A: RistrettoPoint
S: RistrettoPoint
T_1: RistrettoPoint
T_2: RistrettoPoint
Methods
impl<'a, 'b> DealerAwaitingProofShares<'a, 'b>
[src]
fn assemble_shares(
&mut self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
[src]
&mut self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
Assembles proof shares into an RangeProof
.
Used as a helper function by receive_trusted_shares
(which
just hands back the result) and receive_shares
(which
validates the proof shares.
pub fn receive_shares(
self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
[src]
self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
Assemble the final aggregated RangeProof
from the given
proof_shares
, then validate the proof to ensure that all
ProofShare
s were well-formed.
This is a convenience wrapper around receive_shares_with_rng
pub fn receive_shares_with_rng<T: RngCore + CryptoRng>(
self,
proof_shares: &[ProofShare],
rng: &mut T
) -> Result<RangeProof, MPCError>
[src]
self,
proof_shares: &[ProofShare],
rng: &mut T
) -> Result<RangeProof, MPCError>
Assemble the final aggregated RangeProof
from the given
proof_shares
, then validate the proof to ensure that all
ProofShare
s were well-formed.
If the aggregated proof fails to validate, this function
audits the submitted shares to determine which shares were
invalid. This information is returned as part of the
MPCError
.
If the proof shares are known to be trusted, for instance when
performing local aggregation,
receive_trusted_shares
saves time by skipping verification of the aggregated proof.
pub fn receive_trusted_shares(
self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
[src]
self,
proof_shares: &[ProofShare]
) -> Result<RangeProof, MPCError>
Assemble the final aggregated RangeProof
from the given
proof_shares
, but skip validation of the proof.
WARNING
This function does NOT validate the proof shares. It is suitable for creating aggregated proofs when all parties are known by the dealer to be honest (for instance, when there's only one party playing all roles).
Otherwise, use
receive_shares
,
which validates that all shares are well-formed, or else
detects which party(ies) submitted malformed shares.
Auto Trait Implementations
impl<'a, 'b> RefUnwindSafe for DealerAwaitingProofShares<'a, 'b>
impl<'a, 'b> Send for DealerAwaitingProofShares<'a, 'b>
impl<'a, 'b> Sync for DealerAwaitingProofShares<'a, 'b>
impl<'a, 'b> Unpin for DealerAwaitingProofShares<'a, 'b>
impl<'a, 'b> !UnwindSafe for DealerAwaitingProofShares<'a, 'b>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> Cast<U> for T where
U: FromCast<T>,
U: FromCast<T>,
fn cast(self) -> U
impl<T> From<T> for T
[src]
impl<T> FromBits<T> for T
fn from_bits(t: T) -> T
impl<T> FromCast<T> for T
fn from_cast(t: T) -> T
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> IntoBits<U> for T where
U: FromBits<T>,
U: FromBits<T>,
fn into_bits(self) -> U
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,