Lee Clagett
61b6e4cc67
Add aggressive restrictions to pre-handshake p2p buffer limit
2020-12-17 00:36:10 +00:00
Lee Clagett
4978f69d7a
Fix byte_stream::put_n
2020-12-14 14:45:24 -05:00
Alexander Blair
28e5e42986
Merge pull request #7110
...
d660f22ed
protocol: drop origin IP if a block fails to verify in sync mode (moneromooo-monero)
2020-12-10 17:41:59 -08:00
Alexander Blair
1e9483a2d5
Merge pull request #7009
...
7414e2bac
Change epee binary output from std::stringstream to byte_stream (Lee Clagett)
2020-12-10 17:34:50 -08:00
Alexander Blair
6bddd54f9d
Merge pull request #7003
...
08eb0949f
Change to more efficient allocation strategy in byte_stream (Lee Clagett)
2020-12-10 17:33:50 -08:00
moneromooo-monero
d660f22ed1
protocol: drop origin IP if a block fails to verify in sync mode
...
It would otherwise be possible for a peer to send bad blocks,
then disconnect and reconnect again, escaping bans
2020-12-10 21:59:18 +00:00
luigi1111
36d31ba0be
Merge pull request #7018
...
a9cd5d9
cryptonote_core: dandelion - use local height or median height if syncing (xiphon)
2020-11-29 01:58:13 -06:00
luigi1111
c041550ffa
Merge pull request #6973
...
be84f67
Switch to Dandelion++ fluff mode if no out connections for stem mode (Lee Clagett)
2020-11-29 01:54:43 -06:00
luigi1111
7a0334742a
Merge pull request #6937
...
8a282f6
Add RELINK_TARGETS, monero_add_target_no_relink and use monero_add_executable/monero_add_library where possible (mj-xmr) Add monero_add_minimal_executable and use in tests (mj-xmr)
2020-11-29 01:49:39 -06:00
luigi1111
450f1325ab
Merge pull request #6856
...
db70af1
Unit Tests: Remove block reward upper bound size checks (TheCharlatan)
2020-11-28 22:35:07 -06:00
xiphon
a9cd5d914e
cryptonote_core: dandelion - use local height or median height if syncing
2020-11-25 01:27:42 +00:00
Howard Chu
91fd634768
Better log message for unusable anon networks
2020-11-16 12:36:37 +00:00
Lee Clagett
be84f678b9
Switch to Dandelion++ fluff mode if no out connections for stem mode
2020-11-03 13:58:14 -05:00
mj-xmr
8a282f64c9
Add RELINK_TARGETS, monero_add_target_no_relink and use monero_add_executable/monero_add_library where possible (mj-xmr)
...
Add monero_add_minimal_executable and use in tests
This is done in order not to have to relink targets, when just an .so changed, but not its interface.
2020-10-28 20:08:26 +01:00
Lee Clagett
08eb0949f3
Change to more efficient allocation strategy in byte_stream
2020-10-13 15:10:54 +00:00
Lee Clagett
249eae5f4a
Allow byte_stream->byte_slice conversion to shrink unused buffer space
2020-10-13 15:09:18 +00:00
xiphon
a12a8174e0
Dandelion++: skip desynced peers in stem phase
2020-10-12 13:44:06 +00:00
Lee Clagett
7414e2bac1
Change epee binary output from std::stringstream to byte_stream
2020-10-10 15:28:40 +00:00
TheCharlatan
db70af1bbc
Unit Tests: Remove block reward upper bound size checks
...
Tests running after being compiled with `make debug-test` failed with
```
[ FAILED ] block_reward_and_current_block_weight.fails_on_huge_median_size
[ FAILED ] block_reward_and_current_block_weight.fails_on_huge_block_weight
```
With the introduction of the patch in
be82c40703 (diff-1a57d4e6013984c420da98d1adde0eafL113)
the assertions checking the weight of the median and current block
against a size limit were removed. Since the limit is now enforced by a
long divisor and a uint64_t type, checking in a separate test makes
little sense, so they are removed here.
2020-10-03 02:32:17 +02:00
luigi1111
ee0b02d0db
Merge pull request #6757
...
6a37da8
threadpool: guard against exceptions in jobs, and armour plating (moneromooo-monero)
2020-09-03 12:25:59 -05:00
moneromooo-monero
6a37da837e
threadpool: guard against exceptions in jobs, and armour plating
...
Those would, if uncaught, exit run and leave the waiter to wait
indefinitely for the number of active jobs to reach 0
2020-09-01 14:33:33 +00:00
Alexander Blair
44cd8a13ec
Merge pull request #6769
...
b641e0a2c
Add clear method to byte_stream (Lee Clagett)
2020-08-27 12:05:16 -07:00
Sarang Noether
641b08c920
CLSAG optimizations
2020-08-27 12:44:04 +00:00
moneromooo-monero
82ee01699c
Integrate CLSAGs into monero
...
They are allowed from v12, and MLSAGs are rejected from v13.
2020-08-27 12:44:04 +00:00
moneromooo-monero
8cd1d6df8f
unit_tests: add ge_triple_scalarmult_base_vartime test
2020-08-27 12:44:01 +00:00
Alexander Blair
bad5d8d6f0
Merge pull request #6690
...
7175dcb10
replace most boost serialization with existing monero serialization (moneromooo-monero)
2020-08-27 02:54:30 -07:00
Lee Clagett
b641e0a2c0
Add clear method to byte_stream
2020-08-17 21:30:34 -04:00
luigi1111
765db1ae7a
Revert "Use domain-separated ChaCha20 for in-memory key encryption"
...
This reverts commit 921dd8dde5
.
2020-08-17 14:08:59 -05:00
moneromooo-monero
7175dcb107
replace most boost serialization with existing monero serialization
...
This reduces the attack surface for data that can come from
malicious sources (exported output and key images, multisig
transactions...) since the monero serialization is already
exposed to the outside, and the boost lib we were using had
a few known crashers.
For interoperability, a new load-deprecated-formats wallet
setting is added (off by default). This allows loading boost
format data if there is no alternative. It will likely go
at some point, along with the ability to load those.
Notably, the peer lists file still uses the boost serialization
code, as the data it stores is define in epee, while the new
serialization code is in monero, and migrating it was fairly
hairy. Since this file is local and not obtained from anyone
else, the marginal risk is minimal, but it could be migrated
later if needed.
Some tests and tools also do, this will stay as is for now.
2020-08-17 16:23:58 +00:00
Alexander Blair
10ad0d7eb2
Merge pull request #6718
...
85efc88c1
Fix overflow issue in epee:misc_utils::rolling_median_t and median(), with unit test (koe)
2020-08-16 12:53:50 -07:00
Alexander Blair
01b512f3a9
Merge pull request #6716
...
76c16822d
wallet2_api: implement runtime proxy configuration (xiphon)
2020-08-16 12:52:21 -07:00
Alexander Blair
a08df6eb1b
Merge pull request #6603
...
4e2377995
Change ZMQ-JSON txextra to hex and remove unnecessary base fields (Lee Clagett)
2020-08-16 12:43:38 -07:00
Alexander Blair
009ca6fcd3
Merge pull request #6601
...
98c151ecb
Optimize ZMQ-JSON vector reading; GetBlocksFast reads 24%+ faster (Lee Clagett)
60627c9f2
Switch to insitu parsing for ZMQ-JSON; GetBlocksFast reads 13%+ faster (Lee Clagett)
fe96e66eb
Fix pruned tx for ZMQ's GetBlocksFast (Lee Clagett)
2020-08-16 12:43:11 -07:00
Alexander Blair
6d29ee6c52
Merge pull request #6493
...
921dd8dde
Use domain-separated ChaCha20 for in-memory key encryption (Sarang Noether)
2020-08-16 12:39:59 -07:00
Alexander Blair
13549d590e
Merge pull request #6329
...
6bfcd3101
Updates InProofV1, OutProofV1, and ReserveProofV1 to new V2 variants that include all public proof parameters in Schnorr challenges, along with hash function domain separators. Includes new randomized unit tests. (Sarang Noether)
2020-08-16 12:37:43 -07:00
Lee Clagett
4e2377995d
Change ZMQ-JSON txextra to hex and remove unnecessary base fields
2020-08-14 23:01:00 +00:00
Lee Clagett
fe96e66ebe
Fix pruned tx for ZMQ's GetBlocksFast
2020-08-14 19:46:33 +00:00
Sarang Noether
921dd8dde5
Use domain-separated ChaCha20 for in-memory key encryption
2020-08-09 19:11:54 -04:00
Sarang Noether
6bfcd31015
Updates InProofV1, OutProofV1, and ReserveProofV1 to new V2 variants that include all public proof parameters in Schnorr challenges, along with hash function domain separators. Includes new randomized unit tests.
2020-08-09 18:42:15 -04:00
Alexander Blair
c108c5e2f0
Merge pull request #6354
...
67ade8005
Add randomized delay when forwarding txes from i2p/tor -> ipv4/6 (Lee Clagett)
2020-08-09 06:42:49 -07:00
koe
85efc88c1e
Fix overflow issue in epee:misc_utils::rolling_median_t and median(), with unit test
2020-07-23 03:36:05 -05:00
xiphon
76c16822d0
wallet2_api: implement runtime proxy configuration
2020-07-20 13:45:12 +00:00
Alexander Blair
3ba6c7fd30
Merge pull request #6516
...
8656a8c9f
remove double includes (sumogr)
2020-07-19 03:34:28 -07:00
Alexander Blair
a0d179e528
Merge pull request #6512
...
5ef0607da
Update copyright year to 2020 (SomaticFanatic)
2020-07-19 03:32:59 -07:00
luigi1111
35e2520115
Merge pull request #6559
...
15538f7
ByteSlice: Fix persisting ptr to std::moved SSO buffer (Doy-lee)
2020-07-08 17:07:50 -05:00
Doyle
15538f7e3f
ByteSlice: Fix persisting ptr to std::moved SSO buffer
...
The Bug:
1. Construct `byte_slice.portion_` with `epee::span(buffer)` which copies a pointer to the SSO buffer to `byte_slice.portion_`
2. It constructs `byte_slice.storage_` with `std::move(buffer)` (normally this swap pointers, but SSO means a memcpy and clear on the original SSO buffer)
3. `slice.data()` returns a pointer from `slice.portion_` that points to the original SSO cleared buffer, `slice.storage_` has the actual string.
2020-05-20 10:13:58 +10:00
Lee Clagett
67ade80055
Add randomized delay when forwarding txes from i2p/tor -> ipv4/6
2020-05-15 07:57:35 +00:00
Lee Clagett
29e563bb1e
Fixed bugs for take_slice and byte_stream->byte_slice
2020-05-12 01:26:37 -04:00
sumogr
8656a8c9ff
remove double includes
2020-05-11 13:53:17 +00:00
SomaticFanatic
5ef0607da6
Update copyright year to 2020
...
Update copyright year to 2020
2020-05-06 22:36:54 -04:00
Lee Clagett
e5214a2ca2
Adding ZMQ/Pub support for txpool_add and chain_main events
2020-05-04 02:06:35 +00:00
luigi1111
06c81b6527
Merge pull request #6359
...
f9441c5
Fixed string_ref usage bug in epee::from_hex::vector (vtnerd)
2020-04-21 08:38:21 -05:00
Lee Clagett
c26c93019a
Add byte_stream for zero-copy serialization, and add support in ZMQ-JSON.
2020-04-11 04:12:11 +00:00
luigi1111
8185054db7
Merge pull request #6451
...
4ed60b6
Bulletproofs: verification speedup (SarangNoether)
2020-05-02 15:14:41 -05:00
luigi1111
a5cc613a68
Merge pull request #6460
...
f8b1480
unit_tests: fix gcc+ warning (sumogr)
2020-05-01 15:50:19 -05:00
Sumo Gr
f8b1480f95
unit_tests: fix gcc+ warning
2020-04-18 18:04:20 +03:00
Sarang Noether
4ed60b626a
Bulletproofs: verification speedup
2020-04-14 20:31:30 -04:00
luigi1111
d1f3d3376d
Merge pull request #6381
...
e719760
Fix receive order leakage with tx fluffing (vtnerd)
2020-04-04 13:12:31 -05:00
luigi1111
5757d99208
Merge pull request #6361
...
68a6507
Fixed bug in ZMQ JSON-RPC method field (vtnerd)
2020-04-04 13:01:15 -05:00
luigi1111
0150a480fd
Merge pull request #6357
...
42a7a4d
daemon: auto public nodes - cache and prioritize most stable nodes (xiphon)
2020-04-04 12:59:23 -05:00
luigi1111
cfc0f4a7fa
Merge pull request #6351
...
81c5943
Remove temporary std::string creation in some hex->bin calls (vtnerd)
5fcc23a
Move hex->bin conversion to monero copyright files and with less includes (vtnerd)
3387f0e
Reduce template bloat in hex->bin for ZMQ json (vtnerd)
2020-04-04 12:55:02 -05:00
luigi1111
bf70696a85
Merge pull request #6346
...
dbfa4f8
unit_tests: fix missing test names (xiphon)
2020-04-04 12:50:17 -05:00
luigi1111
c4f75fe898
Merge pull request #6339
...
c61abf8
remove empty statements (shopglobal)
2020-04-04 12:47:31 -05:00
luigi1111
292e2d8f28
Merge pull request #6335
...
0078ce7
wipeable_string: split - treat CR, LF and Tabs as separators (xiphon)
2020-04-04 12:42:50 -05:00
Lee Clagett
da99157462
Use byte_slice for sending zmq messages - removes data copy within zmq
2020-04-03 01:56:17 +00:00
luigi1111
096e2135dd
Merge pull request #6214
...
054b4c7
protocol: request txpool contents when synced (moneromooo-monero)
2020-03-31 13:32:55 -05:00
Lee Clagett
f9441c5759
Fixed string_ref usage bug in epee::from_hex::vector
2020-03-30 16:53:34 +00:00
Lee Clagett
0c29e17581
Fix network unit tests after epee changes
2020-03-28 13:30:22 -04:00
Alexander Blair
7d4a93fab3
Merge pull request #6285
...
d0641b42
net: fix incorrect less operator for top/i2p addresses (Aaron Hook)
2020-03-27 12:23:00 -07:00
Lee Clagett
02d887c2e5
Adding Dandelion++ support to public networks:
...
- New flag in NOTIFY_NEW_TRANSACTION to indicate stem mode
- Stem loops detected in tx_pool.cpp
- Embargo timeout for a blackhole attack during stem phase
2020-03-26 15:01:30 +00:00
moneromooo-monero
054b4c7f41
protocol: request txpool contents when synced
...
A newly synced Alice sends a (typically quite small) list of
txids in the local tpxool to a random peer Bob, who then uses
the existing tx relay system to send Alice any tx in his txpool
which is not in the list Alice sent
2020-03-22 16:03:31 +00:00
Aaron Hook
aa93e38862
p2p: remove old debug commands
2020-03-20 22:09:44 -07:00
Alexander Blair
820ab9fdea
Merge pull request #6273
...
0f78b06e
Various improvements to the ZMQ JSON-RPC handling: (Lee Clagett)
2020-03-12 01:13:49 -07:00
Lee Clagett
e719760253
Fix receive order leakage with tx fluffing
2020-03-10 22:30:07 -04:00
Lee Clagett
5fcc23ae0a
Move hex->bin conversion to monero copyright files and with less includes
2020-03-09 05:23:59 +00:00
Lee Clagett
0f78b06e8c
Various improvements to the ZMQ JSON-RPC handling:
...
- Finding handling function in ZMQ JSON-RPC now uses binary search
- Temporary `std::vector`s in JSON output now use `epee::span` to
prevent allocations.
- Binary -> hex in JSON output no longer allocates temporary buffer
- C++ structs -> JSON skips intermediate DOM creation, and instead
write directly to an output stream.
2020-03-05 14:20:56 +00:00
Alexander Blair
944e8a4542
Merge pull request #6220
...
a9bdc6e4
Improved performance for epee serialization: (Lee Clagett)
2020-02-28 19:45:31 -08:00
Alexander Blair
e7997cd62a
Merge pull request #6202
...
02b80513
unit_tests: remove invalid bulletproofs unit test (moneromooo-monero)
2020-02-28 19:33:21 -08:00
xiphon
42a7a4dd32
daemon: auto public nodes - cache and prioritize most stable nodes
2020-02-28 08:06:43 +00:00
xiphon
dbfa4f84ee
unit_tests: fix missing test names
2020-02-18 23:56:21 +00:00
Interchained
c61abf87c0
remove empty statements
...
Cleaning up a little around the code base.
2020-02-17 11:55:15 -05:00
xiphon
0078ce7fac
wipeable_string: split - treat CR, LF and Tabs as separators
2020-02-12 21:16:07 +00:00
moneromooo-monero
dd8c6b1703
wallet: do not split integrated addresses in address book api
2020-01-26 00:03:53 +00:00
Aaron Hook
d0641b42fe
net: fix incorrect less operator for top/i2p addresses
2020-01-18 19:18:56 -08:00
luigi1111
dad4cf121e
Merge pull request #6018
...
dce6f05
rpc: Only show version string if it matches expected pattern (ndorf)
3293780
daemon: Use rpc for 'version' command (ndorf)
2019-12-12 13:36:05 -06:00
moneromooo-monero
02b8051339
unit_tests: remove invalid bulletproofs unit test
...
It was intended to check a case which is actually valid (0 gamma),
but was actually duplicating the bad amount test.
Reported by WhatDo_ on IRC.
2019-12-01 15:40:59 +00:00
Lee Clagett
68a6507c3f
Fixed bug in ZMQ JSON-RPC method field
2019-11-18 12:59:41 +00:00
Nathan Dorfman
dce6f055f9
rpc: Only show version string if it matches expected pattern
2019-11-12 18:19:24 -07:00
Lee Clagett
70c9cd3c9c
Change to Tx diffusion (Dandelion++ fluff) instead of flooding
2019-11-04 09:23:20 +00:00
Lee Clagett
a9bdc6e4c4
Improved performance for epee serialization:
...
- Removed copy of field names in binary deserialization
- Removed copy of array values in binary deserialization
- Removed copy of string values in json deserialization
- Removed unhelpful allocation in json string value parsing
- Removed copy of blob data on binary and json serialization
2019-11-04 01:46:41 +00:00
Lee Clagett
5d7ae2d279
Adding support for hidden (anonymity) txpool
2019-11-02 20:36:03 +00:00
moneromooo-monero
1554a7768b
unit_tests: fix use after free
2019-10-30 18:40:20 +00:00
luigi1111
bb2bcf3521
Merge pull request #5972
...
9447e72
cryptonote: add function to get weight from a pruned tx (moneromooo-monero)
2019-10-22 10:52:14 -05:00
luigi1111
84ce43a239
Merge pull request #5966
...
be82c40
Support median block size > 4 GB (moneromooo-monero)
2019-10-22 10:08:32 -05:00
moneromooo-monero
be82c40703
Support median block size > 4 GB
...
add a 128/64 division routine so we can use a > 32 bit median block
size in calculations
2019-10-21 10:41:07 +00:00
moneromooo-monero
c65a221549
unit_tests: fix build after rename
2019-10-15 13:15:19 +00:00
xiphon
d4d2b5c79a
p2p+rpc: don't skip p2p or rpc port bind failure by default
2019-10-13 13:27:46 +00:00
moneromooo-monero
9447e7276d
cryptonote: add function to get weight from a pruned tx
...
The weight of the prunable data is deterministic from the
unpruned data, so it can be determined from a pruned tx
2019-10-11 12:08:36 +00:00
moneromooo-monero
77afe91db6
unit_tests: fix build with boost 1.69
2019-10-11 01:16:03 +00:00
luigi1111
bf525793c7
Merge pull request #5915
...
8330e77
monerod can now sync from pruned blocks (moneromooo-monero)
2019-10-08 15:55:03 -05:00