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

feat(signer): add ERC2335 ProxyStore #193

Merged
merged 20 commits into from
Dec 6, 2024

Conversation

ManuelBilbao
Copy link
Collaborator

@ManuelBilbao ManuelBilbao commented Nov 28, 2024

This PR implements a new way to safely store proxy keys using ERC-2335 format. It saves (and reads) the keys and secrets using the following structure:

├── PROXY_DIR_KEYS_ENV
│   └── <CONSENSUS_PUBLIC_KEY>
│       └── <MODULE_ID>
│           ├── bls/
│           │   ├── <PROXY_PUBLIC_KEY1>.json
│           │   ├── <PROXY_PUBLIC_KEY1>.sig
│           │   ├── <PROXY_PUBLIC_KEY2>.json
│           │   └── <PROXY_PUBLIC_KEY2>.sig
│           └── ecdsa/
│               ├── <PROXY_PUBLIC_KEY3>.json
│               └── <PROXY_PUBLIC_KEY3>.sig
└── <secrets_path>
    └── <CONSENSUS_PUBLIC_KEY>
        └── <MODULE_ID>
            ├── bls/
            │   ├── <PROXY_PUBLIC_KEY1>
            │   └── <PROXY_PUBLIC_KEY2>
            └── ecdsa
                └── <PROXY_PUBLIC_KEY3>

Storing in the .sig file the delegation signature

Close #71

@ManuelBilbao ManuelBilbao marked this pull request as ready for review December 2, 2024 21:02
Copy link
Collaborator

@ltitanb ltitanb left a comment

Choose a reason for hiding this comment

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

While trying the full flow using the example in da_commit i get an error error: error sending request for url (http://127.0.0.1:20000/signer/v1/generate_proxy_key) although the request is received from the server.

I've also noticed that loading the keys is quite slow when running locally, so maybe we should add a /status endpoint in the signer server and wait on that when starting the other modules in the docker compose. This can also be used to add a health check in the container

crates/common/src/signer/store.rs Outdated Show resolved Hide resolved
@ManuelBilbao
Copy link
Collaborator Author

Added a healthcheck on docker compose so singer-dependant modules don't start until signer is healthy

@ManuelBilbao ManuelBilbao requested a review from ltitanb December 5, 2024 18:37
ltitanb
ltitanb previously approved these changes Dec 6, 2024
crates/cli/src/docker_init.rs Outdated Show resolved Hide resolved
config.example.toml Outdated Show resolved Hide resolved
config.example.toml Outdated Show resolved Hide resolved
@ltitanb ltitanb merged commit 582fb87 into Commit-Boost:main Dec 6, 2024
4 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.

Persist proxy keys
2 participants