Crate bitcoin_hd

Source
Expand description

Library with extended support of hierarchival deterministic wallet functions.

Includes advanced derivation paths functionality and operations.

Re-exports§

pub use account::DerivationAccount;
pub use standards::Bip43;
pub use standards::DerivationStandard;
pub use standards::DescriptorType;

Modules§

account
Module implements LNPBP-32 tracking account type
standards
Derivation schemata based on BIP-43-related standards.

Structs§

DerivationSubpath
Derivation path that consisting only of single type of segments.
DerivePatternError
the provided derive pattern does not match descriptor derivation wildcard
HardenedIndex
Index for hardened children derivation; ensures that the index always >= 2^31.
HardenedIndexExpected
normal derivation index {_0} met when a hardened index was required.
IndexRange
Range of derivation indexes (in form n..m) as it can be present in the derivation path terminal segment according to BIP-88 and LNPBP-32. The range is always inclusive.
IndexRangeList
Multiple index ranges (in form a..b, c..d) as it can be present in the derivation path segment according to BOP-88 and LNPBP-32. The range is always inclusive.
UnhardenedIndex
Index for unhardened children derivation; ensures that the inner value is always < 2^31
UnhardenedIndexExpected
hardened derivation index {_0} met when a normal (unhardened) index was required.
XpubDescriptor
Descriptor for extended public key which may also hold the information information about the key origin.
XpubOrigin
Structure describing origin of some extended key
XpubkeyCore
Deterministic part of the extended public key descriptor

Enums§

AccountStep
Derivation segment for the account part of the derivation path as defined by LNPBP-32 standard
DeriveError
Errors during descriptor derivation
NonStandardDerivation
Errors happening when used derivation does not match one requried by a standard.
TerminalStep
Derivation segment for the terminal part of the derivation path as defined by LNPBP-32 standard
XpubParseError
Error parsing XpubDescriptor string representation
XpubRef
A reference to the used extended public key at some level of a derivation path.
XpubRequirementError
Errors constructing XpubOrigin.

Constants§

HARDENED_INDEX_BOUNDARY
Constant determining BIP32 boundary for u32 values after which index is treated as hardened

Traits§

DerivationPathMaster
Extension trait allowing to add more methods to DerivationPath type
HardenedNormalSplit
Extension trait allowing splitting derivation paths into hardened and unhardened components
SegmentIndexes
Trait defining common API for different types of indexes which may be present in a certain derivation path segment: hardened, unhardened, mixed.
UnsatisfiableKey
Extension trait for types containing EC keys, which can be made provably unspendable