Commit Graph

735 Commits

Author SHA1 Message Date
stoffu
10321fb7c2 wallet2: store subaddress lookahead settings 2018-06-01 09:02:38 +03:00
cslashm
caf9354e2f Use 'boost' mutex instead of 'std' mutex 2018-06-01 09:02:09 +03:00
cslashm
67a6dbc19f Fix sub-address tx scan.
When additional keys was needed, the TX scan failed because the
derivation data was always recomputed with the main tx_key and not
the corresponding additional one.

Moreover this patch avoid perf decreasing when not using HW device.
2018-06-01 09:01:43 +03:00
moneromooo-monero
f2e6a11703 wallet: catch exceptions dealing with ringdb and warn 2018-05-24 13:29:12 +03:00
stoffu
b964e723dd wallet2: fix for loading settings of key reuse mitigation 2018-05-24 13:25:49 +03:00
stoffu
da5dfaa1b6 wallet2: set from_height of GET_OUTPUT_DISTRIBUTION correctly
The previous expression

    req_t.from_height = X ? Y >= Z : 0;

forces the parameter to take the value of either 0 or 1.
2018-05-24 13:23:49 +03:00
cslashm
f2cd4a45a7 Add the possibility to export private view key for fast scan.
On client startup the device asks for authorization to export the private view key.
If user agree, the client hold the private view key allowing a fast blockchain scan.
If the user does not agree, the blockchain scan is fully done via the device.
2018-05-24 13:07:57 +03:00
moneromooo-monero
00b0f8dce4 rpc: allow getting pruned blocks from gettransactions
and get them pruned in find_and_save_rings, since it does not need
the pruned data in the first place.

Also set decode_to_json to false where missing, we don't need this
either.
2018-05-24 13:03:31 +03:00
moneromooo-monero
234296d376 wallet2: request transactions in slices when scanning for known rings
This avoid massive memory consumption for huge wallets
2018-05-24 13:02:35 +03:00
moneromooo-monero
a89545dacf rpc: allow getting pruned blocks from gettransactions
and get them pruned in find_and_save_rings, since it does not need
the pruned data in the first place.

Also set decode_to_json to false where missing, we don't need this
either.
2018-05-24 13:01:43 +03:00
stoffu
0aa0b8347e Fix output shuffling for multisig 2018-05-24 12:28:16 +03:00
moneromooo-monero
b63635f38d wallet2: increase rpc timeout for get_output_distribution 2018-05-16 23:11:46 +03:00
moneromooo-monero
b9eda26091 add top height to get_output_distribution, and cache it for rct
This should cache the vast majority of calls for long running wallets
2018-05-16 23:11:19 +03:00
stoffu
c71e8870db wallet2: store subaddress lookahead settings 2018-05-16 22:46:23 +03:00
cslashm
7b3aef524b Use 'boost' mutex instead of 'std' mutex 2018-05-16 22:43:27 +03:00
cslashm
7a79ba183d Fix sub-address tx scan.
When additional keys was needed, the TX scan failed because the
derivation data was always recomputed with the main tx_key and not
the corresponding additional one.

Moreover this patch avoid perf decreasing when not using HW device.
2018-05-16 22:43:05 +03:00
moneromooo-monero
8de302627a wallet2: request transactions in slices when scanning for known rings
This avoid massive memory consumption for huge wallets
2018-05-16 22:41:34 +03:00
moneromooo-monero
f4d38403a0 rpc: allow getting pruned blocks from gettransactions
and get them pruned in find_and_save_rings, since it does not need
the pruned data in the first place.

Also set decode_to_json to false where missing, we don't need this
either.
2018-05-16 22:39:18 +03:00
moneromooo-monero
ab3c7036c3 wallet2: request transactions in slices when scanning for known rings
This avoid massive memory consumption for huge wallets
2018-05-16 22:36:34 +03:00
moneromooo-monero
320db6c7b7 rpc: allow getting pruned blocks from gettransactions
and get them pruned in find_and_save_rings, since it does not need
the pruned data in the first place.

Also set decode_to_json to false where missing, we don't need this
either.
2018-05-16 22:34:05 +03:00
moneromooo-monero
cfd7928365 wallet2: fix misc issues when the ringdb can't be initialized 2018-05-16 22:27:36 +03:00
cslashm
6b818bcf5c Add the possibility to export private view key for fast scan.
On client startup the device asks for authorization to export the private view key.
If user agree, the client hold the private view key allowing a fast blockchain scan.
If the user does not agree, the blockchain scan is fully done via the device.
2018-05-16 21:47:43 +03:00
moneromooo-monero
0043d20939 fix lambda compile error on openbsd 2018-05-16 21:47:43 +03:00
stoffu
ccae806c13 wallet2: set from_height of GET_OUTPUT_DISTRIBUTION correctly
The previous expression

    req_t.from_height = X ? Y >= Z : 0;

