Documentation ¶
Overview ¶
Package genericblinding provides interface definitions for blind signature schemes
Index ¶
- Constants
- Variables
- func MatchMessage(bd BlindingData, testScheme string, testDataType DataType, ...) (bool, error)
- type BlindMessage
- type BlindSignature
- type BlindingClient
- type BlindingData
- type BlindingFactors
- type BlindingParamClient
- type BlindingParamServer
- type BlindingServer
- type ClearMessage
- type ClearSignature
- type DataType
Constants ¶
View Source
const ( // TypeBlindingParamClient data identification TypeBlindingParamClient = iota + 1 // TypeClearMessage data identification TypeClearMessage // TypeBlindingFactors data identification TypeBlindingFactors // TypeBlindMessage data identification TypeBlindMessage // TypeBlindSignature data identification TypeBlindSignature // TypeClearSignature data identification TypeClearSignature // TypeBlindingParamServer data identification TypeBlindingParamServer )
Variables ¶
View Source
var ( // ErrBadScheme is returned if unmarshalling the data for the wrong scheme ErrBadScheme = errors.New("blinding: Data does not match scheme") // ErrBadType is returned if unmarshalling the data for the wrong scheme ErrBadType = errors.New("blinding: Data does not match type") // ErrBadSigner is returned if unmarshalling data for a foreign signer ErrBadSigner = errors.New("blinding: Foreign signer") )
Functions ¶
func MatchMessage ¶
func MatchMessage(bd BlindingData, testScheme string, testDataType DataType, testPoint *eccutil.Point) (bool, error)
MatchMessage tests parameters of a BlindingData
Types ¶
type BlindingClient ¶
type BlindingClient interface { // Blind a ClearMessage with server-supplied BlindingParamClient Blind(BlindingParamClient, ClearMessage) (BlindingFactors, BlindMessage, error) // Unblind a BlindSignature of ClearMessage using BlindingFactors Unblind(BlindingFactors, ClearMessage, BlindSignature) (ClearSignature, ClearMessage, error) // Verify that ClearSignature is a signature of ClearMessage Verify(ClearSignature, ClearMessage) (bool, error) }
BlindingClient implements a blind signature client
type BlindingData ¶
type BlindingData interface { // Marshall returns ASN.1 DER encoded data Marshal() ([]byte, error) // Unmarshall loads data that was produced by Marshall Unmarshal([]byte) (BlindingData, error) // UniqueID returns a (globally) unique, 32byte ID for this data structure that can be used for duplicate/reuse testing UniqueID() []byte // Return . SchemeData() (string, DataType, *eccutil.Point) }
BlindingData encapsulates data needed for blinding operations
type BlindingFactors ¶
type BlindingFactors BlindingData
BlindingFactors are blinding factors generated by a BlindingClient
type BlindingParamClient ¶
type BlindingParamClient BlindingData
BlindingParamClient is an encoded set of blinding parameters
type BlindingParamServer ¶
type BlindingParamServer BlindingData
BlindingParamServer is an encoded set of blinding parameters
type BlindingServer ¶
type BlindingServer interface { // Generate one-time BlindingParam GetParams() (BlindingParamClient, BlindingParamServer, error) // Sign a BlindMessage usign BlindingParam Sign(BlindingParamServer, BlindMessage) (BlindSignature, error) }
BlindingServer implements a BlindingServer
type ClearMessage ¶
type ClearMessage BlindingData
ClearMessage is a cleartext message before blinding
Click to show internal directories.
Click to hide internal directories.