1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-28 02:18:20 +00:00

feat(core): remove deprecated path

This commit is contained in:
Ondřej Vejpustek 2024-11-22 19:14:33 +01:00
parent 6548ca7921
commit b2a9b63ea7

View File

@ -561,17 +561,7 @@ bool coin_path_check(const CoinInfo *coin, InputScriptType script_type,
valid = valid && (address_n[2] <= PATH_MAX_CHANGE); valid = valid && (address_n[2] <= PATH_MAX_CHANGE);
valid = valid && (address_n[3] <= PATH_MAX_ADDRESS_INDEX); valid = valid && (address_n[3] <= PATH_MAX_ADDRESS_INDEX);
} else if (address_n_count == 5) { } else if (address_n_count == 5) {
if (address_n[1] & PATH_HARDENED) { if ((address_n[1] & PATH_HARDENED) == 0) {
// Unchained Capital compatibility pattern. Will be removed in the
// future.
// m / 45' / coin_type' / account' / [0-1000000] / address_index
valid = valid && check_cointype(coin, address_n[1], full_check);
valid = valid && (address_n[2] & PATH_HARDENED);
valid =
valid && ((address_n[2] & PATH_UNHARDEN_MASK) <= PATH_MAX_ACCOUNT);
valid = valid && (address_n[3] <= 1000000);
valid = valid && (address_n[4] <= PATH_MAX_ADDRESS_INDEX);
} else {
// Casa proposed "universal multisig" pattern with unhardened parts. // Casa proposed "universal multisig" pattern with unhardened parts.
// m/45'/coin_type/account/change/address_index // m/45'/coin_type/account/change/address_index
valid = valid && valid = valid &&