Documentation
¶
Index ¶
- type SNPrivacyProof
- func (proof SNPrivacyProof) Bytes() []byte
- func (proof SNPrivacyProof) GetComInput() *crypto.Point
- func (proof SNPrivacyProof) GetComSK() *crypto.Point
- func (proof SNPrivacyProof) GetSN() *crypto.Point
- func (proof *SNPrivacyProof) Init() *SNPrivacyProof
- func (proof *SNPrivacyProof) Set(stmt *SerialNumberPrivacyStatement, tSK *crypto.Point, tInput *crypto.Point, ...)
- func (proof *SNPrivacyProof) SetBytes(bytes []byte) error
- type SNPrivacyWitness
- type SerialNumberPrivacyStatement
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SNPrivacyProof ¶
type SNPrivacyProof struct {
// contains filtered or unexported fields
}
SNPrivacyProof represents a zero-knowledge proof for proving the the serial number is correctly generated from the secret key and the SND with the following formula: SN = (sk + snd)^-1 * G[0].
func (SNPrivacyProof) Bytes ¶
func (proof SNPrivacyProof) Bytes() []byte
Bytes returns the byte-representation of an SNPrivacyProof.
func (SNPrivacyProof) GetComInput ¶
func (proof SNPrivacyProof) GetComInput() *crypto.Point
GetComInput returns the input commitment of an SNPrivacyProof.
func (SNPrivacyProof) GetComSK ¶
func (proof SNPrivacyProof) GetComSK() *crypto.Point
GetComSK returns the secret key commitment of an SNPrivacyProof.
func (SNPrivacyProof) GetSN ¶
func (proof SNPrivacyProof) GetSN() *crypto.Point
GetSN returns the serial number of an SNPrivacyProof.
func (*SNPrivacyProof) Init ¶
func (proof *SNPrivacyProof) Init() *SNPrivacyProof
Init creates an empty SNPrivacyProof.
func (*SNPrivacyProof) Set ¶
func (proof *SNPrivacyProof) Set( stmt *SerialNumberPrivacyStatement, tSK *crypto.Point, tInput *crypto.Point, tSN *crypto.Point, zSK *crypto.Scalar, zRSK *crypto.Scalar, zInput *crypto.Scalar, zRInput *crypto.Scalar)
Set sets data to an SNPrivacyProof.
func (*SNPrivacyProof) SetBytes ¶
func (proof *SNPrivacyProof) SetBytes(bytes []byte) error
SetBytes sets raw-byte data into an SNPrivacyProof.
type SNPrivacyWitness ¶
type SNPrivacyWitness struct {
// contains filtered or unexported fields
}
SNPrivacyWitness represents the witness of an SNPrivacyProof.
func (SNPrivacyWitness) Prove ¶
func (wit SNPrivacyWitness) Prove(mess []byte) (*SNPrivacyProof, error)
Prove returns an SNPrivacyProof given its witness.
type SerialNumberPrivacyStatement ¶
type SerialNumberPrivacyStatement struct {
// contains filtered or unexported fields
}
SerialNumberPrivacyStatement represents a statement of a SNPrivacyProof.