hdwallet-metamask
's partial multi-account support uses a definitely-wrong derivation path
#459
Labels
tech-debt
A suboptimality that existed in code when it was written.
While
hdwallet-metamask
does not fully support multiple accounts, itsethGetAccountPaths
anddescribePath
functions do, and assume the standard BIP44 derivation scheme (m/44'/60'/n'/0/0
) even though MetaMask itself usesm/44'/60'/0'/0/n
(unless it's being used with a hardware wallet, in which case all bets are off).Options:
hdwallet-metamask
to use Metamask's native account derivation scheme in these functions instead of BIP44. (This isn't perfect, but at least it won't be clearly wrong anymore.) (This is the approach taken by metamask: use metamask-style account path derivation #424.)[]
(orthrow
) fromethGetAccountPaths
andthrow
indescribePath
to avoid exposing wrong functionality.The text was updated successfully, but these errors were encountered: