node

package
v0.0.0-...-d9fdf4f Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2023 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveDb

func SaveDb(sdb *SecretDb, path string) error

Types

type Node

type Node struct {
	// contains filtered or unexported fields
}

func NewNode

func NewNode(nodeconfig config.NodeConfig) *Node

func (*Node) GetKeyManager

func (n *Node) GetKeyManager() *smanager.KeyManager

func (*Node) GetSecretDB

func (n *Node) GetSecretDB() *SecretDb

func (*Node) IsReady

func (n *Node) IsReady() bool

func (*Node) SetPrivk

func (n *Node) SetPrivk(hexk string) error

func (*Node) TxPool

func (n *Node) TxPool() *mempool.TxPool

func (*Node) WatchKey

func (n *Node) WatchKey(key []byte)

type SecretDb

type SecretDb struct {
	PK string `json:"priv-key"`
	// contains filtered or unexported fields
}

func CreateWithHexkey

func CreateWithHexkey(hexk string) (*SecretDb, error)

func GenerateDB

func GenerateDB(path string) *SecretDb

func LoadDb

func LoadDb(path string) *SecretDb

func (SecretDb) PrivateKey

func (s SecretDb) PrivateKey() *ecies.PrivateKey

func (SecretDb) PublicKey

func (s SecretDb) PublicKey() *ecies.PublicKey

Jump to

Keyboard shortcuts

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