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

User should be able to "encrypt and save" restore progress. #16

Open
BenWestgate opened this issue Sep 2, 2023 · 2 comments
Open

User should be able to "encrypt and save" restore progress. #16

BenWestgate opened this issue Sep 2, 2023 · 2 comments
Labels
enhancement New feature or request help wanted Extra attention is needed low priority
Milestone

Comments

@BenWestgate
Copy link
Owner

For L1 or L2 it should ask them if they'd like to save their restore progress to their Persistent Storage.

This would require writing an encryption key/passphrase (transfer key or resume key) down that is used temporarily until this wallet's seed is restored in full.

Save the last session's progress in an folder named by the unique Wallet name all at once to obfuscate the threshold.

Pad to the length of 8 shares as that is the maximum data that could be loaded without restoring the max threshold of 9.

Add random noise equal to this length so plaintext shares can not be linked with the ciphertext saved progress.

Use public key cryptography so that entered shares can be deniably encrypted to the Persistent Storage without re-entering that transport key each session. Deniable encryption means a random noise length of the plaintext is added before asymmetrically encrypting and discarded after decryption.

Private key length 128-bits. 256-bit ECC must be used, the public key is saved to the device, indexed by the shares identifier.

If the user "resumes" a wallet restore and types a correct resume key, it will be as if they had entered all their previously saved shares, even from multiple sessions. Effectively "loading" all saved restore progress for that header.

An incorrect resume key would throw an error as the result would be random data, not valid shares.

The resume keypair is unique per Share Header being restored and it is destroyed along with all ciphertexts immediately after a successful wallet restoration.

This allows multiple share sets to be restored in parallel as long as they all have unique headers.

Entering a valid share with an identical header to previously saved and encrypted shares will cause the software to ask if the user is ready to enter their resume key to "resume restoring secret with header ms1XYYYY".

The choices will be resume (decrypt and automatically enter saved shares) and Continue. After each valid share is entered, it will ask again if they'd like to load their saved progress (which will ask for the resume key) which they can skip. If they need to quit again, progress can be encrypted by this header's resume restore public key without writing or entering the private key.

The resume private key can be securely stored until the user is in a safe place to restore the seed and wallet.

@BenWestgate BenWestgate added enhancement New feature or request help wanted Extra attention is needed labels Sep 2, 2023
Copy link

Stale issue message

@BenWestgate BenWestgate transferred this issue from BenWestgate/Bails May 26, 2024
@BenWestgate
Copy link
Owner Author

This issue belongs here since Bails will have nothing to do with codex32 creation and restore when this repo is finished.

@BenWestgate BenWestgate added this to the L2 milestone May 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed low priority
Projects
None yet
Development

No branches or pull requests

1 participant