|
Wire Sysio Wire Sysion 1.0.0
|
#include <wallet_api.hpp>

Public Member Functions | |
| virtual | ~wallet_api () |
| virtual private_key_type | get_private_key (public_key_type pubkey) const =0 |
| virtual bool | is_locked () const =0 |
| virtual void | lock ()=0 |
| virtual void | unlock (string password)=0 |
| virtual void | check_password (string password)=0 |
| virtual void | set_password (string password)=0 |
| virtual map< public_key_type, private_key_type > | list_keys ()=0 |
| virtual flat_set< public_key_type > | list_public_keys ()=0 |
| virtual bool | import_key (string wif_key)=0 |
| virtual bool | remove_key (string key)=0 |
| virtual string | create_key (string key_type)=0 |
| virtual std::optional< signature_type > | try_sign_digest (const digest_type digest, const public_key_type public_key)=0 |
Definition at line 11 of file wallet_api.hpp.
|
inlinevirtual |
Definition at line 14 of file wallet_api.hpp.
|
pure virtual |
Checks the password of the wallet
Validates the password on a wallet even if the wallet is already unlocked, throws if bad password given.
| password | the password previously set with set_password() |
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
Creates a key within the wallet to be used to sign transactions by an account.
example: create_key K1
| key_type | the key type to create. May be empty to allow wallet to pick appropriate/"best" key type |
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Get the private key corresponding to a public key. The private key must already be in the wallet.
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Imports a WIF Private Key into the wallet to be used to sign transactions by an account.
example: import_key 5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
| wif_key | the WIF Private Key to import |
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Checks whether the wallet is locked (is unable to use its private keys).
This state can be changed by calling lock() or unlock().
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Dumps all private keys owned by the wallet.
The keys are printed in WIF format. You can import these keys into another wallet using import_key()
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Dumps all public keys owned by the wallet.
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Locks the wallet immediately
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Removes a key from the wallet.
example: remove_key SYS6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV
| key | the Public Key to remove |
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Sets a new password on the wallet.
The wallet must be either 'new' or 'unlocked' to execute this command.
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Returns a signature given the digest and public_key, if this wallet can sign via that public key
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.
|
pure virtual |
Unlocks the wallet.
The wallet remain unlocked until the lock is called or the program exits.
| password | the password previously set with set_password() |
Implemented in sysio::wallet::se_wallet, sysio::wallet::soft_wallet, and sysio::wallet::yubihsm_wallet.