forces the parameter to take the value of either 0 or 1.
2018-05-16 21:47:42 +03:00
stoffu
3f5e731d31 wallet2: enable the mitigation only after the fork height 2018-05-16 21:47:42 +03:00
stoffu
c455bbf413 wallet2: fix for loading settings of key reuse mitigation 2018-05-16 21:47:42 +03:00
Mikhail Mitkevichl
c0c97c0c07 import_multisig_info: fix sanity check crash in detach_blockchain 2018-05-16 15:40:23 +03:00
moneromooo-monero
2fbbccca6e wallet2: add missing parameters to get_output_histogram 2018-05-16 15:40:09 +03:00
wowario
d00b812953 set static ring size 2018-05-07 23:30:16 +03:00
moneromooo-monero
a5e0a08e8a wallet2: request transactions in slices when scanning for known rings
This avoid massive memory consumption for huge wallets
2018-05-01 11:13:11 +01:00
moneromooo-monero
1035e47dd0 rpc: allow getting pruned blocks from gettransactions
and get them pruned in find_and_save_rings, since it does not need
the pruned data in the first place.

Also set decode_to_json to false where missing, we don't need this
either.
2018-05-01 11:08:00 +01:00
moneromooo-monero
4e75860da2 wallet2: fix misc issues when the ringdb can't be initialized 2018-05-01 10:52:47 +01:00
wowario
3ed6bf8518 silent dns warning 2018-04-19 21:17:43 +03:00
wowario
0ac4b8e63e increase ringsize to 10 2018-04-19 04:21:25 +03:00
jwinterm
c473f01310 Initial commit 2018-03-29 19:55:44 -07:00
moneromooo-monero
1e393f4bb7 wallet: make the segregation height settable
via user setting first, then DNS TXT record, hardcoded fallback
2018-03-17 14:56:31 +00:00
Riccardo Spagni
0f27fc57ac Merge pull request #3336
57c0b1ed Fix typos in various files (Dimitris Apostolou)
2018-03-16 18:08:07 +02:00
moneromooo-monero
eac3a11ed3 wallet: more user friendly print_ring
It can now take a txid (to display rings for all its inputs),
and will print rings in a format that set_ring understands
2018-03-16 12:07:45 +00:00
moneromooo-monero
504428ab4a ringdb: use the genesis block as a db name
This will avoid careless forkers polluting the shared database
even if they make their own chain. They'll then automatically
start using another subdb, and any key-reusing fork of those
forks will reuse their subdbs.
2018-03-16 10:32:54 +00:00
moneromooo-monero
b09e5181cc wallet: add a set_ring command
This is so one can set rings for spent key images in case the
attackers don't merge the ring matching patch set.
2018-03-16 10:32:51 +00:00
moneromooo-monero
db10dd6d83 wallet: make ringdb an object with database state 2018-03-16 10:32:42 +00:00
moneromooo-monero
d29ea0455a wallet: add an output blackball list to avoid using those in rings 2018-03-16 10:32:37 +00:00
moneromooo-monero
18eaf19489 wallet: key reuse mitigation options
If a pre-fork output is spent on both Monero and attack chain,
any post-fork output can be deduced to be a fake output, thereby
decreasing the effective ring size.

The segregate-per-fork-outputs option, on by default, allows
selecting only pre-fork outputs in this case, so that the same
ring can be used when spending it on the other side, which does
not decrease the effective ring size.

This is intended to be SET when intending to spend Monero on the
attack fork, and to be UNSET if not intending to spend Monero
on the attack fork (since it leaks the fact that the output being
spent is pre-fork).

If the user is not certain yet whether they will spend pre-fork
outputs on a key reusing fork, the key-reuse-mitigation2 option
should be SET instead.

If you use this option and intend to spend Monero on both forks,
then spend real Monero first.
2018-03-16 10:32:34 +00:00
moneromooo-monero
5f146873c5 wallet: add shared ring database
This maps key images to rings, so that different forks can reuse
the rings by key image. This avoids revealing the real inputs like
would happen if two forks spent the same outputs with different
rings. This database is meant to be shared with all Monero forks
which don't bother making a new chain, putting users' privacy at
risk in the process. It is placed in a shared data directory by
default ($HOME/.shared-ringdb on UNIX like systems). You may
use --shared-ringdb-dir to override this location, and should
then do so for all Monero forks for them to share the database.
2018-03-16 10:32:29 +00:00
moneromooo-monero
41f727ce42 add RPC to get a histogram of outputs of a given amount 2018-03-16 10:32:26 +00:00
Dimitris Apostolou
57c0b1ed9f Fix typos in various files 2018-03-15 18:25:38 +02:00
stoffu
71d186566e replace invoke_http_json("/json_rpc",...) with invoke_http_json_rpc("/json_rpc",methodname,...) to reduce boilerplate 2018-03-14 23:23:59 +09:00
Riccardo Spagni
a69c713f8e Merge pull request #3398
c577abab wallet: fix auto low priority so that it takes effect only when saved default is 0 (stoffu)
2018-03-14 16:18:15 +02:00
Riccardo Spagni
2fe1504c03 Merge pull request #3399
1d39b265 wallet2: fix use_fork_rules() when querying version that is defined but not enabled yet (stoffu)
2018-03-14 16:17:59 +02:00
Riccardo Spagni
8b90e3141a Merge pull request #3386
9abeff59 wallet2: handle no blocks returned in refresh to mean no new blocks (moneromooo-monero)
2018-03-14 16:10:00 +02:00