Commit graph

4913 commits

Author SHA1 Message Date
moneromooo-monero
0ac22d0e1c
core: add --block-rate-notify
This runs a command whenever the block rate deviates too much
from the expectation
2019-02-12 12:16:06 +00:00
moneromooo-monero
7d2f817f5e
blockchain: add --reorg-notify
This will trigger if a reorg is seen. This may be used to do things
like stop automated withdrawals on large reorgs.

%s is replaced by the height at the split point
%h is replaced by the height of the new chain
%n is replaced by the number of new blocks after the reorg
2019-02-12 12:16:04 +00:00
moneromooo-monero
1168e8d5d5
cryptonote_core: warn when the block rate deviates from expectations
The warning threshold is set to allow a false positive every
ten days on average.
2019-02-12 12:16:02 +00:00
moneromooo-monero
842a5d8bbe
notify: handle arbitrary tags 2019-02-12 12:15:59 +00:00
moneromooo-monero
ebc60a098d
ArticMine's new block weight algorithm
This curbs runaway growth while still allowing substantial
spikes in block weight

Original specification from ArticMine:

here is the scaling proposal
Define: LongTermBlockWeight
Before fork:
LongTermBlockWeight = BlockWeight
At or after fork:
LongTermBlockWeight = min(BlockWeight, 1.4*LongTermEffectiveMedianBlockWeight)
Note: To avoid possible consensus issues over rounding the LongTermBlockWeight for a given block should be calculated to the nearest byte, and stored as a integer in the block itself. The stored LongTermBlockWeight is then used for future calculations of the LongTermEffectiveMedianBlockWeight and not recalculated each time.
Define:   LongTermEffectiveMedianBlockWeight
LongTermEffectiveMedianBlockWeight = max(300000, MedianOverPrevious100000Blocks(LongTermBlockWeight))
Change Definition of EffectiveMedianBlockWeight
From (current definition)
EffectiveMedianBlockWeight  = max(300000, MedianOverPrevious100Blocks(BlockWeight))
To (proposed definition)
EffectiveMedianBlockWeight  = min(max(300000, MedianOverPrevious100Blocks(BlockWeight)), 50*LongTermEffectiveMedianBlockWeight)
Notes:
1) There are no other changes to the existing penalty formula, median calculation, fees etc.
2) There is the requirement to store the LongTermBlockWeight of a block unencrypted in the block itself. This  is to avoid possible consensus issues over rounding and also to prevent the calculations from becoming unwieldy as we move away from the fork.
3) When the  EffectiveMedianBlockWeight cap is reached it is still possible to mine blocks up to 2x the EffectiveMedianBlockWeight by paying the corresponding penalty.
2019-02-12 12:15:54 +00:00
moneromooo-monero
f985d70f91
wallet2: extend fake out picks away from the gamma pick
in order to unbias selection from blocks with few txes
2018-10-23 09:56:32 +00:00
Riccardo Spagni
d6da74ab5b
Merge pull request #4698
ea723eef update version to 0.13.0.4 (Riccardo Spagni)
2018-10-22 23:27:02 +02:00
Riccardo Spagni
ea723eeffa
update version to 0.13.0.4 2018-10-22 23:10:58 +02:00
Lee Clagett
64c8981c1c Providing user supplied default constructor for expect<void> 2018-10-22 15:39:10 +00:00
Riccardo Spagni
1504424887
Merge pull request #4667
14515ef2 blockchain: move two new verification errors to the verify category (moneromooo-monero)
2018-10-20 20:44:38 +02:00
Riccardo Spagni
3a44fa2582
Merge pull request #4660
742dec8d rpc: fix output distribution caching ignoring chain changes (moneromooo-monero)
2018-10-20 20:44:04 +02:00
Riccardo Spagni
367cf3729b
Merge pull request #4643
c28ea6b6 device: fixed Ledger Nano S device selection (xiphon)
2018-10-20 20:43:46 +02:00
Riccardo Spagni
510d54edd7
Merge pull request #4651
8d098ad5 Rename "blackball" for clarity (moneromooo-monero)
2018-10-20 20:43:28 +02:00
Riccardo Spagni
37c6636199
Merge pull request #4638
a23c80df core: don't verify range proofs multiple times (moneromooo-monero)
2018-10-20 20:43:09 +02:00
Riccardo Spagni
ca6b6ca0d3
Merge pull request #4636
d7ff707b tx_pool: revert #4592 and move bin2hex conversion to on_get_transaction_pool (stoffu)
2018-10-20 20:42:51 +02:00
Riccardo Spagni
dc6da786d3
Merge pull request #4630
e4ce26c7 spawn: close all file descriptors before execve (moneromooo-monero)
2018-10-20 20:42:05 +02:00
Riccardo Spagni
effb22cfc4
Merge pull request #4627
bd482802 util: close keys file lock on exec (moneromooo-monero)
2018-10-20 20:41:45 +02:00
moneromooo-monero
14515ef230
blockchain: move two new verification errors to the verify category
Lest we get people get scared again
2018-10-19 21:11:31 +00:00
moneromooo-monero
742dec8d6a
rpc: fix output distribution caching ignoring chain changes
0 is placeholder for whole chain, so we should compare chain
height changes rather than chain-height-or-zero. Even this isn't
totally foolproof if a blocks are popped and the same number
added again, but it is much better as it prevents the data from
slowly going out of sync.
2018-10-19 09:22:59 +00:00
moneromooo-monero
8d098ad508
Rename "blackball" for clarity
Apparently some people seem to think it's a censorship list...
2018-10-18 18:46:17 +00:00
xiphon
c28ea6b617 device: fixed Ledger Nano S device selection 2018-10-18 04:37:30 +00:00
stoffu
d7ff707b52
tx_pool: revert #4592 and move bin2hex conversion to on_get_transaction_pool 2018-10-18 10:10:36 +09:00
moneromooo-monero
a23c80dfce
core: don't verify range proofs multiple times 2018-10-17 16:23:31 +00:00
moneromooo-monero
e4ce26c79f
spawn: close all file descriptors before execve
No need to give whatever we're calling access to what we use
2018-10-17 09:31:46 +00:00
moneromooo-monero
bd48280290
util: close keys file lock on exec 2018-10-16 17:21:08 +00:00
Riccardo Spagni
5638b07d9f
Merge pull request #4603
8e7baeb3 daemon: fix reading past stack on exit (moneromooo-monero)
2018-10-16 18:22:55 +02:00
moneromooo-monero
7ae3ebc7a8
wallet_rpc_server: fix change_wallet_password RPC 2018-10-16 15:18:24 +00:00
Riccardo Spagni
ccc7e3afae
Merge pull request #4622
32ba6f3a wallet2_api: fix generating new wallet in the GUI (moneromooo-monero)
2018-10-16 17:14:09 +02:00
moneromooo-monero
32ba6f3adb
wallet2_api: fix generating new wallet in the GUI
It was creating a new wallet without a password first (this should
be fixed), then not changing the password correctly
2018-10-16 14:47:22 +00:00
moneromooo-monero
8e7baeb394
daemon: fix reading past stack on exit 2018-10-15 22:14:17 +00:00
Riccardo Spagni
5881bec7d6
bump version to 0.13.0.3 2018-10-15 16:23:35 +02:00
Riccardo Spagni
b66c523046
Merge pull request #4596
e3e1f836 tx_pool: store hex string instead of raw binary to tx_blob of get_transaction_pool RPC (stoffu)
2018-10-15 13:56:18 +02:00
Riccardo Spagni
6834ce6de2
Merge pull request #4574
a04d68f6 SOFTWARE is the default wallet device (m2049r)
2018-10-15 13:50:21 +02:00
Riccardo Spagni
8beb3cd2a1
Merge pull request #4569
e25d21a7 simplewallet: mark default-ring-size setting as obsolete (moneromooo-monero)
2018-10-15 13:49:58 +02:00
Riccardo Spagni
dc24639e64
Merge pull request #4579
d7f3805d Revert "p2p: connect via the bound ip, if any" (moneromooo-monero)
2018-10-15 13:49:32 +02:00
Riccardo Spagni
92f42b1e81
Merge pull request #4570
3b04e2e3 daemon: do not run complex code in a signal handler (moneromooo-monero)
2018-10-15 13:49:05 +02:00
Riccardo Spagni
29d7ef0fe0
Merge pull request #4568
2509717b simplewallet: fix view key parsing in --generate-from-view-key (moneromooo-monero)
2018-10-15 13:48:21 +02:00
Riccardo Spagni
a9504f7001
Merge pull request #4587
067e232b password: fix secure input with echo on windows (moneromooo-monero)
2018-10-15 13:47:54 +02:00
stoffu
e3e1f83694
tx_pool: store hex string instead of raw binary to tx_blob of get_transaction_pool RPC
Inspired by https://github.com/masari-project/masari/issues/93
2018-10-15 20:09:32 +09:00
moneromooo-monero
b215ea9f56
password: fix backspace outputting ^? on linux on echoing secure input 2018-10-14 10:39:40 +00:00
moneromooo-monero
067e232b19
password: fix secure input with echo on windows
Thanks to iDunk for the testing back and forth
2018-10-14 10:38:11 +00:00
moneromooo-monero
d7f3805d2e
Revert "p2p: connect via the bound ip, if any"
This reverts commit 909398efc7.

