blindsecp256k1v0

package
v0.0.0-...-04b9532 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2021 License: GPL-3.0 Imports: 6 Imported by: 0

README

go-blindsecp256k1/v0

The directory v0 implements the blind signature over secp256k1, based on "An Efficient Blind Signature Scheme Based on the Elliptic Curve Discrete Logarithm Problem" paper by by Morteza Nikooghadama & Ali Zakerolhosseini.

The implementation of "New Blind Signature Schemes Based on the (Elliptic Curve) Discrete Logarithm Problem" paper by Hamid Mala & Nafiseh Nezhadansari, can be found at the root directory of this repository: https://github.com/arnaucube/go-blindsecp256k1

Documentation

Overview

Package blindsecp256k1v0 implements the Blind signature scheme explained at "An Efficient Blind Signature Scheme Based on the Elliptic Curve Discrete Logarithm Problem", by Morteza Nikooghadama & Ali Zakerolhosseini http://www.isecure-journal.com/article_39171_47f9ec605dd3918c2793565ec21fcd7a.pdf

LICENSE can be found at https://github.com/arnaucube/go-blindsecp256k1/blob/master/LICENSE

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRequestParameters

func NewRequestParameters() (*big.Int, *blindsecp256k1.Point, error)

NewRequestParameters returns a new random k (secret) & R (public) parameters

func Verify

func Verify(m *big.Int, signature *Signature, q *blindsecp256k1.PublicKey) bool

Verify checks the signature of the message m for the given PublicKey

Types

type PrivateKey

type PrivateKey big.Int

PrivateKey represents the signer's private key

func NewPrivateKey

func NewPrivateKey() (*PrivateKey, error)

NewPrivateKey returns a new random private key

func (*PrivateKey) BigInt

func (sk *PrivateKey) BigInt() *big.Int

BigInt returns a *big.Int representation of the PrivateKey

func (*PrivateKey) BlindSign

func (sk *PrivateKey) BlindSign(mBlinded *big.Int, k *big.Int) *big.Int

BlindSign performs the blind signature on the given mBlinded using SignerPrivateData values

func (*PrivateKey) Public

func (sk *PrivateKey) Public() *blindsecp256k1.PublicKey

Public returns the PublicKey from the PrivateKey

type Signature

type Signature struct {
	S *big.Int
	F *blindsecp256k1.Point
}

Signature contains the signature values S & F

func Unblind

func Unblind(sBlind *big.Int, u *UserSecretData) *Signature

Unblind performs the unblinding operation of the blinded signature for the given and the UserSecretData

type UserSecretData

type UserSecretData struct {
	A *big.Int
	B *big.Int
	C *big.Int

	F *blindsecp256k1.Point // public
}

UserSecretData contains the secret values from the User (a, b, c) and the public F

func Blind

func Blind(m *big.Int, signerPubK *blindsecp256k1.PublicKey,
	signerR *blindsecp256k1.Point) (*big.Int, *UserSecretData, error)

Blind performs the blinding operation on m using SignerPublicData parameters

Jump to

Keyboard shortcuts

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