bbs

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

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

Go to latest
Published: Oct 5, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

README

A Native GoLang Implementation for BBS+ Signatures

This library is a port of the Hyperledger Ursa BBS+ implementation

Documentation

Index

Constants

View Source
const (
	// Number of bytes in scalar compressed form
	FrCompressedSize = 32
	// Number of bytes in scalar uncompressed form
	FrUncompressedSize = 48
	// Number of bytes in G1 X coordinate
	G1CompressedSize = 48
	// Number of bytes in G1 X and Y coordinates
	G1UncompressedSize = 96
	// Number of bytes in G2 X (a, b) coordinate
	G2CompressedSize = 96
	// Number of bytes in G2 X(a, b) and Y(a, b) coordinates
	G2UncompressedSize = 192
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Commitment

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

The type for creating commitments to messages that are hidden during issuance.

func (Commitment) Equal

func (c Commitment) Equal(rhs Commitment) bool

func (*Commitment) FromCompressed

func (c *Commitment) FromCompressed(data []byte) error

func (*Commitment) FromUncompressed

func (c *Commitment) FromUncompressed(data []byte) error

func (*Commitment) Hash

func (c *Commitment) Hash(data []byte)

func (Commitment) ToCompressed

func (c Commitment) ToCompressed() []byte

func (Commitment) ToUncompressed

func (c Commitment) ToUncompressed() []byte

type GeneratorG1

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

The type for creating commitments to messages that are hidden during issuance.

func (GeneratorG1) Equal

func (c GeneratorG1) Equal(rhs GeneratorG1) bool

func (*GeneratorG1) FromCompressed

func (c *GeneratorG1) FromCompressed(data []byte) error

func (*GeneratorG1) FromUncompressed

func (c *GeneratorG1) FromUncompressed(data []byte) error

func (*GeneratorG1) Hash

func (c *GeneratorG1) Hash(data []byte)

func (*GeneratorG1) Random

func (c *GeneratorG1) Random()

func (GeneratorG1) ToCompressed

func (c GeneratorG1) ToCompressed() []byte

func (GeneratorG1) ToUncompressed

func (c GeneratorG1) ToUncompressed() []byte

type GeneratorG2

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

The type for creating commitments to messages that are hidden during issuance.

func (GeneratorG2) Equal

func (c GeneratorG2) Equal(rhs GeneratorG2) bool

func (*GeneratorG2) FromCompressed

func (c *GeneratorG2) FromCompressed(data []byte) error

func (*GeneratorG2) FromUncompressed

func (c *GeneratorG2) FromUncompressed(data []byte) error

func (*GeneratorG2) Hash

func (c *GeneratorG2) Hash(data []byte)

func (*GeneratorG2) Random

func (c *GeneratorG2) Random()

func (GeneratorG2) ToCompressed

func (c GeneratorG2) ToCompressed() []byte

func (GeneratorG2) ToUncompressed

func (c GeneratorG2) ToUncompressed() []byte

type ProofChallenge

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

func (ProofChallenge) Equal

func (p ProofChallenge) Equal(rhs ProofChallenge) bool

func (*ProofChallenge) FromBytes

func (p *ProofChallenge) FromBytes(data []byte) error

func (*ProofChallenge) Hash

func (p *ProofChallenge) Hash(data []byte)

func (*ProofChallenge) Random

func (p *ProofChallenge) Random()

func (ProofChallenge) ToBytes

func (p ProofChallenge) ToBytes() []byte

type ProofNonce

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

func (ProofNonce) Bytes

func (p ProofNonce) Bytes() []byte

func (ProofNonce) Equal

func (p ProofNonce) Equal(rhs ProofNonce) bool

func (*ProofNonce) Hash

func (p *ProofNonce) Hash(data []byte)

func (*ProofNonce) Random

func (p *ProofNonce) Random()

func (*ProofNonce) SetBytes

func (p *ProofNonce) SetBytes(data []byte) error

type PublicKey

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

func (PublicKey) Bytes

func (p PublicKey) Bytes(compressed bool) []byte

func (PublicKey) MessageCount

func (p PublicKey) MessageCount() int

func (*PublicKey) SetBytes

func (p *PublicKey) SetBytes(data []byte, compressed bool) error

type SecretKey

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

func (SecretKey) Bytes

func (k SecretKey) Bytes() []byte

func (SecretKey) Equal

func (k SecretKey) Equal(rhs SecretKey) bool

func (*SecretKey) Hash

func (k *SecretKey) Hash(data []byte)

func (*SecretKey) Random

func (k *SecretKey) Random()

func (*SecretKey) SetBytes

func (k *SecretKey) SetBytes(data []byte) error

type SignatureBlinding

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

func (SignatureBlinding) Bytes

func (m SignatureBlinding) Bytes() []byte

func (SignatureBlinding) Equal

func (*SignatureBlinding) Hash

func (m *SignatureBlinding) Hash(data []byte)

func (*SignatureBlinding) Random

func (m *SignatureBlinding) Random()

func (*SignatureBlinding) SetBytes

func (m *SignatureBlinding) SetBytes(data []byte) error

type SignatureMessage

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

func (SignatureMessage) Bytes

func (m SignatureMessage) Bytes() []byte

func (SignatureMessage) Equal

func (m SignatureMessage) Equal(rhs SignatureMessage) bool

func (*SignatureMessage) Hash

func (m *SignatureMessage) Hash(data []byte)

func (*SignatureMessage) Random

func (m *SignatureMessage) Random()

func (*SignatureMessage) SetBytes

func (m *SignatureMessage) SetBytes(data []byte) error

Jump to

Keyboard shortcuts

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