It looks like it's causing trouble with tor on some setups
2018-10-13 10:20:15 +00:00
m2049r
a04d68f698
SOFTWARE is the default wallet device 2018-10-12 23:15:02 +02:00
moneromooo-monero
3b04e2e3d4
daemon: do not run complex code in a signal handler
instead, delegate the work to a one off thread
and notify it from the signal handler
2018-10-12 19:17:55 +00:00
moneromooo-monero
e25d21a788
simplewallet: mark default-ring-size setting as obsolete 2018-10-12 13:01:00 +00:00
moneromooo-monero
2509717b11
simplewallet: fix view key parsing in --generate-from-view-key 2018-10-12 12:55:57 +00:00
Riccardo Spagni
e0f4606a72
remove -release from the version string 2018-10-09 22:57:15 +02:00
Riccardo Spagni
d7d6d23867
update version for release 2018-10-09 22:37:21 +02:00
Riccardo Spagni
1b9e6861b7
Merge pull request #4540
8833aec0 wallet2: fix cold signing using non padded bulletproofs (moneromooo-monero)
2018-10-09 16:44:51 +02:00
Riccardo Spagni
d8f95843c4
Merge pull request #4535
c716a331 device: increase ledger timeout to 2 minutes (selsta)
2018-10-09 16:44:05 +02:00
Riccardo Spagni
e16982617b
Merge pull request #4538
bd7b800f device_io_hid: fix DEFAULT_* type (too short) and init time (moneromooo-monero)
2018-10-09 16:44:01 +02:00
Riccardo Spagni
eca27122df
Merge pull request #4532
8f22e808 device: destroy device objects on exit (moneromooo-monero)
2018-10-09 16:43:55 +02:00
Riccardo Spagni
4b609dede3
Merge pull request #4530
77471e23 blockchain_blackball: fix stray ! (moneromooo-monero)
2018-10-08 22:07:34 +02:00
Riccardo Spagni
161fd13768
Merge pull request #4527
c5a97315 Remove last traces of libpcsc-lite (moneromooo-monero)
2018-10-08 22:07:27 +02:00
Riccardo Spagni
f5df0e272e
Revert "Merge pull request #4472"
This reverts commit b26ab0b580.
2018-10-08 21:42:38 +02:00
Riccardo Spagni
34da7d852b
Merge pull request #4514
85e58cb2 blockchain_blackball: fix stats double counting (moneromooo-monero)
2018-10-08 13:03:11 +02:00
Riccardo Spagni
84cc3b916e
Merge pull request #4036
9acf42d3 Multisig M/N functionality core tests added (naughtyfox)
9f3963e8 Arbitrary M/N multisig schemes: * support in wallet2 * support in monero-wallet-cli * support in monero-wallet-rpc * support in wallet api * support in monero-gen-trusted-multisig * unit tests for multisig wallets creation (naughtyfox)
2018-10-07 20:04:10 +02:00
Riccardo Spagni
b63f1ea637
Merge pull request #4505
977df631 Fix some calls to the translation function (Guillaume LE VAILLANT)
2018-10-07 20:04:09 +02:00
Riccardo Spagni
b26ab0b580
Merge pull request #4472
02d3ef7b blocks: use auto-generated .c files instead of 'LD -r -b binary' (xiphon)
2018-10-06 11:15:43 +02:00
Riccardo Spagni
17ab6fdd5a
Merge pull request #4495
34a85e0c wallet2: disable height based segregation (moneromooo-monero)
2018-10-06 11:15:43 +02:00
Riccardo Spagni
a2cd4f2cc7
Merge pull request #4499
c5928bde wallet2_api: fix build with C++14 (moneromooo-monero)
2018-10-06 11:15:43 +02:00
Riccardo Spagni
9556ba0d66
Merge pull request #4390
a0613532 secure_pwd_reader: Add proper Unicode handling [Ryo contribution] (fireice-uk)
579383c2 simplewallet: Add Unicode input_line [Ryo backport] (fireice-uk)
2018-10-06 11:15:43 +02:00
Riccardo Spagni
5adbede27f
Merge pull request #4487
7c790f11 Fix rtxn usage in BlockchainLMDB::get_estimated_batch_size (Howard Chu)
2018-10-06 11:15:39 +02:00
Riccardo Spagni
735a33e8d8
Merge pull request #4485
5ec929fb daemon: do not display uptime when not known (moneromooo-monero)
2018-10-02 22:45:52 +02:00
Riccardo Spagni
e037534f44
Merge pull request #4490
bccd88dd wallet2: clear found out for every tx key (doy-lee)
2018-10-02 22:45:50 +02:00
Riccardo Spagni
9570081ae5
Merge pull request #4484
2c74b1a1 wallet_rpc_server: include all transfer records for a txid (moneromooo-monero)
2018-10-02 22:45:50 +02:00
Riccardo Spagni
e0fa7fa384
Merge pull request #4482
25e5890d wallet: fix --generate-from-json using wrong password (moneromooo-monero)
2018-10-02 22:45:50 +02:00
Riccardo Spagni
9c426a30f9
Merge pull request #4479
d5541e44 common: Windows 'spawn' support for tx and block notifications (xiphon)
2018-10-02 22:45:48 +02:00
Riccardo Spagni
ca9b2493ee
Merge pull request #4476
fa9e54b6 build: fix gcc false positive 'stringop-overflow' warning (xiphon)
2018-10-02 22:45:48 +02:00
Riccardo Spagni
cf436cde1a
Merge pull request #4475
6da36ea0 wallet2_api: blackball/unblackball now take two parameters (moneromooo-monero)
2018-10-02 22:45:48 +02:00
Riccardo Spagni
88a0985104
Merge pull request #4470
2fbf38ee Fix 32bit depends builds (TheCharlatan)
17142ec9 malloc scratchpad for all supported android archs (m2049r)
6a781408 Make depends use self built clang for darwin (TheCharlatan)
69da14e1 fixes make debug compilation on OSX (Dusan Klinec)
fe125647 Fixup RENAME_DB() macro (Howard Chu)
b2972927 osx compilation fix: missing boost libs added (Dusan Klinec)
174f31bf simplewallet: don't complain about payment id on pool mined blocks (moneromooo-monero)
89288863 README: mention ASAN usage alongside valgrind (moneromooo-monero)
83debef9 wallet_rpc_server: remove verbose field in incoming_transfers query (moneromooo-monero)
a69271fa Fixed a typo (Piotr Kąkol)
92d1da28 unit_tests: fix build with GCC 5.4.0 on ubuntu (moneromooo-monero)
a21da905 Wallet: use unique_ptr for WalletImpl members (oneiric)
7a056f44 WalletAPI: multisigSignData bug fixed (naughtyfox)
43a06350 ringdb: use cursors to be a bit faster (moneromooo-monero)
7964d4f8 wallet2: handle corner case in picking fake outputs (moneromooo-monero)
6f5360b3 bump version to 0.13.0.1 (Riccardo Spagni)
cf470bf3 switch from master to rc (Riccardo Spagni)
2018-10-02 22:45:45 +02:00
Riccardo Spagni
4701a78ad1
Merge pull request #4467
fa942ef6 daemon: silence daemon update warnings on testnet (iDunk5400)
2018-10-02 22:45:45 +02:00
Riccardo Spagni
5fc4d57ee5
Merge pull request #4463
8110bea3 dns_utils: refresh list of usable DNSSEC servers (moneromooo-monero)
2018-10-02 22:45:33 +02:00
Riccardo Spagni
efbd42f9d9
Merge pull request #4333
73403004 add --block-notify to monerod and --tx-notify to monero-wallet-{cli,rpc} (moneromooo-monero)
2018-09-29 22:18:09 +02:00
Riccardo Spagni
4cbaa6e43d
Merge pull request #4461
7dd11711 wallet2: fix transfers between subaddresses hitting the sanity check (moneromooo-monero)
2018-09-29 22:17:21 +02:00
Riccardo Spagni
f0b3bbf808
Merge pull request #4459
bcf3f6af fuzz_tests: catch unhandled exceptions (moneromooo-monero)
3ebd05d4 miner: restore stream flags after changing them (moneromooo-monero)
a093092e levin_protocol_handler_async: do not propagate exception through dtor (moneromooo-monero)
1eebb82b net_helper: do not propagate exceptions through dtor (moneromooo-monero)
fb6a3630 miner: do not propagate exceptions through dtor (moneromooo-monero)
2e2139ff epee: do not propagate exception through dtor (moneromooo-monero)
0749a8bd db_lmdb: do not propagate exceptions in dtor (moneromooo-monero)
1b0afeeb wallet_rpc_server: exit cleanly on unhandled exceptions (moneromooo-monero)
418a9936 unit_tests: catch unhandled exceptions (moneromooo-monero)
ea7f9543 threadpool: do not propagate exceptions through the dtor (moneromooo-monero)
6e855422 gen_multisig: nice exit on unhandled exception (moneromooo-monero)
53df2deb db_lmdb: catch error in mdb_stat calls during migration (moneromooo-monero)
e67016dd blockchain_blackball: catch failure to commit db transaction (moneromooo-monero)
661439f4 mlog: don't remove old logs if we failed to rename the current file (moneromooo-monero)
5fdcda50 easylogging++: test for NULL before dereference (moneromooo-monero)
7ece1550 performance_test: fix bad last argument calling add_arg (moneromooo-monero)
a085da32 unit_tests: add check for page size > 0 before dividing (moneromooo-monero)
d8b1ec8b unit_tests: use std::shared_ptr to shut coverity up about leaks (moneromooo-monero)
02563bf4 simplewallet: top level exception catcher to print nicer messages (moneromooo-monero)
c57a65b2 blockchain_blackball: fix shift range for 32 bit archs (moneromooo-monero)
2018-09-29 22:17:00 +02:00
Riccardo Spagni
33aa05678f
Merge pull request #4458
921b0fb1 use default create_address_file argument (m2049r)
2018-09-29 22:16:40 +02:00
Riccardo Spagni
67e6c4370b
Merge pull request #4456
06d05c21 device: set device name correctly if key_on_device is set (Dusan Klinec)
2018-09-29 22:15:52 +02:00
Riccardo Spagni
a5476f82ca
Merge pull request #4449
17142ec9 malloc scratchpad for all supported android archs (m2049r)
2018-09-29 22:15:31 +02:00
Riccardo Spagni
05c942aba8
Merge pull request #4445
fe125647 Fixup RENAME_DB() macro (Howard Chu)
2018-09-29 22:14:09 +02:00
Riccardo Spagni
931e7faa0b
Merge pull request #4439
174f31bf simplewallet: don't complain about payment id on pool mined blocks (moneromooo-monero)
2018-09-29 22:13:17 +02:00
Riccardo Spagni
52b639bcd0
Merge pull request #4427
83debef9 wallet_rpc_server: remove verbose field in incoming_transfers query (moneromooo-monero)
2018-09-29 22:12:31 +02:00
Riccardo Spagni
86a137aff3
Merge pull request #4417
a21da905 Wallet: use unique_ptr for WalletImpl members (oneiric)
2018-09-29 22:11:32 +02:00
Riccardo Spagni
acc9b32749
Merge pull request #4409
7a056f44 WalletAPI: multisigSignData bug fixed (naughtyfox)
2018-09-29 22:11:13 +02:00
Riccardo Spagni
9d0b177720
Merge pull request #4407
43a06350 ringdb: use cursors to be a bit faster (moneromooo-monero)
2018-09-29 22:10:48 +02:00
Riccardo Spagni
0d062bacfb
Merge pull request #4406
7964d4f8 wallet2: handle corner case in picking fake outputs (moneromooo-monero)
2018-09-29 21:51:51 +02:00
moneromooo-monero
7340300460
add --block-notify to monerod and --tx-notify to monero-wallet-{cli,rpc}
Those take a command line of the form "A [B]", with A being the
name (and optional path, if not in the caller's CWD, but fully
qualified path is recommended, avoids possible security issues)
to a program, and optional arguments. Any occurence of the two
character string "%s" will be replaced by the hash of the block
or transaction which triggered the notification.

