aboutsummaryrefslogtreecommitdiff
path: root/src/cryptonote_core/blockchain.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* | fix a few leaks by throwing objects, not newed pointers to objectsmoneromooo-monero2017-12-181-1/+1
|/
* Merge pull request #2878Riccardo Spagni2017-12-161-5/+6
|\ | | | | | | | | abebe392 rpc: add offline state in info rpc (moneromooo-monero) 7696e849 core: make --offline also disable DNS lookups (moneromooo-monero)
| * core: make --offline also disable DNS lookupsmoneromooo-monero2017-11-301-5/+6
| |
* | add bulletproofs from v7 on testnetmoneromooo-monero2017-12-081-9/+26
|/
* remove "using namespace std" from headersmoneromooo-monero2017-11-141-0/+2
| | | | | | | It's nasty, and actually breaks on Solaris, where if.h fails to build due to: struct map *if_memmap;
* Merge pull request #2615Riccardo Spagni2017-11-141-4/+4
|\ | | | | | | 10013e94 Protect node privacy by proper filtering in restricted-mode RPC answers (binaryFate)
| * Protect node privacy by proper filtering in restricted-mode RPC answersbinaryFate2017-11-081-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch allows to filter out sensitive information for queries that rely on the pool state, when running in restricted mode. This filtering is only applied to data sent back to RPC queries. Results of inline commands typed locally in the daemon are not affected. In practice, when running with `--restricted-rpc`: * get_transaction_pool will list relayed transactions with the fields "last relayed time" and "received time" set to zero. * get_transaction_pool will not list transaction that have do_not_relay set to true, and will not list key images that are used only for such transactions * get_transaction_pool_hashes.bin will not list such transaction * get_transaction_pool_stats will not count such transactions in any of the aggregated values that are computed The implementation does not make filtering the default, so developers should be mindful of this if they add new RPC functionality. Fixes #2590.
* | track double spending in the txpoolmoneromooo-monero2017-11-061-6/+6
|/ | | | | | | | | | | | | | Transactions in the txpool are marked when another transaction is seen double spending one or more of its inputs. This is then exposed wherever appropriate. Note that being marked with this "double spend seen" flag does NOT mean this transaction IS a double spend and will never be mined: it just means that the network has seen at least another transaction spending at least one of the same inputs, so care should be taken to wait for a few confirmations before acting upon that transaction (ie, mostly of use for merchants wanting to accept unconfirmed transactions).
* blockchain: do not lock the blockchain lock for simple DB gettersmoneromooo-monero2017-10-301-7/+28
| | | | | | | It is safe in those cases, though might return slightly out of date information if another thread is busy modifying the blockchain, but it avoids potentially lengthy delays just to get things like the current blockchain height.
* Merge pull request #2656Riccardo Spagni2017-10-151-3/+3
|\ | | | | | | | | 3492de01 fix lightwallet and subaddresses conflict (Jaquee) 329f149e remove reference to cryptonote::null_hash (Jaquee)
| * remove reference to cryptonote::null_hashJaquee2017-10-151-3/+3
| |
* | Merge pull request #2640Riccardo Spagni2017-10-151-2/+12
|\ \ | |/ |/| | | | | 22b51e06 db_lmdb: include chain height when failing to find an output key (moneromooo-monero) 5db433b3 blockchain: avoid exceptions in output verification (moneromooo-monero)
| * blockchain: avoid exceptions in output verificationmoneromooo-monero2017-10-121-2/+12
| | | | | | | | This can happen if we get a bad tx, so let's not spam the log.
* | Merge pull request #2552Riccardo Spagni2017-10-151-9/+18
|\ \ | | | | | | | | | 69ce33f2 core: fix failure to sync when a tx is already in the pool (moneromooo-monero)
| * | core: fix failure to sync when a tx is already in the poolmoneromooo-monero2017-09-291-9/+18
| | |
* | | Merge pull request #2469Riccardo Spagni2017-10-151-9/+119
|\ \ \ | |_|/ |/| | | | | 7adceee6 precomputed block hashes are now in blocks of N (currently 256) (moneromooo-monero)
| * | precomputed block hashes are now in blocks of N (currently 256)moneromooo-monero2017-09-181-9/+119
| | | | | | | | | | | | This shaves a lot of space off binaries
* | | Merge pull request #2537Riccardo Spagni2017-10-061-2/+2
|\ \ \ | | | | | | | | | | | | 269a2a01 blockchain: fix off by one getting blocks (moneromooo-monero)
| * | | blockchain: fix off by one getting blocksmoneromooo-monero2017-09-271-2/+2
| | |/ | |/|
* / | core: remove out sorting from v7 rulesmoneromooo-monero2017-09-271-20/+0
|/ / | | | | | | | | | | | | and restore random shuffle of outputs This turned out to have a flaw (sort order depends on output index), and this doesn't really bring much anyway
* | move checkpoints in a separate librarymoneromooo-monero2017-09-251-1/+0
| |
* | Merge pull request #2457Riccardo Spagni2017-09-251-1/+10
|\ \ | | | | | | | | | d2d8a41c Use actual batch size for resize estimates (Howard Chu)
| * | Use actual batch size for resize estimatesHoward Chu2017-09-171-1/+10
| | | | | | | | | | | | | | | | | | | | | And optimize import startup: Remember start_height position during initial count_blocks pass to avoid having to reread entire file again to arrive at start_height
* | | Merge pull request #2440Riccardo Spagni2017-09-251-0/+39
|\ \ \ | | | | | | | | | | | | | | | | | | | | 6137a0b9 blockchain: reject unsorted ins and outs from v7 (moneromooo-monero) 16afab90 core: sort ins and outs key key image and public key, respectively (moneromooo-monero) 0c36b9f9 common: add apply_permutation file and function (moneromooo-monero)
| * | | blockchain: reject unsorted ins and outs from v7moneromooo-monero2017-09-181-0/+39
| | | | | | | | | | | | | | | | This ensures no information is leaked by the ordering
* | | | blockchain: fix crash checking pre-validated txidsmoneromooo-monero2017-09-201-2/+2
| |_|/ |/| |
* | | Merge pull request #2446Riccardo Spagni2017-09-181-56/+16
|\ \ \ | | | | | | | | | | | | | | | | 6d0ca7d1 Tweak concurrency limits (Howard Chu) 510d0d47 Use a threadpool (Howard Chu)
| * | | Use a threadpoolHoward Chu2017-09-141-56/+16
| | |/ | |/| | | | | | | Instead of constantly creating and destroying threads
* | | Merge pull request #2044Riccardo Spagni2017-09-181-74/+129
|\ \ \ | |/ / |/| | | | | | | | | | | | | | 0299cb77 Fix various oversights/bugs in ZMQ RPC server code (Thomas Winget) 77986023 json serialization for rpc-relevant monero types (Thomas Winget) 5c1e08fe Refactor some things into more composable (smaller) functions (Thomas Winget) 9ac2ad07 DRY refactoring (Thomas Winget)
| * | json serialization for rpc-relevant monero typesThomas Winget2017-09-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Structured {de-,}serialization methods for (many new) types which are used for requests or responses in the RPC. New types include RPC requests and responses, and structs which compose types within those. # Conflicts: # src/cryptonote_core/blockchain.cpp
| * | Refactor some things into more composable (smaller) functionsThomas Winget2017-09-051-73/+123
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit refactors some of the rpc-related functions in the Blockchain class to be more composable. This change was made in order to make implementing the new zmq rpc easier without trampling on the old rpc. New functions: Blockchain::get_num_mature_outputs Blockchain::get_random_outputs Blockchain::get_output_key Blockchain::get_output_key_mask_unlocked Blockchain::find_blockchain_supplement (overload) functions which previously had this functionality inline now call these functions as necessary.
| * | DRY refactoringThomas Winget2017-08-311-1/+6
| | |
* | | update checkpoint hashesRiccardo Spagni2017-09-061-1/+1
| |/ |/|
* | Fix blockchain_import wedge on exception in cleanup_handle_incoming_blocksmoneromooo-monero2017-08-291-3/+14
|/
* Merge pull request #2347Riccardo Spagni2017-08-271-2/+7
|\ | | | | | | | | 5807529e blockchain: cap memory size of retrieved blocks (moneromooo-monero) c1b10381 rpc: decrease memory usage a bit in getblocks.bin (moneromooo-monero)
| * blockchain: cap memory size of retrieved blocksmoneromooo-monero2017-08-261-2/+7
| | | | | | | | | | It helps keep memory usage down when a wallet refreshes through a string of large blocks
* | Merge pull request #2314Riccardo Spagni2017-08-261-1/+18
|\ \ | |/ |/| | | | | c22d22e2 Cleanup test impact of adding safesyncmode() method (Howard Chu) 9a859844 Toggle SAFE syncmode on and off automatically (Howard Chu)
| * Toggle SAFE syncmode on and off automaticallyHoward Chu2017-08-201-1/+18
| | | | | | | | | | | | | | | | | | If monerod is started with default sync mode, set it to SAFE after synchronization completes. Set it back to FAST if synchronization restarts (e.g. because another peer has a longer blockchain). If monerod is started with an explicit sync mode, none of this automation takes effect.
* | core: add mainnet v6 fork height at 1400000moneromooo-monero2017-08-181-0/+3
|/
* protocol: pass blockchain cumulative difficulty when syncingmoneromooo-monero2017-08-151-0/+1
| | | | Not used yet.
* Merge pull request #2250Riccardo Spagni2017-08-151-1/+3
|\ | | | | | | f4f7eeba blockchain: log more info when we reject an orphan (moneromooo-monero)
| * blockchain: log more info when we reject an orphanmoneromooo-monero2017-08-041-1/+3
| | | | | | | | We want to know what happened when a block is wrongly rejected
* | Merge pull request #2246Riccardo Spagni2017-08-151-11/+3
|\ \ | | | | | | | | | d732c73e blockchain: remove a few unused variables (moneromooo-monero)
| * | blockchain: remove a few unused variablesmoneromooo-monero2017-08-031-11/+3
| |/
* | Merge pull request #2237Riccardo Spagni2017-08-151-8/+8
|\ \ | | | | | | | | | | | | | | | 5d4ef719 core: speed up output index unique set calculation (moneromooo-monero) 19d7f568 perf_timer: allow profiling more granular than millisecond (moneromooo-monero) bda8c598 epee: add nanosecond timer and pause/restart profiling macros (moneromooo-monero)
| * | core: speed up output index unique set calculationmoneromooo-monero2017-08-011-8/+8
| |/ | | | | | | | | | | | | | | | | A sort+uniq step was done for every tx in a 200 block chunk, causing a lot of repeated scanning as the size of the offset map got larger with every added tx. We now do the step only once at the end of the loop. Doing it this way potentially uses more memory, but testing shows that it's currently only about 2% more.
* | change mixin to ring size in user visible placesmoneromooo-monero2017-08-071-6/+6
| |
* | Merge pull request #2225Riccardo Spagni2017-08-071-0/+9
|\ \ | | | | | | | | | 5d91b26c blockchain: skip checking tx semantics in embedded block hash range (moneromooo-monero)
| * | blockchain: skip checking tx semantics in embedded block hash rangemoneromooo-monero2017-07-301-0/+9
| |/ | | | | | | | | If the txes are bad, this'll be picked up by the block hash mismatch since the tx merkle root is part of the block hash.
* | Merge pull request #2243Riccardo Spagni2017-08-071-0/+2
|\ \ | | | | | | | | | 4d873046 blockchain: add testnet v6 fork height at 971400 (moneromooo-monero)