Documentation ¶
Index ¶
- Variables
- type MemorySigner
- func (s MemorySigner) GetKey(_ context.Context, addr tezos.Address) (tezos.Key, error)
- func (s MemorySigner) ListAddresses(_ context.Context) ([]tezos.Address, error)
- func (s MemorySigner) SignBlock(_ context.Context, addr tezos.Address, head *codec.BlockHeader) (tezos.Signature, error)
- func (s MemorySigner) SignMessage(_ context.Context, addr tezos.Address, msg string) (tezos.Signature, error)
- func (s MemorySigner) SignOperation(_ context.Context, addr tezos.Address, op *codec.Op) (tezos.Signature, error)
- type Signer
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAddressMismatch = errors.New("signer: address mismatch")
Functions ¶
This section is empty.
Types ¶
type MemorySigner ¶
type MemorySigner struct {
// contains filtered or unexported fields
}
func NewFromKey ¶
func NewFromKey(k tezos.PrivateKey) *MemorySigner
func (MemorySigner) ListAddresses ¶
func (MemorySigner) SignBlock ¶
func (s MemorySigner) SignBlock(_ context.Context, addr tezos.Address, head *codec.BlockHeader) (tezos.Signature, error)
func (MemorySigner) SignMessage ¶
type Signer ¶
type Signer interface { // Return a list of addresses the signer manages. ListAddresses(context.Context) ([]tezos.Address, error) // Returns the public key for a managed address. Required for reveal ops. GetKey(context.Context, tezos.Address) (tezos.Key, error) // Sign an arbitrary text message wrapped into a failing noop SignMessage(context.Context, tezos.Address, string) (tezos.Signature, error) // Sign an operation. SignOperation(context.Context, tezos.Address, *codec.Op) (tezos.Signature, error) // Sign a block header. SignBlock(context.Context, tezos.Address, *codec.BlockHeader) (tezos.Signature, error) }
Click to show internal directories.
Click to hide internal directories.