Description
openedon Apr 26, 2022
The current implementation is using BIP44 for keychain derivation path, but this one is not efficient for the archethic keychain use case, as the implementations on clients.
So we are introducing a new derivation path for keychain m/650'/account'/index'
where account can be anything and customized for each keychain and where index is the number of transaction in the chain.
The implementation of the derivation key is then custom.
About the implementation, because the hardware limitations must be considered, we might not use child derivation key function like in BIP32 (recursive and cumulative) but one-time operation to generate the private key.
For example: HMAC-512(Key=seed, Data=SHA256(derivationPath)), where the first 256 bytes of the digest are the private key.
The wallet spec is updated: https://archethic-foundation.github.io/archethic-docs/build/clients/wallet-spec)
Javascript client PR implements this new change: archethic-foundation/libjs#37
📝📝 Actions List
- Change Derivation Path for DeriveKeyPair
- Modify for Ledger Origin PublicKey
- Modify the Wallet Encoder with new Encoding scheme
- Modify for new Encoded Wallet in
generateKeyFromWallet
fn - Change Decoding of wallet as per new encoding
- Derive Address as per new Scheme
- Modify txn signature for new path
- Modify tests
- Test Changes with H/W Device
- Sanitize Code from Debug Flags