Documentation
¶
Index ¶
- Variables
- type BaseProof
- func (po *BaseProof) ComputeProof(fullWitness witness.Witness) (native_groth16.Proof, error)
- func (po *BaseProof) CreateBaseCaseWitness(rawTxBytes []byte, currTxId [32]byte) (witness.Witness, error)
- func (po *BaseProof) CreateLightWitness(genesisTxId []byte) (*witness.Witness, error)
- func (po *BaseProof) ReadKeys() error
- func (po *BaseProof) VerifyProof(witness *witness.Witness, proof *native_groth16.Proof) bool
- func (po *BaseProof) WriteKeys() error
- type NormalProof
- func (po *NormalProof) ComputeProof(fullWitness witness.Witness) (native_groth16.Proof, error)
- func (po *NormalProof) CreateFullWitness(prevPublicWitness witness.Witness, prevProof native_groth16.Proof, ...) (*witness.Witness, error)
- func (po *NormalProof) CreateLightWitness(txId []byte) (*witness.Witness, error)
- func (po *NormalProof) ReadKeys() error
- func (po *NormalProof) SetupKeys() error
- func (po *NormalProof) VerifyProof(witness *witness.Witness, proof *native_groth16.Proof) bool
- func (po *NormalProof) WriteKeys() error
- type ProofSystem
Constants ¶
This section is empty.
Variables ¶
View Source
var BASE_RAW_TX_SIZE = 191
Functions ¶
This section is empty.
Types ¶
type BaseProof ¶
type BaseProof struct { CurveId ecc.ID InnerField *big.Int OuterField *big.Int Ccs *constraint.ConstraintSystem VerifyingKey *native_groth16.VerifyingKey ProvingKey *native_groth16.ProvingKey // contains filtered or unexported fields }
func BootBaseProof ¶ added in v0.1.4
func NewBaseProof ¶
func (*BaseProof) ComputeProof ¶
func (*BaseProof) CreateBaseCaseWitness ¶
func (po *BaseProof) CreateBaseCaseWitness( rawTxBytes []byte, currTxId [32]byte, ) (witness.Witness, error)
FIXME: This is duplicated from groth16/common.go
func (*BaseProof) CreateLightWitness ¶ added in v0.1.4
func (*BaseProof) VerifyProof ¶
type NormalProof ¶
type NormalProof struct { CurveId ecc.ID InnerField *big.Int OuterField *big.Int Ccs *constraint.ConstraintSystem VerifyingKey *native_groth16.VerifyingKey ProvingKey *native_groth16.ProvingKey BaseProofObj *BaseProof // contains filtered or unexported fields }
func NewNormalProof ¶
func NewNormalProof(prefixSize int, postfixSize int, baseProof *BaseProof) (*NormalProof, error)
func (*NormalProof) ComputeProof ¶ added in v0.1.4
func (po *NormalProof) ComputeProof(fullWitness witness.Witness) (native_groth16.Proof, error)
func (*NormalProof) CreateFullWitness ¶ added in v0.1.4
func (po *NormalProof) CreateFullWitness( prevPublicWitness witness.Witness, prevProof native_groth16.Proof, prevVk native_groth16.VerifyingKey, prefixBytes []byte, prevTxnIdBytes []byte, postFixBytes []byte, spendingTxId []byte) (*witness.Witness, error)
func (*NormalProof) CreateLightWitness ¶ added in v0.1.4
func (po *NormalProof) CreateLightWitness(txId []byte) (*witness.Witness, error)
func (*NormalProof) ReadKeys ¶
func (po *NormalProof) ReadKeys() error
func (*NormalProof) SetupKeys ¶
func (po *NormalProof) SetupKeys() error
func (*NormalProof) VerifyProof ¶ added in v0.1.4
func (po *NormalProof) VerifyProof(witness *witness.Witness, proof *native_groth16.Proof) bool
func (*NormalProof) WriteKeys ¶
func (po *NormalProof) WriteKeys() error
type ProofSystem ¶ added in v0.1.4
type ProofSystem struct { InnerField *big.Int OuterField *big.Int // contains filtered or unexported fields }
func NewProofSystem ¶ added in v0.1.4
func NewProofSystem(normalPrefixSize int, normalPostfixSize int) (*ProofSystem, error)
func (*ProofSystem) CreateBaseCaseProof ¶ added in v0.1.4
func (ps *ProofSystem) CreateBaseCaseProof(pInfo txivc.BaseProofInfo) (string, error)
func (*ProofSystem) VerifyBaseProof ¶ added in v0.1.4
func (ps *ProofSystem) VerifyBaseProof(txId string, jsonProof string) bool
Click to show internal directories.
Click to hide internal directories.