From e30a343095bfb62a79913d2f2f68ec55c6c0003d Mon Sep 17 00:00:00 2001 From: Jack Date: Thu, 31 Oct 2024 11:01:48 -0800 Subject: [PATCH] feat: support Unchained p2wsh path fix: move unchained paths to bitcoin multisig SPENDWITNESS chore: add changelog --- core/.changelog.d/4271.added | 1 + core/src/apps/bitcoin/keychain.py | 3 +++ 2 files changed, 4 insertions(+) create mode 100644 core/.changelog.d/4271.added diff --git a/core/.changelog.d/4271.added b/core/.changelog.d/4271.added new file mode 100644 index 0000000000..25553a17cb --- /dev/null +++ b/core/.changelog.d/4271.added @@ -0,0 +1 @@ +Add P2WSH support for Unchained BIP32 paths. diff --git a/core/src/apps/bitcoin/keychain.py b/core/src/apps/bitcoin/keychain.py index 13c81d22d2..c6fbdecf04 100644 --- a/core/src/apps/bitcoin/keychain.py +++ b/core/src/apps/bitcoin/keychain.py @@ -158,6 +158,9 @@ def validate_path_against_script_type( if slip44 == SLIP44_BITCOIN: append(PATTERN_GREENADDRESS_A) append(PATTERN_GREENADDRESS_B) + if coin.coin_name in BITCOIN_NAMES and multisig: + append(PATTERN_UNCHAINED_HARDENED) + append(PATTERN_UNCHAINED_UNHARDENED) elif coin.taproot and script_type == InputScriptType.SPENDTAPROOT: append(PATTERN_BIP86)