Commit graph

163 commits

Author SHA1 Message Date
moneromooo-monero
0c5dd3161b
cryptonote: add a set_null for transaction_prefix
Since it's all inline, I suspect the compiler will merge the
duplicate stores anyway.
2018-11-30 15:11:43 +00:00
Riccardo Spagni
59e8a4c306
Merge pull request #4753
157054b8 hardfork: initialize current_fork_index in ctor (moneromooo-monero)
2362baf7 network_throttle: initialize m_last_sample_time in ctor (moneromooo-monero)
d9400f69 serializtion: add missing mainnet and stagenet fields for 0mq (moneromooo-monero)
cbe0122b wallet2: initialize amount to 0 in tx_scan_info_t ctor (moneromooo-monero)
2018-11-14 21:33:02 +02:00
Riccardo Spagni
148ac1a898
Merge pull request #4744
b3e8677c cryptonote: use logging functions for errors, not std::cout (moneromooo-monero)
2018-11-06 21:33:52 +02:00
Dusan Klinec
29ffb6bba8
device/trezor: trezor support added 2018-11-02 21:36:39 +01:00
moneromooo-monero
157054b840
hardfork: initialize current_fork_index in ctor
Also order init list to match actual runtime init order

Coverity 136605
2018-10-29 16:23:58 +00:00
moneromooo-monero
b3e8677c70
cryptonote: use logging functions for errors, not std::cout 2018-10-27 18:07:55 +00:00
Riccardo Spagni
20d3605a54
Merge pull request #4700
3bb4b0d4 miner: fix build with boost 1.69 (moneromooo-monero)
2018-10-26 22:41:21 +02:00
Riccardo Spagni
fc06c5daf8
Merge pull request #4617
3ffbec15 rpc: init m_rpc_version in Message ctor (moneromooo-monero)
bfa2dce1 rpc: remove unused ctors (moneromooo-monero)
7cc39845 account: init creation timestamp to 0 (moneromooo-monero)
32123789 wallet2: initialize some scalar fields in ctor where appropriate (moneromooo-monero)
4eca42b2 blockchain_db: initialize m_hardfork in ctor just in case (moneromooo-monero)
2018-10-26 22:39:00 +02:00
Riccardo Spagni
1c91963dcd
Merge pull request #4308
9907ea06 cryptonote: sort tx_extra fields (moneromooo-monero)
2018-10-26 22:18:28 +02:00
moneromooo-monero
3bb4b0d41f
miner: fix build with boost 1.69 2018-10-22 22:17:15 +00:00
Riccardo Spagni
a145ae52b6
Merge pull request #4523
6ca00b6d miner: really reset flags/precision on std::cout (moneromooo-monero)
2018-10-20 20:40:36 +02:00
moneromooo-monero
7cc39845be
account: init creation timestamp to 0
Never actually used uninitialized

