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

Support btc wallet entries #9

Closed
OrestisAlpos opened this issue Jan 27, 2025 · 1 comment
Closed

Support btc wallet entries #9

OrestisAlpos opened this issue Jan 27, 2025 · 1 comment
Assignees

Comments

@OrestisAlpos
Copy link
Collaborator

Extend the ipc-cli wallet new to accept a new wallet type btc. This creates a secp256k1 key, similar to the evm wallet type, but it makes sure that the y coordinate of the key is even, as required by taproot on bitcoin.
The reason we need this is because bitcoin-backed subnets will use this wallet (the corresponding key pair) both in the subnet and on bitcoin.

The output of ipc-cli wallet list --wallet-type btc should be something like:

Address: 0xd9de7930810060e59156c213cb9abba81fde1dfd PubKey: 0402c44b5cb925062742b91f6af7b2b493ed4ea4adb753153010a2a8584980c0ce6dd5a13792d307787738744bd4ed961256660e114b7f94dce8f96beedf171a20 XOnlyPubKey: 02c44b5cb925062742b91f6af7b2b493ed4ea4adb753153010a2a8584980c0ce
Address: 0x79ab3440cfd29ad25c91557d68716a816ed8048f PubKey: 0403dbb2178b38d53d85cbcd5689bc834899eb85173c1eddd213c0c77e68a17f81bd2931b5ca6056e46132711c43eb0eeb8af72fbf943a888f4c2c3b663465b1e2 XOnlyPubKey: 03dbb2178b38d53d85cbcd5689bc834899eb85173c1eddd213c0c77e68a17f81
Address: 0x7e89195f9ce9a31aff3383e2e055747c793810e5 PubKey: 041df495ba7e5ae8bf7e9964a8587e4a39cd2e92fe3390de8e650b25afbacc729ce020e32a14741c380b12dc4b5fc144a660c710102b7ee2787fc1bc047a797d60 XOnlyPubKey: 1df495ba7e5ae8bf7e9964a8587e4a39cd2e92fe3390de8e650b25afbacc729c
Address: 0x23df81f399387e8972b5286489378f139088ea85 PubKey: 042b73a0b2ec73ac050b2cae17d7b3ffa683518f1d7fe03b6a8580a46fbdc3841621224f9bfb70402a73bdf324007b32026d9d6ab12ee55c95964196028e8eaea4 XOnlyPubKey: 2b73a0b2ec73ac050b2cae17d7b3ffa683518f1d7fe03b6a8580a46fbdc38416

That's similar to what ipc-cli wallet list --wallet-type fevm returns, but with additionally returning the XOnlyPublicKey format of the public key.

@OrestisAlpos OrestisAlpos self-assigned this Jan 27, 2025
@OrestisAlpos OrestisAlpos converted this from a draft issue Jan 27, 2025
This was referenced Jan 27, 2025
@OrestisAlpos
Copy link
Collaborator Author

Handled in PR #11 , but #16 is still to be done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

1 participant