Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Keystore ¶
type Keystore interface { // CosignerIndex returns the index at which the keystore signs in a multisig configuration. // The returned value is always zero for a singlesig configuration. CosignerIndex() int // Identifier returns the SHA256 hash of the master extended public key. Identifier() (string, error) // HasSecureOutput returns whether the keystore supports to output an address securely. // This is typically done through a screen on the device or through a paired mobile phone. HasSecureOutput() bool // OutputAddress outputs the public key at the given absolute keypath for the given coin. // Please note that this is only supported if the keystore has a secure output channel. OutputAddress(signing.AbsoluteKeypath, signing.ScriptType, coin.Coin) error // ExtendedPublicKey returns the extended public key at the given absolute keypath. ExtendedPublicKey(signing.AbsoluteKeypath) (*hdkeychain.ExtendedKey, error) // SignTransaction signs the given transaction proposal. SignTransaction(coin.ProposedTransaction) error }
Keystore supports hardened key derivation according to BIP32 and signing of transactions.
type Keystores ¶
type Keystores interface { // Count returns the number of keystores in the collection. Count() int // Add adds the given keystore to the collection of keystores. Add(Keystore) error // Remove removes the given keystore from the collection of keystores. Remove(Keystore) error // HaveSecureOutput returns whether any of the keystores has a secure output. HaveSecureOutput() bool // OutputAddress outputs the address for the given coin with the given configuration on all // keystores that have a secure output. OutputAddress(*signing.Configuration, coin.Coin) error // SignTransaction signs the given proposed transaction on all keystores. SignTransaction(coin.ProposedTransaction) error // Configuration returns the configuration at the given path with the given signing threshold. Configuration(signing.ScriptType, signing.AbsoluteKeypath, int) (*signing.Configuration, error) }
Keystores models a collection of keystores that can be passed from a wallet to its accounts.
func NewKeystores ¶
NewKeystores returns a collection of the given keystores.
Click to show internal directories.
Click to hide internal directories.