mirror of
https://github.com/monero-project/monero.git
synced 2025-08-23 17:35:13 -04:00
wallet: add a --generate-from-json flag
It takes a filename containing JSON data to generate a wallet. The following fields are valid: version: integer, should be 1 filename: string, path/filename for the newly created wallet scan_from_height: 64 bit unsigned integer, optional password: string, optional viewkey: string, hex representation spendkey: string, hex representation seed: string, optional, list of words separated by spaces Either seed or private keys should be given. If using private keys, the spend key may be omitted (the wallet will not be able to spend, but will see incoming transactions). If scan_from_height is given, blocks below this height will not be checked for transactions as an optimization.
This commit is contained in:
parent
eb1b87d239
commit
a2e378b91b
4 changed files with 192 additions and 10 deletions
|
@ -490,7 +490,7 @@ void wallet2::process_new_blockchain_entry(const cryptonote::block& b, const cry
|
|||
//handle transactions from new block
|
||||
|
||||
//optimization: seeking only for blocks that are not older then the wallet creation time plus 1 day. 1 day is for possible user incorrect time setup
|
||||
if(b.timestamp + 60*60*24 > m_account.get_createtime())
|
||||
if(b.timestamp + 60*60*24 > m_account.get_createtime() && height >= m_refresh_from_block_height)
|
||||
{
|
||||
TIME_MEASURE_START(miner_tx_handle_time);
|
||||
process_new_transaction(b.miner_tx, height, true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue