refactor: group equality and validity proofs in sigma_proofs module

This commit is contained in:
Sam Kim 2021-12-16 08:26:43 -05:00 committed by Michael Vines
parent e011502875
commit c6cd0a5591
6 changed files with 5 additions and 9 deletions

View File

@ -10,12 +10,11 @@ use {
elgamal::{ElGamalCiphertext, ElGamalKeypair, ElGamalPubkey, ElGamalSecretKey}, elgamal::{ElGamalCiphertext, ElGamalKeypair, ElGamalPubkey, ElGamalSecretKey},
pedersen::{Pedersen, PedersenCommitment, PedersenDecryptHandle, PedersenOpening}, pedersen::{Pedersen, PedersenCommitment, PedersenDecryptHandle, PedersenOpening},
}, },
equality_proof::EqualityProof, sigma_proofs::{equality_proof::EqualityProof, validity_proof::ValidityProof},
errors::ProofError, errors::ProofError,
instruction::{Role, Verifiable}, instruction::{Role, Verifiable},
range_proof::RangeProof, range_proof::RangeProof,
transcript::TranscriptProtocol, transcript::TranscriptProtocol,
validity_proof::ValidityProof,
}, },
curve25519_dalek::scalar::Scalar, curve25519_dalek::scalar::Scalar,
merlin::Transcript, merlin::Transcript,

View File

@ -9,7 +9,7 @@ use {
elgamal::{ElGamalCiphertext, ElGamalKeypair, ElGamalPubkey}, elgamal::{ElGamalCiphertext, ElGamalKeypair, ElGamalPubkey},
pedersen::{Pedersen, PedersenCommitment, PedersenOpening}, pedersen::{Pedersen, PedersenCommitment, PedersenOpening},
}, },
equality_proof::EqualityProof, sigma_proofs::equality_proof::EqualityProof,
errors::ProofError, errors::ProofError,
instruction::Verifiable, instruction::Verifiable,
range_proof::RangeProof, range_proof::RangeProof,

View File

@ -4,15 +4,13 @@ pub(crate) mod macros;
#[cfg(not(target_arch = "bpf"))] #[cfg(not(target_arch = "bpf"))]
pub mod encryption; pub mod encryption;
#[cfg(not(target_arch = "bpf"))] #[cfg(not(target_arch = "bpf"))]
mod equality_proof;
#[cfg(not(target_arch = "bpf"))]
mod errors; mod errors;
#[cfg(not(target_arch = "bpf"))] #[cfg(not(target_arch = "bpf"))]
mod range_proof; mod range_proof;
#[cfg(not(target_arch = "bpf"))] #[cfg(not(target_arch = "bpf"))]
mod transcript; mod sigma_proofs;
#[cfg(not(target_arch = "bpf"))] #[cfg(not(target_arch = "bpf"))]
mod validity_proof; mod transcript;
mod instruction; mod instruction;
pub mod zk_token_elgamal; pub mod zk_token_elgamal;

View File

@ -20,10 +20,9 @@ mod target_arch {
elgamal::{ElGamalCiphertext, ElGamalPubkey}, elgamal::{ElGamalCiphertext, ElGamalPubkey},
pedersen::{PedersenCommitment, PedersenDecryptHandle}, pedersen::{PedersenCommitment, PedersenDecryptHandle},
}, },
equality_proof::EqualityProof, sigma_proofs::{equality_proof::EqualityProof, validity_proof::ValidityProof},
errors::ProofError, errors::ProofError,
range_proof::RangeProof, range_proof::RangeProof,
validity_proof::ValidityProof,
}, },
curve25519_dalek::{ristretto::CompressedRistretto, scalar::Scalar}, curve25519_dalek::{ristretto::CompressedRistretto, scalar::Scalar},
std::convert::TryFrom, std::convert::TryFrom,