Tokenization is barebones. If you want things like pipes, calls
to paths with spaces, etc, then use a script (though exec time
will suffer).

block-notify is called when a new block is added onto the chain.

tx-notify is called when a new transaction happens with the
wallet as source and/or destination.

It is the notification program's responsibility to determine what
to do in those cases.

Note that this is asynchronous, so it is very possible that:
- the notification programs will be run out of order
- several events happen before the notification for the first one

A Windows port would be nice if someone wants to make one.
2018-09-29 08:44:18 +00:00
moneromooo-monero
83debef99e
wallet_rpc_server: remove verbose field in incoming_transfers query
The key image (which was only supplied if verbose was true) is
readily available, not a secret key, and it was only modelled
after the CLI command because it's a bit spammy for the CLI.
2018-09-28 17:06:56 +00:00
moneromooo-monero
7dd11711b0
wallet2: fix transfers between subaddresses hitting the sanity check
Transfers between subaddresses are accounted for differently
2018-09-28 10:41:17 +00:00
moneromooo-monero
3ebd05d4e5
miner: restore stream flags after changing them
Coverity 136462
2018-09-27 18:17:32 +00:00
moneromooo-monero
fb6a363050
miner: do not propagate exceptions through dtor
Coverity 161862
2018-09-27 17:42:39 +00:00
moneromooo-monero
0749a8bd3c
db_lmdb: do not propagate exceptions in dtor
Not much we can do here

