HWI supports different BIP derivation paths based on the address type requested. When using Bitcoin Core descriptors, HWI follows BIP 44, 49, and 84.
Supported Address Types
- Native SegWit (P2WPKH): Uses BIP 84. Default derivation:
m/84h/0h/0h/0 (receiving) and m/84h/0h/0h/1 (change). - Legacy (P2PKH): Use
--addr-type legacy. Uses BIP 44. Derivation: m/44h/0h/0h/0 (receiving) and m/44h/0h/0h/1 (change). - Nested SegWit (P2SH-P2WPKH): Use
--addr-type sh_wit. Uses BIP 49. Derivation: m/49h/0h/0h/0 (receiving) and m/49h/0h/0h/1 (change).
Customization
- Custom Paths: Use the
--path option to specify a specific derivation path. - Bitcoin Core Integration: To ensure
getnewaddress in Bitcoin Core matches these types, you must set -addresstype=p2sh-segwit and -changetype=p2sh-segwit in your bitcoin.conf or via CLI.
# Example of requesting a specific address type via HWI CLI
./hwi.py --addr-type legacy ...
# Example of requesting a custom derivation path
./hwi.py --path "m/44'/0'/0'/0/0" ...