-
Notifications
You must be signed in to change notification settings - Fork 4
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
Testnet securely maintain a pool of recovery codes #285
Comments
Start date changed from Nov 11th to Nov 17th (based on delays in #231). |
Start date changed from Friday Nov 19th to Wednesday Dec 1 (delayed from refactoring work in #283). |
Going to bootstrap this from a password manager. |
This still needs to be done, but we need to work out partially #403, as to whether we have a set of Node IDs in PKI or as a gestalt graph or just as a set. I prefer going down the route of the gestalt graph. But I think for efficiency sake, we still need to provide a set to the agent software and update the Once some level of integration testing is done, then this will become the next priority to have testnet integration tests fully passing @tegefaulkes @emmacasolin |
According to https://gitlab.com/MatrixAI/Engineering/Polykey/Polykey-Infrastructure/-/merge_requests/2#note_1145876524, we will inject our recovery codes into AWS secrets manager. We can use this: https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-secrets-manager/index.html to automate the injection. That means recovery code generation is done manually and also fixed. It could be done automatically if the infrastructure code had access to the recovery code generators. It would mean bringing in PK's code base and calling The Auto generation must be stable. For example if we expect the pool to be 10, and there's 5, then only generate 5 more. If there's 10, we don't delete anything. Deletion is manual for now. |
Based on working through #403, the usage of recovery code pool should be placed into the AWS secrets manager. The naming of these secrets should be:
Note that |
The secret generation is not automated, we don't have an infrastructure orchestrator at this point in time. But it could be done as part of |
@tegefaulkes please link the PR for |
The PR hasn't been made yet. I'll link it when it is created. |
No PR was made, It was pushed directly to master. I'm resolving this issue. |
Once we have the ability to use
PK_RECOVERY_CODE
to automatically bootstrap the PK keynodes, we need to create at least 1 recovery code and 1 root key to be used.The recovery code must be kept secret. I'll maintain this right now. The root key will be inside AWS's block device mounted into the ECS container and this will be kept safe inside AWS.
The recovery code will need to be used as an environment variable for ECS for the testnet.
Eventually we can store the recovery code inside a running Polykey node, and make use of AWS integrations, like our wiki page: "Service Deployment Secrets with AWS ECS".
Doing this should ensure that we don't need to maintain the volume state mounted in to the ECS container, it just has to be mutable, but it can be deleted, since everything can be recovered.
Tasks
pk bootstrap
locally to generate a recovery code and root key.pk bootstrap
on a different directory and see if the same root key is used. Compare them.This will be done for 1 single testnet node. We can scale this up later.
The text was updated successfully, but these errors were encountered: