ledger

package
v1.16.44 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2026 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

Package ledger provides hardware wallet integration via Ledger devices.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LedgerDevice

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

func New

func New() (*LedgerDevice, error)

func (*LedgerDevice) Address added in v0.2.1

func (dev *LedgerDevice) Address(hrp string, index uint32) (ids.ShortID, error)

Address returns the address at the given index

func (*LedgerDevice) Addresses added in v0.2.1

func (dev *LedgerDevice) Addresses(indices []uint32) ([]ids.ShortID, error)

Addresses returns addresses for the given indices

func (*LedgerDevice) Close added in v0.2.1

func (dev *LedgerDevice) Close() error

Close closes the connection to the ledger device

func (*LedgerDevice) Disconnect added in v0.2.1

func (dev *LedgerDevice) Disconnect() error

Disconnect closes the connection to the ledger device

func (*LedgerDevice) FindAddresses

func (dev *LedgerDevice) FindAddresses(addresses []string, maxIndex uint32) (map[string]uint32, error)

func (*LedgerDevice) FindFunds

func (dev *LedgerDevice) FindFunds(
	network network.Network,
	amount uint64,
	maxIndex uint32,
) ([]uint32, error)

FindFunds searches for a set of indices that pay a given amount

func (*LedgerDevice) GetAddresses added in v0.2.1

func (dev *LedgerDevice) GetAddresses(indices []uint32, hrp string, chainID string) ([]string, error)

GetAddresses returns Lux addresses for the given indices

func (*LedgerDevice) Sign added in v0.2.1

func (dev *LedgerDevice) Sign(hash []byte, indices []uint32) ([][]byte, error)

Sign signs a hash with the ledger device for multiple indices

func (*LedgerDevice) SignHash added in v0.2.1

func (dev *LedgerDevice) SignHash(hash []byte, indices []uint32) ([][]byte, error)

SignHash signs a hash with the ledger device for multiple indices

func (*LedgerDevice) Version added in v0.2.1

func (dev *LedgerDevice) Version() (v *version.Semantic, err error)

Version returns the version of the ledger device

Jump to

Keyboard shortcuts

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