77 Address const& defaultTransactAccount()
const;
91 int addProxyAccount(
Address const& _account);
92 bool removeProxyAccount(
unsigned _id);
95 std::vector<eth::TransactionSkeleton>
const& queuedTransactions(
int _id)
const;
96 void clearQueue(
int _id);
113 m_getPassword(_getPassword),
114 m_getAuthorisation(_getAuthorisation),
115 m_keyManager(_keyman)
121 virtual bool unlockAccount(
Address const& _account, std::string
const& _password,
unsigned _duration)
override;
136 setAccounts(_accounts);
141 for (
auto const& i: _accounts)
142 m_accounts[i.address()] = i.secret();
148 for (
auto const& i: m_accounts)
Adapted from code found on http://stackoverflow.com/questions/180947/base64-decode-snippet-in-c Origi...
#define function(a, b, c, d, k, s)
Manages real accounts (where we know the secret key) and proxy accounts (where transactions to be sen...
std::vector< eth::TransactionSkeleton > TransactionQueue
FixedAccountHolder(std::function< Interface *()> const &_client, std::vector< dev::KeyPair > const &_accounts)
bool isProxyAccount(Address const &_account) const
std::unordered_map< int, std::pair< Address, TransactionQueue > > m_transactionQueues
virtual bool unlockAccount(Address const &, std::string const &, unsigned)
Automatically authenticate all transactions for the given account for the next _duration seconds...
std::function< std::string(Address)> m_getPassword
std::function< Interface *()> m_client
AccountHolder(std::function< Interface *()> const &_client)
High-level manager of password-encrypted keys for Ethereum.
bool isRealAccount(Address const &_account) const
h160s Addresses
A vector of Ethereum addresses.
TransactionRepercussion r
Main API hub for interfacing with Ethereum.
dev::AddressHash realAccounts() const override
std::function< bool(TransactionSkeleton const &, bool)> m_getAuthorisation
SimpleAccountHolder(std::function< Interface *()> const &_client, std::function< std::string(Address)> const &_getPassword, KeyManager &_keyman, std::function< bool(TransactionSkeleton const &, bool)> _getAuthorisation=std::function< bool(TransactionSkeleton const &, bool)>())
void setAccounts(std::vector< dev::KeyPair > const &_accounts)
std::unordered_map< dev::Address, dev::Secret > m_accounts
KeyManager & m_keyManager
std::map< Address, std::pair< std::chrono::steady_clock::time_point, unsigned > > m_unlockedAccounts
std::unordered_map< Address, int > m_proxyAccounts
std::unordered_set< h160 > AddressHash
A hash set of Ethereum addresses.