Coverity 136615
2018-10-16 11:58:50 +00:00
Riccardo Spagni
c531df734f
Merge pull request #4389
6844ae1b tx_pool: avoid parsing a whole tx if only the prefix is needed (moneromooo-monero)
2018-10-15 13:36:15 +02:00
moneromooo-monero
6ca00b6d75
miner: really reset flags/precision on std::cout 2018-10-08 12:12:36 +00:00
moneromooo-monero
6844ae1b8d
tx_pool: avoid parsing a whole tx if only the prefix is needed 2018-10-08 10:18:01 +00:00
moneromooo-monero
9907ea0694
cryptonote: sort tx_extra fields
This removes some small amount of fingerprinting entropy.
There is no consensus rule to require this since this field
is technically free form, and a transaction is free to have
custom data in it.
2018-10-07 11:13:22 +00:00
Riccardo Spagni
effcbf2060
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:20:38 +02:00
Riccardo Spagni
b4a9ebad6c
Merge pull request #4299
f9b22a7b hw_device: support for multiple devices added [for review] (Dusan Klinec)
2018-09-18 17:29:26 +02:00
Riccardo Spagni
9c40bc62fc
Merge pull request #3430
42397359 Fixup 32bit arm build (TheCharlatan)
a06d2581 Fix Windows build (TheCharlatan)
ecaf5b3f Add libsodium to the packages, the arm build was complaining about it. (TheCharlatan)
cbbf4d24 Adapt translations to upstream changes (TheCharlatan)
db571546 Updated pcsc url (TheCharlatan)
f0ba19fd Add lrelease to the depends (TheCharlatan)
cfb30462 Add Miniupnp submodule (TheCharlatan)
5f7da005 Unbound is now a submodule. Adapt depends for this. (TheCharlatan)
d6b9bdd3 Update readmes to reflect the usage of depends (TheCharlatan)
56b6e41e Add support for apple and arm building (TheCharlatan)
29311fd1 Disable stack unwinding for mingw32 depends build. (TheCharlatan)
8db3d573 Modify depends for monero's dependencies (TheCharlatan)
0806a23a Initial depends addition (TheCharlatan)
2018-09-18 16:33:21 +02:00
Dusan Klinec
f9b22a7b01
hw_device: support for multiple devices added [for review]
- device name is a new wallet property
- full device name is now a bit more structured so we can address particular device vendor + device path. Example: 'Ledger', 'Trezor:udp', 'Trezor:udp:127.0.0.1:21324', 'Trezor:bridge:usb01'. The part before ':' identifies HW device implementation, the optional part after ':' is device path to look for.
- new --hw-device parameter added to the wallet, can name the hardware device
- device reconnect added
2018-09-14 16:02:00 +02:00
Riccardo Spagni
7addabce8f
Merge pull request #4330
93e7627d cryptonote_format_utils: do not early out on invalid tx pubkeys (moneromooo-monero)
2018-09-14 13:04:40 +02:00
moneromooo-monero
044dff5a30
bulletproofs: scale points by 8 to ensure subgroup validity 2018-09-11 13:38:31 +00:00
moneromooo-monero
d1591853bf
cryptonote_basic: check output type before using it
Reported by QuarksLab.
2018-09-11 13:38:15 +00:00
moneromooo-monero
5ffb2ff9b7
v8: per byte fee, pad bulletproofs, fixed 11 ring size 2018-09-11 13:38:07 +00:00
moneromooo-monero
2a8fcb421b
Bulletproof aggregated verification and tests
Also constrains bulletproofs to simple rct, for simplicity
2018-09-11 13:37:37 +00:00
TheCharlatan
56b6e41ea7 Add support for apple and arm building
Add pcsc-lite to linux builds
Fixup windows icu4c linking with depends, the static libraries have an 's' appended to them
Compiling depends arm-linux-gnueabihf will allow you to compile armv6zk monero binaries
2018-09-10 22:05:36 +02:00
moneromooo-monero
93e7627d5a
cryptonote_format_utils: do not early out on invalid tx pubkeys
Another such pubkey might be valid
2018-09-02 23:00:44 +00:00
moneromooo-monero
ab74dc277a
crypto: make secret_key automatically mlock 2018-08-16 11:57:49 +00:00
moneromooo-monero
e9ffa91257
store secret keys encrypted where possible
The secret spend key is kept encrypted in memory, and
decrypted on the fly when needed.

