mock

package
v0.0.0-...-77dcbbd Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package auth implements auth module following LIP-0041.

Index

Constants

View Source
const (
	MaxKeyCount = 64
)

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	blueprint.API
}

type AuthModuleConfig

type AuthModuleConfig struct {
}

type DataSetParams

type DataSetParams struct {
	Pairs []*Pair `fieldNumber:"1"`
	Hash  bool    `fieldNumber:"2"`
}

func (*DataSetParams) Decode

func (e *DataSetParams) Decode(data []byte) error

func (*DataSetParams) DecodeFromReader

func (e *DataSetParams) DecodeFromReader(reader *codec.Reader) error

func (*DataSetParams) DecodeStrict

func (e *DataSetParams) DecodeStrict(data []byte) error

func (*DataSetParams) DecodeStrictFromReader

func (e *DataSetParams) DecodeStrictFromReader(reader *codec.Reader) error

func (*DataSetParams) Encode

func (e *DataSetParams) Encode() []byte

func (*DataSetParams) MustDecode

func (e *DataSetParams) MustDecode(data []byte)

type Endpoint

type Endpoint struct {
	blueprint.Endpoint
	// contains filtered or unexported fields
}

func (*Endpoint) Get

func (*Endpoint) HandleGetValidators

func (e *Endpoint) HandleGetValidators(w rpc.EndpointResponseWriter, r *statemachine.EndpointRequest)

type Module

type Module struct {
	blueprint.Module
	// contains filtered or unexported fields
}

func NewModule

func NewModule() *Module

func (*Module) API

func (m *Module) API() *API

func (*Module) AfterTransactionsExecute

func (m *Module) AfterTransactionsExecute(ctx *statemachine.AfterTransactionsExecuteContext) error

func (*Module) BeforeCommandExecute

func (m *Module) BeforeCommandExecute(ctx *statemachine.TransactionExecuteContext) error

func (*Module) Endpoint

func (m *Module) Endpoint() statemachine.Endpoint

func (*Module) GetCommand

func (m *Module) GetCommand(name string) (statemachine.Command, bool)

func (*Module) Init

func (m *Module) Init(cfg []byte) error

func (*Module) InitGenesisState

func (m *Module) InitGenesisState(ctx *statemachine.GenesisBlockProcessingContext) error

func (*Module) Name

func (m *Module) Name() string

func (*Module) VerifyTransaction

type Pair

type Pair struct {
	Key   codec.Hex `fieldNumber:"1"`
	Value codec.Hex `fieldNumber:"2"`
}

func (*Pair) Decode

func (e *Pair) Decode(data []byte) error

func (*Pair) DecodeFromReader

func (e *Pair) DecodeFromReader(reader *codec.Reader) error

func (*Pair) DecodeStrict

func (e *Pair) DecodeStrict(data []byte) error

func (*Pair) DecodeStrictFromReader

func (e *Pair) DecodeStrictFromReader(reader *codec.Reader) error

func (*Pair) Encode

func (e *Pair) Encode() []byte

func (*Pair) MustDecode

func (e *Pair) MustDecode(data []byte)

type SetData

type SetData struct {
	blueprint.Command
}

func (*SetData) Execute

func (*SetData) Name

func (a *SetData) Name() string

func (*SetData) Verify

type UpdateValidators

type UpdateValidators struct {
	blueprint.Command
}

func (*UpdateValidators) Execute

func (*UpdateValidators) Name

func (a *UpdateValidators) Name() string

func (*UpdateValidators) Verify

type UpdateValidatorsParams

type UpdateValidatorsParams struct {
	Keys []*ValidatorKey `fieldNumber:"1"`
}

func (*UpdateValidatorsParams) Decode

func (e *UpdateValidatorsParams) Decode(data []byte) error

func (*UpdateValidatorsParams) DecodeFromReader

func (e *UpdateValidatorsParams) DecodeFromReader(reader *codec.Reader) error

func (*UpdateValidatorsParams) DecodeStrict

func (e *UpdateValidatorsParams) DecodeStrict(data []byte) error

func (*UpdateValidatorsParams) DecodeStrictFromReader

func (e *UpdateValidatorsParams) DecodeStrictFromReader(reader *codec.Reader) error

func (*UpdateValidatorsParams) Encode

func (e *UpdateValidatorsParams) Encode() []byte

func (*UpdateValidatorsParams) MustDecode

func (e *UpdateValidatorsParams) MustDecode(data []byte)

type UserAccount

type UserAccount struct {
	Nonce uint64 `fieldNumber:"1" json:"nonce,string"`
}

func (*UserAccount) Decode

func (e *UserAccount) Decode(data []byte) error

func (*UserAccount) DecodeFromReader

func (e *UserAccount) DecodeFromReader(reader *codec.Reader) error

func (*UserAccount) DecodeStrict

func (e *UserAccount) DecodeStrict(data []byte) error

func (*UserAccount) DecodeStrictFromReader

func (e *UserAccount) DecodeStrictFromReader(reader *codec.Reader) error

func (*UserAccount) Encode

func (e *UserAccount) Encode() []byte

func (*UserAccount) MustDecode

func (e *UserAccount) MustDecode(data []byte)

type ValidatorKey

type ValidatorKey struct {
	Address       codec.Lisk32 `fieldNumber:"1" json:"address"`
	GenerationKey codec.Hex    `fieldNumber:"2" json:"generatorKey"`
	BLSKey        codec.Hex    `fieldNumber:"3" json:"blsKey"`
	BFTWeight     uint64       `fieldNumber:"4" json:"bftWeight,string"`
}

func (*ValidatorKey) Decode

func (e *ValidatorKey) Decode(data []byte) error

func (*ValidatorKey) DecodeFromReader

func (e *ValidatorKey) DecodeFromReader(reader *codec.Reader) error

func (*ValidatorKey) DecodeStrict

func (e *ValidatorKey) DecodeStrict(data []byte) error

func (*ValidatorKey) DecodeStrictFromReader

func (e *ValidatorKey) DecodeStrictFromReader(reader *codec.Reader) error

func (*ValidatorKey) Encode

func (e *ValidatorKey) Encode() []byte

func (*ValidatorKey) MustDecode

func (e *ValidatorKey) MustDecode(data []byte)

type ValidatorsData

type ValidatorsData struct {
	Keys []*ValidatorKey `fieldNumber:"1" json:"keys"`
}

func (*ValidatorsData) Decode

func (e *ValidatorsData) Decode(data []byte) error

func (*ValidatorsData) DecodeFromReader

func (e *ValidatorsData) DecodeFromReader(reader *codec.Reader) error

func (*ValidatorsData) DecodeStrict

func (e *ValidatorsData) DecodeStrict(data []byte) error

func (*ValidatorsData) DecodeStrictFromReader

func (e *ValidatorsData) DecodeStrictFromReader(reader *codec.Reader) error

func (*ValidatorsData) Encode

func (e *ValidatorsData) Encode() []byte

func (*ValidatorsData) MustDecode

func (e *ValidatorsData) MustDecode(data []byte)

Jump to

Keyboard shortcuts

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