import/export accounts

- cli: add passwordfile flag
- cli: change unlock flag only takes account
- cli: with unlock you are prompted for password or use passfile with password flag
- cli: unlockAccount used in normal client start (run) and accountExport
- cli: getPassword used in accountCreate and accountImport
- accounts: Manager.Import, Manager.Export
- crypto: SaveECDSA (to complement LoadECDSA) to save to file
- crypto: NewKeyFromECDSA added (used in accountImport and New = generated constructor)
This commit is contained in:
zelig
2015-03-23 13:00:06 +00:00
parent 658204bafc
commit c4ea921876
5 changed files with 190 additions and 39 deletions

View File

@ -104,7 +104,13 @@ var (
}
UnlockedAccountFlag = cli.StringFlag{
Name: "unlock",
Usage: "Unlock a given account untill this programs exits (address:password)",
Usage: "unlock the account given until this program exits (prompts for password).",
Value: "",
}
PasswordFileFlag = cli.StringFlag{
Name: "password",
Usage: "Password used when saving a new account and unlocking an existing account. If you create a new account make sure you remember this password.",
Value: "",
}
// logging and debug settings