Both spend and view secret keys are kept encrypted in a JSON
field in the keys file. This avoids leaving the keys in
memory due to being manipulated by the JSON I/O API.
2018-08-16 11:57:43 +00:00
luigi1111
3235abc184
Merge pull request #4030
0c41488 miner: show id and height when a block is found (stoffu)
2018-07-19 13:53:36 -05:00
luigi1111
025187e6c9
Merge pull request #3854
149da42 db_lmdb: enable batch transactions by default (stoffu)
34cb6b4 add --regtest and --fixed-difficulty for regression testing (vicsn)
9e1403e update get_info RPC and bump RPC version (vicsn)
207b66e first new functional tests (vicsn)
2018-07-19 13:35:25 -05:00
victorsintnicolaas
34cb6b4b70 add --regtest and --fixed-difficulty for regression testing
on_generateblocks RPC call combines functionality from the on_getblocktemplate and on_submitblock RPC calls to allow rapid block creation. Difficulty is set permanently to 1 for regtest.
Makes use of FAKECHAIN network type, but takes hard fork heights from mainchain
Default reserve_size in generate_blocks RPC call is now 1. If it is 0, the following error occurs 'Failed to calculate offset for'.
Queries hard fork heights info of other network types
2018-06-29 10:06:11 +02:00
luigi1111
3ad4ecd4ff
Merge pull request #3982
08b85a8 cryptonote_config: add get_config to refactor x = testnet ? config::testnet::X : stagenet ? config::stagenet::X : config::X (stoffu)
0cf80ba net_node: resolve host for node addresses given via command line flags (stoffu)
2018-06-27 15:38:23 -05:00
moneromooo-monero
ed2c81ed95
replace std::list with std::vector on some hot paths
also use reserve where appropriate
2018-06-26 22:14:21 +01:00
luigi1111
36aeaa7545
Merge pull request #3757
6f9260e handle optional miner params better (cryptochangements34)
2018-06-20 14:09:42 -05:00
stoffu
0c4148845b
miner: show id and height when a block is found 2018-06-20 12:08:40 +09:00
luigi1111
9a3bd88b9f
Merge pull request #3851
a87980f fix build with GCC 8.1.0 (moneromooo-monero)
2018-06-19 12:51:13 -05:00
luigi1111
42e7f31613
Merge pull request #3725
9cc0d42 connection_context: remove state_ prefix from state names (moneromooo-monero)
d9d002c daemon: print peer state in sync_info (moneromooo-monero)
2018-06-16 14:01:12 -05:00
stoffu
08b85a8e00
cryptonote_config: add get_config to refactor x = testnet ? config::testnet::X : stagenet ? config::stagenet::X : config::X 2018-06-11 20:17:02 +09:00
stoffu
98cf62cc45
hardfork: fix get_next_version() 2018-05-30 09:49:57 +09:00
stoffu
a79fc219b7
hardfork: fix get_earliest_ideal_height_for_version() to support non-existent versions 2018-05-30 09:49:52 +09:00
moneromooo-monero
a87980f6c2
fix build with GCC 8.1.0 2018-05-26 14:54:10 +01:00
moneromooo-monero
b9389e582e
db_lmdb: save pruned and prunable tx data separately
This bumps DB version to 2, migration code will run for v1 DBs
2018-05-23 22:48:12 +01:00
moneromooo-monero
6f859e4328
cryptonote: make sure outPk setup always happens 2018-05-07 19:21:52 +01:00
cryptochangements34
6f9260e38e handle optional miner params better 2018-05-06 12:28:57 -04:00
moneromooo-monero
9cc0d4220f
connection_context: remove "state_" prefix from state names
It's redundant and makes it easier to print them in columns
2018-04-28 19:56:28 +01:00
Dimitris Apostolou
57c0b1ed9f Fix typos in various files 2018-03-15 18:25:38 +02:00
stoffu
8705beaf51
keypair::generate: always require hw::device to avoid possible mistake 2018-03-14 21:00:16 +09:00
stoffu
27a196b126
device: untangle cyclic depenency
When #3303 was merged, a cyclic dependency chain was generated:

    libdevice <- libcncrypto <- libringct <- libdevice

This was because libdevice needs access to a set of basic crypto operations
implemented in libringct such as scalarmultBase(), while libringct also needs
access to abstracted crypto operations implemented in libdevice such as
ecdhEncode(). To untangle this cyclic dependency chain, this patch splits libringct
into libringct_basic and libringct, where the basic crypto ops previously in
libringct are moved into libringct_basic. The cyclic dependency is now resolved
thanks to this separation:

    libcncrypto <- libringct_basic <- libdevice <- libcryptonote_basic <- libringct

This eliminates the need for crypto_device.cpp and rctOps_device.cpp.

Also, many abstracted interfaces of hw::device such as encrypt_payment_id() and
get_subaddress_secret_key() were previously implemented in libcryptonote_basic
(cryptonote_format_utils.cpp) and were then called from hw::core::device_default,
which is odd because libdevice is supposed to be independent of libcryptonote_basic.
Therefore, those functions were moved to device_default.cpp.
2018-03-14 21:00:15 +09:00
stoffu
c9b38b4765
device: made function prototypes consistent with pre-#3303 codebase 2018-03-14 21:00:06 +09:00