waddrmgr: add new DerivationInfo method to ManagedPubKeyAddress
In this commit, we add a new method DerivationInfo to the ManagedPubKeyAddress interface. This method is meant to provide callers with the information necessary to independently derive each key returned by the various methods provided to derive addresses.
This commit is contained in:
parent
1ede0a1a66
commit
05d73f6899
1 changed files with 6 additions and 0 deletions
|
@ -103,6 +103,12 @@ type ManagedPubKeyAddress interface {
|
|||
// ExportPrivKey returns the private key associated with the address
|
||||
// serialized as Wallet Import Format (WIF).
|
||||
ExportPrivKey() (*btcutil.WIF, error)
|
||||
|
||||
// DerivationInfo contains the information required to derive the key
|
||||
// that backs the address via traditional methods from the HD root. For
|
||||
// imported keys, the first value will be set to false to indicate that
|
||||
// we don't know exactly how the key was derived.
|
||||
DerivationInfo() (bool, KeyScope, DerivationPath)
|
||||
}
|
||||
|
||||
// ManagedScriptAddress extends ManagedAddress and represents a pay-to-script-hash
|
||||
|
|
Loading…
Reference in a new issue