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

crypto: BIP44 derivation #2964

Merged
merged 16 commits into from
Sep 15, 2023
Merged

crypto: BIP44 derivation #2964

merged 16 commits into from
Sep 15, 2023

Conversation

redshiftzero
Copy link
Member

@redshiftzero redshiftzero commented Sep 1, 2023

Towards #2946.

This adds experimental BIP44 derivation wherein we:

  1. derive a 64-byte binary seed from the seed phrase as described in BIP39 using PBKDF2 but using only mnemonic as the salt
  2. define a BIP44 path m/44'/6532'/0' which matches the Penumbra coin_type and the account number (0) used in the test vector generator (the apostrophes indicate hardened derivation)
  3. derive the spend key bytes from BIP32 child key derivation from the seed and the above BIP44 path

@redshiftzero redshiftzero force-pushed the bip44 branch 2 times, most recently from 2cb6be9 to 0a544d7 Compare September 14, 2023 21:01
@redshiftzero redshiftzero changed the title wip: BIP44 derivation BIP44 derivation Sep 14, 2023
@redshiftzero redshiftzero marked this pull request as ready for review September 14, 2023 21:19
@redshiftzero redshiftzero changed the title BIP44 derivation wip: BIP44 derivation Sep 14, 2023
@redshiftzero redshiftzero changed the title wip: BIP44 derivation crypto: BIP44 derivation Sep 15, 2023
@redshiftzero redshiftzero temporarily deployed to smoke-test September 15, 2023 16:53 — with GitHub Actions Inactive
Copy link
Contributor

@cronokirby cronokirby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few minor nits, looks good to me otherwise!

crates/bin/pcli/src/command/keys.rs Outdated Show resolved Hide resolved
crates/bin/pcli/src/command/keys.rs Outdated Show resolved Hide resolved
@cronokirby cronokirby temporarily deployed to smoke-test September 15, 2023 23:02 — with GitHub Actions Inactive
@cronokirby cronokirby merged commit 9c80e80 into main Sep 15, 2023
8 checks passed
@cronokirby cronokirby deleted the bip44 branch September 15, 2023 23:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Testnet 56: Callisto
Development

Successfully merging this pull request may close these issues.

2 participants