Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BIP39 Cointype Fixes #44

Merged

Conversation

lemois-1337
Copy link
Collaborator

Following the recent transition from Kaspa coin type 111111 to Karlsen coin type 121337 - a change already documented on https://github.com/satoshilabs/slips/blob/master/slip-0044.md - we're in the process of adopting our specific BIP39 derivation path. This step is crucial for most integrations that do not operate a node daemon, such as hardware wallets, to ensure address compatibility across different platforms. A unique derivation path is essential for this purpose.

We currently have wallets that use the old coin type, necessitating support for both the legacy and new derivation paths. To facilitate this, a new command line option has been introduced for the create subcommand: -l (short) or --legacy (long). Here's how it functions:

  • By default, the command creates or imports a version 2 wallet using the new coin type 121337.
  • When the legacy option is invoked, it creates or imports a version 1 wallet with the original coin type 111111.

Although wallets with version 1 will remain operational, migrating KLS to a newly established version 2 wallet is strongly advised for future compatibility with both software and hardware wallets.

Final implementation for commit e20a090

Small change has been added to the karlsenwallet to show the used wallet version. Also a warning has been added when using the old wallet v1 with old derivation path.

WIP because some other changes related to BIP39 may be committed at a later stage.

Following the recent transition from Kaspa coin type (111111) to
Karlsen coin type (121337) - a change already documented on https://github.com/satoshilabs/slips/blob/master/slip-0044.md -
we're in the process of adopting our specific BIP39 derivation path.
This step is crucial for most integrations that do not operate a
node daemon, such as hardware wallets, to ensure address
compatibility across different platforms. A unique derivation path
is essential for this purpose.

We currently have wallets that use the old coin type, necessitating
support for both the legacy and new derivation paths. To facilitate
this, a new command line option has been introduced for the 'create'
subcommand: -l (short) or --legacy (long). Here's how it functions:

* By default, the command creates or imports a version 2 wallet using
  the new coin type 121337.
* When the legacy option is invoked, it creates or imports a version 1
  wallet with the original coin type 111111.

Although wallets with version 1 will remain operational, migrating KLS
to a newly established version 2 wallet is strongly advised for future
compatibility with both software and hardware wallets.

Final implementation for commit e20a090
Copy link

codecov bot commented Mar 6, 2024

Codecov Report

Attention: Patch coverage is 53.33333% with 14 lines in your changes are missing coverage. Please review.

Project coverage is 61.36%. Comparing base (77a5967) to head (d4a936f).
Report is 2 commits behind head on master.

Files Patch % Lines
cmd/karlsenwallet/daemon/server/server.go 0.00% 7 Missing ⚠️
cmd/karlsenwallet/keys/create.go 0.00% 5 Missing ⚠️
cmd/karlsenwallet/daemon/server/sign.go 0.00% 1 Missing ⚠️
cmd/karlsenwallet/keys/keys.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #44      +/-   ##
==========================================
+ Coverage   61.34%   61.36%   +0.01%     
==========================================
  Files         646      647       +1     
  Lines       31898    31914      +16     
==========================================
+ Hits        19568    19584      +16     
  Misses       9480     9480              
  Partials     2850     2850              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@lemois-1337 lemois-1337 changed the title [WIP] BIP39 Cointype Fixes BIP39 Cointype Fixes Mar 6, 2024
@lemois-1337 lemois-1337 merged commit 3c63c5e into karlsen-network:master Mar 6, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant