ecc

package module
v0.0.0-...-cdaaca7 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ECC

type ECC struct {
	P big.Int
	A big.Int
	G ECPoint
}

func NewSecp256K1

func NewSecp256K1() *ECC

func (*ECC) FieldAdd

func (curve *ECC) FieldAdd(a, b *big.Int) *big.Int

func (*ECC) FieldDiv

func (curve *ECC) FieldDiv(a, b *big.Int) *big.Int

func (*ECC) FieldMul

func (curve *ECC) FieldMul(a, b *big.Int) *big.Int

func (*ECC) FieldNormal

func (curve *ECC) FieldNormal(a *big.Int) *big.Int

func (*ECC) FieldSub

func (curve *ECC) FieldSub(a, b *big.Int) *big.Int

func (*ECC) Inverse

func (curve *ECC) Inverse(x *big.Int) *big.Int

func (*ECC) NewPoint

func (curve *ECC) NewPoint(x *big.Int) *ECPoint

func (*ECC) PointAdd

func (curve *ECC) PointAdd(Q, P *ECPoint) *ECPoint

func (*ECC) PointScale

func (curve *ECC) PointScale(Q *ECPoint, N *big.Int) *ECPoint

func (*ECC) PointTwice

func (curve *ECC) PointTwice(Q *ECPoint) *ECPoint

func (*ECC) PrivateKey2Address

func (curve *ECC) PrivateKey2Address(key *big.Int) string

func (*ECC) Sqrt

func (curve *ECC) Sqrt(x *big.Int) *big.Int

type ECPoint

type ECPoint struct {
	X big.Int
	Y big.Int
}

func (*ECPoint) Bytes

func (p *ECPoint) Bytes() []byte

Jump to

Keyboard shortcuts

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