-
Notifications
You must be signed in to change notification settings - Fork 33
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
[Keybase] Miniature Keybase Implementation to Enable M1 - Create and Delete #150
Comments
NOTE: Please use the |
Recommend to use a filesystem db for the implementation Currently we are between Please use one of these two options |
tl;dr @adshmh Could you or someone on your team take this on? @andrewnguyen22 did a detailed job at explaining what we need from a basic keybase solution. This is a precursor that can be worked on in parallel with the CLI being built by @deblasis: https://github.com/pokt-network/pocket/pull/169/files The keybase doesn't need to be anything fancy, and I think it can actually be copy-pastad or extracted from V0, tendermint or ignite CLI? For example, just using main/client/keys and taking out the pieces we need. |
@Jasonyou1995 When you have time to tackle things, one thing I would suggest is doing a bit of research & learning about what a keybase is and how it works. For example, see the summary of the research @deblasis did on the state of RPC in the crypto industry here: #213 As someone who has never built one myself, here is how I would go about it:
Lmk if that's enough context to get you going. |
I'm working on this issue now! Thank you so much for the detailed guide. It's very helpful for me to get started. |
@Jasonyou1995 I've removed Check out the demo @deblasis documented in #169 In v0, here are the entrypoints for In V1, @deblasis set us up for something equally as simple: Also, now that we merged in #177, you can search for |
Thanks for the clarification @Olshansk! Here are some questions I have:
|
|
Notes
|
Per my comment above, I also believe the demo @deblasis put together is a great starting point too: #150 (comment)
This is VERY optional if you find / learn something interesting along the way. For example, see the discussion related to
We only expect an integration with V1 (i.e. this repo). The entrypoint is the CLI @deblasis is working on. The approach will be similar (though not identical) to that of V0. |
Came by this while scowering other repos: https://github.com/celestiaorg/celestia-node/blob/main/libs/keystore/keystore.go Could be an additional good reference for our keybase/keystore |
See #338 as a reference for future iterations of this work. |
## Description This PR addresses the `#150` comments throughout the `app/client/cli` directory and integrates the keybase to be used in place of reading keys from files locally. The new method has been added to the `debug/keystore.go` file `InitialiseDebugKeybase()` which reads the 999 validator private keys from the `build/localnet/manifests/private-keys.yaml` file and stores them in the keybase. This is only run when there are less than 999 keys in the keybase. To speed this up `BadgerDB`'s `WriteBatch()` function is being used - however due to the encryption/JSON encoding and then Gob encoding steps of adding private keys to the keybase this takes a few seconds when ran for the first time. This PR does not add any endpoints to interact with the keybase from the CLI this is instead tracked in the issue #489 ## Issue Fixes #484 ## Type of change Please mark the relevant option(s): - [x] New feature, functionality or library - [ ] Bug fix - [x] Code health or cleanup - [ ] Major breaking change - [ ] Documentation - [ ] Other <!-- add details here if it a different type of change --> ## List of changes - Add logic to initialise keybase with 999 validator keys - Update `app/client/cli` to use the keybase ## Testing - [x] `make develop_test` - [x] [LocalNet](https://github.com/pokt-network/pocket/blob/main/docs/development/README.md) w/ all of the steps outlined in the `README` [localnet_with_integration.webm](https://user-images.githubusercontent.com/53987565/217543043-21c35c3e-8389-44a5-968a-d3afb6cb8dd9.webm) ## Required Checklist - [x] I have performed a self-review of my own code - [x] I have commented my code, particularly in hard-to-understand areas - [x] I have tested my changes using the available tooling - [x] I have updated the corresponding CHANGELOG ### If Applicable Checklist - [ ] I have updated the corresponding README(s); local and/or global - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have added, or updated, [mermaid.js](https://mermaid-js.github.io) diagrams in the corresponding README(s) - [ ] I have added, or updated, documentation and [mermaid.js](https://mermaid-js.github.io) diagrams in `shared/docs/*` if I updated `shared/*`README(s)
Objective
Create a miniature Keybase that can create, store, and delete keys
Origin Document
In order to achieve the M1 milestone a mini-keybase implementation is needed to enable dynamic accounts and actors.
This keybase may be used for the following tasks:
Goals / Deliverables
Mini ED-25519 Keybase:
Non-Goals / Deliverables
General issue checklist
Creator: @andrewnguyen22
The text was updated successfully, but these errors were encountered: