jubjub

package
v0.0.0-...-95aab37 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 14, 2021 License: MIT Imports: 3 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Jubjub

type Jubjub struct {
	// jubjub is defined over this field
	BlsR *big.Int

	// the prime order subgroup of jubjub
	JubjubS *big.Int

	D *big.Int

	Cofactor *big.Int
}

func NewJubjub

func NewJubjub() *Jubjub

func (*Jubjub) Add

func (curve *Jubjub) Add(p1 *JubjubPoint, p2 *JubjubPoint) (*JubjubPoint, error)

func (*Jubjub) GetForY

func (curve *Jubjub) GetForY(y *big.Int, shouldBeOdd bool) (*JubjubPoint, error)

func (*Jubjub) MulByCofactor

func (curve *Jubjub) MulByCofactor(point *JubjubPoint) (*JubjubPoint, error)

func (*Jubjub) Neg

func (curve *Jubjub) Neg(p *JubjubPoint) (*JubjubPoint, error)

func (*Jubjub) Point

func (curve *Jubjub) Point(x *big.Int, y *big.Int) (*JubjubPoint, error)

func (*Jubjub) ScalarMult

func (curve *Jubjub) ScalarMult(scalar *big.Int, point *JubjubPoint) (*JubjubPoint, error)

type JubjubPoint

type JubjubPoint struct {
	// contains filtered or unexported fields
}

func (*JubjubPoint) Clone

func (point *JubjubPoint) Clone() (*JubjubPoint, error)

func (*JubjubPoint) String

func (point *JubjubPoint) String() string

func (*JubjubPoint) Text

func (point *JubjubPoint) Text(base int) string

func (*JubjubPoint) VerifyOnCurve

func (point *JubjubPoint) VerifyOnCurve() error

func (*JubjubPoint) X

func (point *JubjubPoint) X() *big.Int

func (*JubjubPoint) Y

func (point *JubjubPoint) Y() *big.Int

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL