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

Solana support #38

Merged
merged 3 commits into from
Apr 16, 2024
Merged

Solana support #38

merged 3 commits into from
Apr 16, 2024

Conversation

lishawnl
Copy link
Collaborator

@lishawnl lishawnl commented Apr 15, 2024

Added Solana support:

  • Added an optional keywords arguments opts into derive functions. If opts contains network: :solana, derive public key from private key using Ed25519 algorithms.
path = "M/501'/0'/0'"
xpub = BlockKeys.CKD.derive(root_key, path, network: :solana)
  • Added Solana modules to derive address from public key and validate address.
address = BlockKeys.Solana.Address.from_xpub(xpub)
is_valid? = BlockKeys.Solana.Address.valid_address?(address)
  • Updated README with Solana support

Copy link
Contributor

@tzumby tzumby left a comment

Choose a reason for hiding this comment

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

Thanks @lishawnl, this looks great, let just a naming comment

README.md Outdated Show resolved Hide resolved
lib/block_keys/ckd.ex Outdated Show resolved Hide resolved
@lishawnl lishawnl marked this pull request as ready for review April 15, 2024 21:10
Copy link

@wchenNL wchenNL left a comment

Choose a reason for hiding this comment

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

LGTM 🔥

@lishawnl lishawnl merged commit 3f40bff into ExWeb3:master Apr 16, 2024
8 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.

3 participants