Documentation
¶
Index ¶
- Constants
- Variables
- func VerifyEqualityProof(pd *CiphertextCommitmentEqualityProofData) error
- type CiphertextCommitmentEqualityProofContext
- type CiphertextCommitmentEqualityProofData
- type CompressedRistretto
- type DecryptHandle
- type ElGamalCiphertext
- type ElGamalPubkey
- type EqualityProof
- type PedersenCommitment
- type PodCiphertextCommitmentEqualityProof
- type PodElGamalCiphertext
- type PodElGamalPubkey
- type PodPedersenCommitment
- type Point
- type Scalar
Constants ¶
View Source
const U = common.U
Variables ¶
View Source
var ( ErrProofDeserialization = errors.New("deserialization error") ErrProofAlgebraic = errors.New("algebraic relation failed") )
Functions ¶
func VerifyEqualityProof ¶
func VerifyEqualityProof( pd *CiphertextCommitmentEqualityProofData, ) error
Types ¶
type CiphertextCommitmentEqualityProofContext ¶
type CiphertextCommitmentEqualityProofContext struct {
Pubkey PodElGamalPubkey
Ciphertext PodElGamalCiphertext
Commitment PodPedersenCommitment
}
type CiphertextCommitmentEqualityProofData ¶
type CiphertextCommitmentEqualityProofData struct {
Context CiphertextCommitmentEqualityProofContext
Proof PodCiphertextCommitmentEqualityProof
}
type CompressedRistretto ¶
type CompressedRistretto = common.CompressedRistretto
type DecryptHandle ¶
type DecryptHandle struct {
common.DecryptHandle
}
type ElGamalCiphertext ¶
type ElGamalCiphertext struct {
Commitment PedersenCommitment
Handle DecryptHandle
}
func (*ElGamalCiphertext) FromPod ¶
func (ct *ElGamalCiphertext) FromPod(v PodElGamalCiphertext) error
type ElGamalPubkey ¶
type ElGamalPubkey struct {
common.ElGamalPubkey
}
func (*ElGamalPubkey) FromPod ¶
func (pk *ElGamalPubkey) FromPod(v PodElGamalPubkey) error
type EqualityProof ¶
type EqualityProof struct {
Y0 CompressedRistretto
Y1 CompressedRistretto
Y2 CompressedRistretto
Zs Scalar
Zx Scalar
Zr Scalar
}
func EqualityProofFromBytes ¶
func EqualityProofFromBytes(buf *[U * 6]byte) (*EqualityProof, error)
func (EqualityProof) Verify ¶
func (ep EqualityProof) Verify( pubkey *ElGamalPubkey, ciphertext *ElGamalCiphertext, commitment *PedersenCommitment, transcript *merlin.Transcript, ) error
type PedersenCommitment ¶
type PedersenCommitment struct {
common.PedersenCommitment
}
func PedersenCommitmentFromPod ¶
func PedersenCommitmentFromPod(v PodPedersenCommitment) (*PedersenCommitment, error)
type PodCiphertextCommitmentEqualityProof ¶
type PodCiphertextCommitmentEqualityProof struct {
Y0 [U]byte
Y1 [U]byte
Y2 [U]byte
Zs [U]byte
Zx [U]byte
Zr [U]byte
}
func (*PodCiphertextCommitmentEqualityProof) AsBytes ¶
func (p *PodCiphertextCommitmentEqualityProof) AsBytes() [U * 6]byte
type PodElGamalPubkey ¶
type PodPedersenCommitment ¶
Click to show internal directories.
Click to hide internal directories.