Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RingSigner ¶
type RingSigner struct {
// contains filtered or unexported fields
}
RingSigner is a signer implementation that uses a ring to sign messages, for verification the ring signature must be verified and confirmed to be using the expected ring.
func NewRingSigner ¶
func NewRingSigner(ring *ring.Ring, privKey ringtypes.Scalar) *RingSigner
NewRingSigner creates a new RingSigner instance with the ring and private key provided
type Signer ¶
Signer is an interface that abstracts the signing of a message, it is used to sign both relay requests and responses via one of the two implementations. The Signer interface expects a 32 byte message (sha256 hash) and returns a byte slice containing the signature or any error that occurred during signing.
type SimpleSigner ¶
type SimpleSigner struct {
// contains filtered or unexported fields
}
SimpleSigner is a signer implementation that uses a private key to sign messages.
func NewSimpleSigner ¶
func NewSimpleSigner(kr keyring.Keyring, keyName string) (*SimpleSigner, error)
NewSimpleSigner creates a new SimpleSigner instance with the keyring and keyName provided It uses the private key associated with the keyName in the keyring to sign messages.