shapeshift / web

ShapeShift Web
https://app.shapeshift.com
MIT License
166 stars 178 forks source link

Wrong account#/index# when deriving additional Thorchain addresses #8001

Closed purelycrickets closed 2 hours ago

purelycrickets commented 2 hours ago

Overview

Reported in Support and recreated by Ops:

The first address (0th address) is derived with 44'/931'/0'/0/0 which is correct.

Other tools increment the index# (last digit) when deriving additional addresses: 44'/931'/0'/0/1 44'/931'/0'/0/2 44'/931'/0'/0/3 but it seems ShapeShift is incrementing the account number instead:

44'/931'/1'/0/0 44'/931'/2'/0/0 44'/931'/3'/0/0 This creates an inconsistency between how ShapeShift works vs how all other tools work.

If a user creates a 2nd address on any other tool, and then tries to use that address on ShapeShift, they'll think the funds are gone.

Similarly, if someone creates a 2nd address on ShapeShift but then tries to use any other tool, they won't find their funds there either

References and additional details

https://jam.dev/c/33665cda-3e4e-4b77-a518-4c5175803bcf See the difference^

Acceptance Criteria

ShapeShift uses the proper account derivation index incrementation.

Need By Date

No response

Screenshots/Mockups

No response

Estimated effort

No response

gomesalexandre commented 2 hours ago

Closing as this isn't a bug - different wallets use different derivation paths for accounts 0+, this is the state of internet chains. More details in https://discord.com/channels/554694662431178782/1299096396108136549/1299098236111294494