Coverity 161875
2018-09-27 17:29:15 +00:00
moneromooo-monero
1b0afeeb1c
wallet_rpc_server: exit cleanly on unhandled exceptions
Coverity 161868
2018-09-27 17:29:12 +00:00
moneromooo-monero
ea7f954381
threadpool: do not propagate exceptions through the dtor
This would call terminate.
We ignore exceptions in pthread_join instead, as this is not
a fatal problem here.

Coverity 182568
2018-09-27 17:29:02 +00:00
moneromooo-monero
6e8554221f
gen_multisig: nice exit on unhandled exception
Coverity 182569
2018-09-27 17:28:59 +00:00
moneromooo-monero
53df2deb36
db_lmdb: catch error in mdb_stat calls during migration
Coverity 188305
2018-09-27 17:28:53 +00:00
moneromooo-monero
e67016ddb4
blockchain_blackball: catch failure to commit db transaction
Coverity 188349
2018-09-27 17:28:50 +00:00
m2049r
921b0fb11b
use default create_address_file argument 2018-09-27 17:59:46 +02:00
moneromooo-monero
02563bf4b9
simplewallet: top level exception catcher to print nicer messages
Coverity 188408
2018-09-27 10:56:54 +00:00
moneromooo-monero
c57a65b246
blockchain_blackball: fix shift range for 32 bit archs
Coverity 188406
2018-09-27 10:54:35 +00:00