Skip to content
This repository has been archived by the owner on Nov 17, 2022. It is now read-only.

Implement new wallet file format and secure access to wallet using password #16

Closed
avive opened this issue Jun 14, 2020 · 2 comments
Closed
Assignees
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@avive
Copy link
Member

avive commented Jun 14, 2020

Motivation

  • CLIWallet currently uses a clear-text minimalistic file format for user created accounts that we want to stop using.
  • We'd like CLIWallet to use the same file format as Smapp.
    SMIP: Spacemesh Reference Wallets - File Format and Accounts Derivation SMIPS#17.
  • Once implemented, a wallet file created in Smapp can be used in CLIWallet and vice versa using the same password.
  • We'd like add new features to CLIWallet that require the wallet file support such as adding new accounts per wallet, contacts and working with Vaults. This task enables us to build this feature.

The Task

  • Implement the same file format used by smapp for persisting wallets based on this spec:
  • The task should include integration tests that verify reading/writing data correctly to the wallet file and unlocking correctly a wallet in ram using user's password.
  • Wallet should support a wallet-file cli flag that specifies a path to a wallet file. default value for this param should be 'wallet.json' so running the wallet will look for the wallet json in the same path as the executable.
  • If wallet file can't be read on app startup, it should prompt the user to create a wallet. Wallet has 2 params: 1. path/name. 2. password. So the app should guide the user through the process of specifying this and create a wallet at the user specified path and name using the user-provided password to encrypt the private data in the wallet file.
  • If wallet file is found on startup, the app should prompt the user for a password to unlock the data in the wallet and notify the user if it was able to unlock it or not.
  • User should be able to open another wallet in the app without having to restart it. He needs to provide path and name of wallet file and password for the app to unlock it. Only one wallet needs to be unlocked/loaded to the app at any given time.
  • Once a wallet is unlocked. App should provide commands for the user to select an existing account and to create new accounts. New accounts should be added to the wallet file when they are added by the user.

Future Features

  • Create a 12-words backup from wallet's seed.
  • Restore from 12 words backup. Create a new wallet file using seed restored from 12 words.
  • Use wallet in combo with a ledger hardware wallet.
@avive avive added help wanted Extra attention is needed good first issue Good for newcomers labels Jun 14, 2020
@DaveAppleton
Copy link
Contributor

I can get this done for you (for CLIWallet)

@avive avive changed the title Update Wallet File Format Implement new wallet file format and secure access to wallet using password Dec 1, 2020
@avive
Copy link
Member Author

avive commented Dec 1, 2020

@DaveAppleton - are you still interested in writing this?

@avive avive closed this as completed Jan 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants