aboutsummaryrefslogtreecommitdiff
path: root/src/daemon/rpc_command_executor.cpp (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-06-27Merge pull request #8703luigi11111-3/+10
c90c1c3 Show IPv6 addresses in connection list (Guillaume Le Vaillant)
2023-04-14Show IPv6 addresses in connection listGuillaume Le Vaillant1-3/+10
2023-01-16Copyright: Update to 2023mj-xmr1-1/+1
Co-authored-by: plowsof <plowsof@protonmail.com> extra files
2022-10-28Merge pull request #8527luigi11111-1/+1
e988530 Remove redundant check (SerHack)
2022-08-22Remove redundant checkSerHack1-1/+1
2022-05-23epee: update 'http_server_handlers_map2.h' macros to use fully qualified namesJeffrey Ryan1-1/+1
quick patch which fixes the issue where if you use some macros from `http_server_handlers_map2.h` you have to be in the `epee` namespace or it doesn't compile. Now can remove `using namespace epee;` from header file `core_rpc_server.h`, which caused a couple of name qualifying mistakes
2022-03-04Copyright: Update to 2022mj-xmr1-1/+1
2021-03-29Merge pull request #7326luigi11111-1/+3
cf266d6 bootstrap_daemon: proxy configuration support (xiphon)
2021-02-09Remove unused variables in monero codebaseKevin Barbour1-1/+0
There are quite a few variables in the code that are no longer (or perhaps never were) in use. These were discovered by enabling compiler warnings for unused variables and cleaning them up. In most cases where the unused variables were the result of a function call the call was left but the variable assignment removed, unless it was obvious that it was a simple getter with no side effects.
2021-01-21bootstrap_daemon: proxy configuration supportxiphon1-1/+3
2020-12-31Header row for peer list in sync_infoDenis Goddard1-0/+1
2020-12-22restrict public node checks a littlemoneromooo-monero1-0/+4
do not include blocked hosts in peer lists or public node lists by default, warn about no https on clearnet and about untrusted peers likely being spies
2020-08-16Merge pull request #6703Alexander Blair1-1/+3
8baa7bb23 daemon: don't print "(pruned)" for coinbase txes (moneromooo-monero)
2020-08-16Merge pull request #6689Alexander Blair1-2/+4
afd002c31 daemon: print sampling time in print_net_stats (moneromooo-monero) ec7bba079 util: fix kilo prefix typo (K instead of k) (moneromooo-monero)
2020-07-24daemon: don't print "(pruned)" for coinbase txesmoneromooo-monero1-1/+3
Pruned coinbase txes are the same as unpruned ones, so the prunable data is empty
2020-07-19Merge pull request #6512Alexander Blair1-1/+1
5ef0607da Update copyright year to 2020 (SomaticFanatic)
2020-06-25daemon: print sampling time in print_net_statsmoneromooo-monero1-2/+4
2020-05-24daemon: remove time based "update needed" status stringmoneromooo-monero1-2/+1
2020-05-06Update copyright year to 2020SomaticFanatic1-1/+1
Update copyright year to 2020
2020-04-21Merge pull request #6408luigi11111-2/+2
5ef7138 daemon: fix print_net_stats RPC calls (moneromooo-monero)
2020-04-04Merge pull request #6353luigi11111-3/+7
6810150 daemon: if no banned IPs print something (sumogr)
2020-03-29daemon: fix print_net_stats RPC callsmoneromooo-monero1-2/+2
2020-02-28Merge pull request #6225Alexander Blair1-3/+3
987c3139 print_coinbase_tx_sum now supports 128 bits sums (moneromooo-monero)
2020-02-28Merge pull request #6211Alexander Blair1-1/+2
5985c5af rpc: add bad-blocks to flush_cache RPC (moneromooo-monero)
2020-02-24daemon: if no banned IPs print somethingsumogr1-3/+7
2020-02-06Merge pull request #6096Alexander Blair1-3/+32
a633f85d daemon: allow printing N blocks from the end of the chain (moneromooo-monero)
2020-02-06Merge pull request #6095Alexander Blair1-0/+24
7ba31191 daemon: add +meta print_tx parameter (moneromooo-monero)
2020-02-06Merge pull request #6053Alexander Blair1-2/+2
deb350b7 always print peer IDs in the same format (moneromooo-monero)
2019-12-12Merge pull request #6054luigi11111-1/+1
017f816 daemon: handle printing higher hash rates (moneromooo-monero)
2019-12-12print_coinbase_tx_sum now supports 128 bits sumsmoneromooo-monero1-3/+3
The tail emission will bring the total above 64 bits
2019-12-02rpc: add bad-blocks to flush_cache RPCmoneromooo-monero1-1/+2
Flushes m_invalid_blocks in Blockchain.
2019-11-12rpc: Only show version string if it matches expected patternNathan Dorfman1-1/+2
2019-11-12daemon: Use rpc for "version" commandNathan Dorfman1-0/+35
2019-11-04daemon: allow printing N blocks from the end of the chainmoneromooo-monero1-3/+32
It's a very common usage (for my anyway) and avoids the need to get the current height, paste, subtract one, etc
2019-11-04daemon: add +meta print_tx parametermoneromooo-monero1-0/+24
prints size, weight and (if mined) height
2019-10-29daemon: handle printing higher hash ratesmoneromooo-monero1-1/+1
2019-10-29always print peer IDs in the same formatmoneromooo-monero1-2/+2
2019-10-25rpc: add a flush_cache RPCmoneromooo-monero1-0/+28
This allows flushing internal caches (for now, the bad tx cache, which will allow debugging a stuck monerod after it has failed to verify a transaction in a block, since it would otherwise not try again, making subsequent log changes pointless)
2019-10-25Merge pull request #5357luigi11111-1/+51
b3a9a4d add a quick early out to get_blocks.bin when up to date (moneromooo-monero) 2899379 daemon, wallet: new pay for RPC use system (moneromooo-monero) ffa4602 simplewallet: add public_nodes command (moneromooo-monero)
2019-10-25daemon, wallet: new pay for RPC use systemmoneromooo-monero1-1/+51
Daemons intended for public use can be set up to require payment in the form of hashes in exchange for RPC service. This enables public daemons to receive payment for their work over a large number of calls. This system behaves similarly to a pool, so payment takes the form of valid blocks every so often, yielding a large one off payment, rather than constant micropayments. This system can also be used by third parties as a "paywall" layer, where users of a service can pay for use by mining Monero to the service provider's address. An example of this for web site access is Primo, a Monero mining based website "paywall": https://github.com/selene-kovri/primo This has some advantages: - incentive to run a node providing RPC services, thereby promoting the availability of third party nodes for those who can't run their own - incentive to run your own node instead of using a third party's, thereby promoting decentralization - decentralized: payment is done between a client and server, with no third party needed - private: since the system is "pay as you go", you don't need to identify yourself to claim a long lived balance - no payment occurs on the blockchain, so there is no extra transactional load - one may mine with a beefy server, and use those credits from a phone, by reusing the client ID (at the cost of some privacy) - no barrier to entry: anyone may run a RPC node, and your expected revenue depends on how much work you do - Sybil resistant: if you run 1000 idle RPC nodes, you don't magically get more revenue - no large credit balance maintained on servers, so they have no incentive to exit scam - you can use any/many node(s), since there's little cost in switching servers - market based prices: competition between servers to lower costs - incentive for a distributed third party node system: if some public nodes are overused/slow, traffic can move to others - increases network security - helps counteract mining pools' share of the network hash rate - zero incentive for a payer to "double spend" since a reorg does not give any money back to the miner And some disadvantages: - low power clients will have difficulty mining (but one can optionally mine in advance and/or with a faster machine) - payment is "random", so a server might go a long time without a block before getting one - a public node's overall expected payment may be small Public nodes are expected to compete to find a suitable level for cost of service. The daemon can be set up this way to require payment for RPC services: monerod --rpc-payment-address 4xxxxxx \ --rpc-payment-credits 250 --rpc-payment-difficulty 1000 These values are an example only. The --rpc-payment-difficulty switch selects how hard each "share" should be, similar to a mining pool. The higher the difficulty, the fewer shares a client will find. The --rpc-payment-credits switch selects how many credits are awarded for each share a client finds. Considering both options, clients will be awarded credits/difficulty credits for every hash they calculate. For example, in the command line above, 0.25 credits per hash. A client mining at 100 H/s will therefore get an average of 25 credits per second. For reference, in the current implementation, a credit is enough to sync 20 blocks, so a 100 H/s client that's just starting to use Monero and uses this daemon will be able to sync 500 blocks per second. The wallet can be set to automatically mine if connected to a daemon which requires payment for RPC usage. It will try to keep a balance of 50000 credits, stopping mining when it's at this level, and starting again as credits are spent. With the example above, a new client will mine this much credits in about half an hour, and this target is enough to sync 500000 blocks (currently about a third of the monero blockchain). There are three new settings in the wallet: - credits-target: this is the amount of credits a wallet will try to reach before stopping mining. The default of 0 means 50000 credits. - auto-mine-for-rpc-payment-threshold: this controls the minimum credit rate which the wallet considers worth mining for. If the daemon credits less than this ratio, the wallet will consider mining to be not worth it. In the example above, the rate is 0.25 - persistent-rpc-client-id: if set, this allows the wallet to reuse a client id across runs. This means a public node can tell a wallet that's connecting is the same as one that connected previously, but allows a wallet to keep their credit balance from one run to the other. Since the wallet only mines to keep a small credit balance, this is not normally worth doing. However, someone may want to mine on a fast server, and use that credit balance on a low power device such as a phone. If left unset, a new client ID is generated at each wallet start, for privacy reasons. To mine and use a credit balance on two different devices, you can use the --rpc-client-secret-key switch. A wallet's client secret key can be found using the new rpc_payments command in the wallet. Note: anyone knowing your RPC client secret key is able to use your credit balance. The wallet has a few new commands too: - start_mining_for_rpc: start mining to acquire more credits, regardless of the auto mining settings - stop_mining_for_rpc: stop mining to acquire more credits - rpc_payments: display information about current credits with the currently selected daemon The node has an extra command: - rpc_payments: display information about clients and their balances The node will forget about any balance for clients which have been inactive for 6 months. Balances carry over on node restart.
2019-10-24daemon: print difficulty in decimal, as it used to bemoneromooo-monero1-8/+8
It got switched to hexadecimal when we went to 128 bit values
2019-10-24Merge pull request #6001luigi11111-1/+2
705edd8 daemon: fix coinbase txes always being seen as pruned (moneromooo-monero)
2019-10-24Merge pull request #6000luigi11111-1/+2
641c9cf daemon: add miner tx hash in print_block output (moneromooo-monero)
2019-10-18daemon: fix coinbase txes always being seen as prunedmoneromooo-monero1-1/+2
2019-10-18daemon: add miner tx hash in print_block outputmoneromooo-monero1-1/+2
2019-10-07Print cdifficulty and don't serialize miner tx hash twiceDoyle1-0/+1
2019-09-14Merge pull request #5868luigi11111-1/+1
1f1fff2 daemon: print mining algorithm in mining_status even when not mining (moneromooo-monero)
2019-09-08Merge pull request #5849luigi11111-4/+9
b51f4cd daemon: add pruned and publicrpc flags to print_pl (moneromooo-monero)
2019-09-08Merge pull request #5840luigi11111-0/+36
063eebb daemon: implement 'set_bootstrap_daemon' command (xiphon)
2019-08-28daemon: print mining algorithm in mining_status even when not miningmoneromooo-monero1-1/+1
2019-08-23daemon: add pruned and publicrpc flags to print_plmoneromooo-monero1-4/+9
2019-08-23daemon: implement 'set_bootstrap_daemon' commandxiphon1-0/+36
2019-08-20daemon: fix merge error removing the "never seen before" timestamp checkmoneromooo-monero1-1/+1
2019-08-19daemon: fix print_pl only printing public zone peersmoneromooo-monero1-7/+6
2019-08-15Merge pull request #5659luigi11111-17/+40
6bb2797 daemon: print 128bit diff properly (stoffu)
2019-08-14Merge pull request #5525luigi11111-4/+62
0605406 daemon: sort alt chains by height (moneromooo-monero) 4228ee0 daemon: add optional arguments to alt_chain_info (moneromooo-monero) 880ebfd daemon: add more chain specific info in alt_chain_info (moneromooo-monero)
2019-07-31Add IPv6 supportThomas Winget1-1/+1
new cli options (RPC ones also apply to wallet): --p2p-bind-ipv6-address (default = "::") --p2p-bind-port-ipv6 (default same as ipv4 port for given nettype) --rpc-bind-ipv6-address (default = "::1") --p2p-use-ipv6 (default false) --rpc-use-ipv6 (default false) --p2p-require-ipv4 (default true, if ipv4 bind fails and this is true, will not continue even if ipv6 bind successful) --rpc-require-ipv4 (default true, description as above) ipv6 addresses are to be specified as "[xx:xx:xx::xx:xx]:port" except in the cases of the cli args for bind address. For those the square braces can be omitted.
2019-07-30daemon: print 128bit diff properlystoffu1-17/+40
2019-07-24Merge pull request #5595luigi11111-0/+15
2aa1134 daemon: display peer address type in print_cn (moneromooo-monero)
2019-07-24Merge pull request #5588luigi11111-0/+1
cd720c7 add cumulative difficulty to diff command (wowario)
2019-07-24Merge pull request #5582luigi11111-4/+8
fcfcc3a rpc: in/out peers can now return the setting's value (moneromooo-monero)
2019-07-24Merge pull request #5573luigi11111-1/+1
c07bbd5 daemon: fix 'never seen before' time span display for peers (moneromooo-monero)
2019-07-24Merge pull request #5530luigi11111-53/+0
6abaaaa remove obsolete save_graph skeleton code (moneromooo-monero)
2019-07-16allow blocking whole subnetsmoneromooo-monero1-13/+40
2019-06-01daemon: add more chain specific info in alt_chain_infomoneromooo-monero1-0/+44
2019-05-31daemon: display peer address type in print_cnmoneromooo-monero1-0/+15
2019-05-30rpc: in/out peers can now return the setting's valuemoneromooo-monero1-4/+8
2019-05-30add cumulative difficulty to diff commandwowario1-0/+1
2019-05-24daemon: fix "never seen before" time span display for peersmoneromooo-monero1-1/+1
2019-05-22Add ssl_options support to monerod's rpc mode.Lee Clagett1-1/+2
2019-05-10remove obsolete save_graph skeleton codemoneromooo-monero1-53/+0
2019-05-09daemon: add optional arguments to alt_chain_infomoneromooo-monero1-5/+17
>N limits display to alt chains with more than N blocks -N limits display to alt chains younger than N blocks
2019-05-09daemon: sort alt chains by heightmoneromooo-monero1-1/+3
2019-05-02blockchain: keep a rolling long term block weight medianmoneromooo-monero1-1/+1
2019-04-16Merge pull request #5446Riccardo Spagni1-1/+1
7d79222f daemon: remove debug info (moneromooo-monero) 8fec0f98 functional_tests: add sweep_single test (moneromooo-monero) 9880d61b wallet_rpc_server: remove unused code (moneromooo-monero) 8a61b33d rpc: omit irrelevant fields for pool txes in gettransactions (moneromooo-monero) 56508524 rpc: add relayed in get_transaction output (moneromooo-monero) 82e510f1 rpc: set default log category in core_rpc_server.h (moneromooo-monero)
2019-04-15daemon: remove debug infomoneromooo-monero1-1/+1
2019-04-14daemon: fix ratio not being floating pointmoneromooo-monero1-1/+1
Coverity 197648
2019-04-11Merge pull request #5378Riccardo Spagni1-1/+1
eda2661a Allow pruning before v10 (moneromooo-monero)
2019-04-04wallet: new option to start background miningmoneromooo-monero1-4/+5
The setup-background-mining option can be used to select background mining when a wallet loads. The user will be asked the first time the wallet is created.
2019-04-01Allow pruning before v10moneromooo-monero1-1/+1
This check is now not needed anymore, and would prevent people from using --prune-blockchain when starting a new sync
2019-03-24New interactive daemon command 'print_net_stats': Global traffic statsrbrunner71-0/+60
2019-03-17Merge pull request #5190Riccardo Spagni1-1/+2
551104fb daemon: add --public-node mode, RPC port propagation over P2P (xiphon)
2019-03-17Merge pull request #5185Riccardo Spagni1-1/+76
59478c80 daemon: new mining_status command (moneromooo-monero)
2019-03-09daemon: new mining_status commandmoneromooo-monero1-1/+76
2019-03-05Update 2019 copyrightbinaryFate1-1/+1
2019-03-04Merge pull request #4054Riccardo Spagni1-0/+2
24569454 epee: add SSL support (moneromooo-monero)
2019-03-04ArticMine's new block weight algorithmmoneromooo-monero1-0/+1
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. Note: the long term block weight is stored in the database, but not in the actual block itself, since it requires recalculating anyway for verification.
2019-02-25daemon: add --public-node mode, RPC port propagation over P2Pxiphon1-1/+2
2019-02-02epee: add SSL supportmoneromooo-monero1-0/+2
RPC connections now have optional tranparent SSL. An optional private key and certificate file can be passed, using the --{rpc,daemon}-ssl-private-key and --{rpc,daemon}-ssl-certificate options. Those have as argument a path to a PEM format private private key and certificate, respectively. If not given, a temporary self signed certificate will be used. SSL can be enabled or disabled using --{rpc}-ssl, which accepts autodetect (default), disabled or enabled. Access can be restricted to particular certificates using the --rpc-ssl-allowed-certificates, which takes a list of paths to PEM encoded certificates. This can allow a wallet to connect to only the daemon they think they're connected to, by forcing SSL and listing the paths to the known good certificates. To generate long term certificates: openssl genrsa -out /tmp/KEY 4096 openssl req -new -key /tmp/KEY -out /tmp/REQ openssl x509 -req -days 999999 -sha256 -in /tmp/REQ -signkey /tmp/KEY -out /tmp/CERT /tmp/KEY is the private key, and /tmp/CERT is the certificate, both in PEM format. /tmp/REQ can be removed. Adjust the last command to set expiration date, etc, as needed. It doesn't make a whole lot of sense for monero anyway, since most servers will run with one time temporary self signed certificates anyway. SSL support is transparent, so all communication is done on the existing ports, with SSL autodetection. This means you can start using an SSL daemon now, but you should not enforce SSL yet or nothing will talk to you.
2019-01-28Merge pull request #5062Riccardo Spagni1-3/+3
acfff8d0 rpc: fix internal daemon calls in restricted rpc getting partial data (moneromooo-monero)
2019-01-28rpc: fix internal daemon calls in restricted rpc getting partial datamoneromooo-monero1-3/+3
2019-01-28Merge pull request #5080Riccardo Spagni1-5/+15
d294a577 daemon: extend 'print_pl' command, optional filter by type and limit (xiphon)
2019-01-22Pruningmoneromooo-monero1-13/+110
The blockchain prunes seven eighths of prunable tx data. This saves about two thirds of the blockchain size, while keeping the node useful as a sync source for an eighth of the blockchain. No other data is currently pruned. There are three ways to prune a blockchain: - run monerod with --prune-blockchain - run "prune_blockchain" in the monerod console - run the monero-blockchain-prune utility The first two will prune in place. Due to how LMDB works, this will not reduce the blockchain size on disk. Instead, it will mark parts of the file as free, so that future data will use that free space, causing the file to not grow until free space grows scarce. The third way will create a second database, a pruned copy of the original one. Since this is a new file, this one will be smaller than the original one. Once the database is pruned, it will stay pruned as it syncs. That is, there is no need to use --prune-blockchain again, etc.
2019-01-18daemon: extend 'print_pl' command, optional filter by type and limitxiphon1-5/+15
2019-01-16Merge pull request #5019Riccardo Spagni1-2/+6
65ce387c daemon: add a +hex option to print_block (moneromooo-monero)
2018-12-26daemon: add a +hex option to print_blockmoneromooo-monero1-2/+6
2018-12-26daemon: print human friendly timestamp toomoneromooo-monero1-2/+2
2018-11-28add command pop_blocksJason Wong1-0/+27
add new public method to Blockchain and update according to code review update after review: better lock/unlock, try catch and coding style
2018-11-16Merge pull request #4777Riccardo Spagni1-4/+4
c17a1d43 daemon: use msg_writer, not cout, to display information (moneromooo-monero)
2018-11-01daemon: use msg_writer, not cout, to display informationmoneromooo-monero1-4/+4
2018-11-01Merge pull request #4648Riccardo Spagni1-1/+13
a7bffead daemon: fix base fee stating /kB even when it is per byte (moneromooo-monero)
2018-10-19daemon: fix base fee stating /kB even when it is per bytemoneromooo-monero1-1/+13
2018-10-18daemon: Show mining addressRicardo de Vries1-1/+1
2018-10-02daemon: do not display uptime when not knownmoneromooo-monero1-5/+15
2018-09-18Merge pull request #4341Riccardo Spagni1-0/+2
e6117282 daemon: request no PoW hashes we don't need when asking for blocks (moneromooo-monero)
2018-09-11v8: per byte fee, pad bulletproofs, fixed 11 ring sizemoneromooo-monero1-12/+15
2018-09-05daemon: request no PoW hashes we don't need when asking for blocksmoneromooo-monero1-0/+2
This fixes the horrendous slowdown in bc_dyn_stats
2018-07-24daemon.print_bc: don't print difficulty twicestoffu1-1/+1
2018-07-19Merge pull request #4029luigi11111-1/+3
bd9e4e3 daemon: show a bit more info with print_block (stoffu)
2018-07-19Merge pull request #3973luigi11111-6/+26
50af357 alt_chain_info can now give more info about a particular alt chain (moneromooo-monero)
2018-06-26alt_chain_info can now give more info about a particular alt chainmoneromooo-monero1-6/+26
2018-06-20daemon: show a bit more info with print_blockstoffu1-1/+3
2018-06-19Merge pull request #3851luigi11111-1/+1
a87980f fix build with GCC 8.1.0 (moneromooo-monero)
2018-06-16Merge pull request #3725luigi11111-1/+1
9cc0d42 connection_context: remove state_ prefix from state names (moneromooo-monero) d9d002c daemon: print peer state in sync_info (moneromooo-monero)
2018-05-31Merge pull request #3561luigi11111-0/+3
353e9c0 Core RPC: optionally add POW hash to block_header_response (stoffu)
2018-05-26fix build with GCC 8.1.0moneromooo-monero1-1/+1
2018-05-19daemon: request unpruned transactions for print_txmoneromooo-monero1-0/+1
instead of uninitialized
2018-04-28daemon: print peer state in sync_infomoneromooo-monero1-1/+1
It's often relevant
2018-04-25Fix broken interactive daemon 'limit' commands plus RPC callsrbrunner71-6/+6
2018-04-05Core RPC: optionally add POW hash to block_header_responsestoffu1-0/+3
2018-03-05Stagenetstoffu1-3/+3
2018-02-16Merge pull request #3165Riccardo Spagni1-4/+21
7539603f Bootstrap daemon (stoffu)
2018-01-30Bootstrap daemonstoffu1-4/+21
2018-01-29Fix in_peers/out_peers RPC operationsErik de Castro Lopo1-2/+2
Original implementations could never have worked.
2018-01-29Allow the number of incoming connections to be limitedErik de Castro Lopo1-0/+32
It was already possible to limit outgoing connections. One might want to do this on home network connections with high bandwidth but low usage caps.
2018-01-26Update 2018 copyrightxmr-eric1-1/+1
2017-12-28Merge pull request #2946Riccardo Spagni1-1/+1
1a686bf8 daemon: print num txes in print_bc (moneromooo-monero)
2017-12-18use const refs in for loops for non tiny typesmoneromooo-monero1-1/+1
2017-12-17daemon: print num txes in print_bcmoneromooo-monero1-1/+1
2017-11-20Merge pull request #2783Riccardo Spagni1-0/+4
416a7933 Print msg upon success for commands that were silent (binaryFate)
2017-11-14remove "using namespace std" from headersmoneromooo-monero1-1/+1
It's nasty, and actually breaks on Solaris, where if.h fails to build due to: struct map *if_memmap;
2017-11-14Merge pull request #2615Riccardo Spagni1-3/+3
10013e94 Protect node privacy by proper filtering in restricted-mode RPC answers (binaryFate)
2017-11-10Print msg upon success for commands that were silentbinaryFate1-0/+4
2017-11-08Protect node privacy by proper filtering in restricted-mode RPC answersbinaryFate1-3/+3
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.
2017-11-06track double spending in the txpoolmoneromooo-monero1-1/+3
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).
2017-11-06Merge pull request #2591Riccardo Spagni1-18/+24
93ad1f87 Fix #2559: more flexible print_tx daemon command (binaryFate)
2017-10-15Merge pull request #2599Riccardo Spagni1-1/+2
b776c725 daemon: use @N syntax to output_histogram for specific amounts (moneromooo-monero)
2017-10-08Fix #2559: more flexible print_tx daemon commandbinaryFate1-18/+24
2017-10-07daemon: use @N syntax to output_histogram for specific amountsmoneromooo-monero1-1/+2
Makes debugging tx verification easier
2017-10-07Subaddresseskenshi841-1/+1
2017-10-02Merge pull request #2512Riccardo Spagni1-1/+1
792ba4f0 Log categories can now be added to and removed from (moneromooo-monero) 48f92eb6 easylogging++: add categories getter (moneromooo-monero) f35afe62 epee: factor log level/categories setting (moneromooo-monero)
2017-10-02Merge pull request #2470Riccardo Spagni1-29/+96
2e59f6ea rpc: add new RPCs to get and set limits (MaxXor)
2017-09-25daemon: initialize decode_as_json in RPC requestmoneromooo-monero1-0/+1
CID 161886
2017-09-22Log categories can now be added to and removed frommoneromooo-monero1-1/+1
Also, set_log without parameters now prints the log categories
2017-09-21daemon: indicate whether the spent key image is mined or unconfirmedstoffu1-1/+1
2017-09-19rpc: add new RPCs to get and set limitsMaxXor1-29/+96
2017-09-02Use latest height for fork date estimateHoward Chu1-2/+3
2017-08-27Merge pull request #2349Riccardo Spagni1-1/+1
1914c999 txpool: update db tx metadata when it changes (moneromooo) 4dbf29bd txpool: add tx size median to the pool stats (moneromooo)
2017-08-26daemon: fix backlog estimating at max block sizemoneromooo-monero1-2/+3
Block size will pretty much never be fully used, unless all txes are using max fee.
2017-08-25txpool: add tx size median to the pool statsmoneromooo1-1/+1
2017-08-25Merge pull request #2311Riccardo Spagni1-16/+4
df0cffed cryptonote_protocol: warn if we see a higher top version we expect (moneromooo-monero) 317ab21a cryptonote_protocol: less strict check on top version on connect (moneromooo-monero) cc81a371 cryptonote_protocol: update target height when syncing too (moneromooo-monero) e2ad372b cryptonote_protocol: simplify and remove unnecessary casts (moneromooo-monero) 727e67ca cryptonote_protocol: print peer top height along with its version (moneromooo-monero) b5345ef4 crypto: use malloc instead of alloca (moneromooo-monero) 80794b31 thread_group: set thread size to THREAD_STACK_SIZE (moneromooo-monero) 5524bc31 print peer id in 0 padded hex for consistency (moneromooo-monero) 8f8cc09b contrib: add sync_info to rlwrap command set (moneromooo-monero) 70b8c6d7 cryptonote_protocol: misc fixes to the new sync algorithm (moneromooo-monero)
2017-08-23print peer id in 0 padded hex for consistencymoneromooo-monero1-16/+4
2017-08-23daemon: print estimated tx backlog in print_pool_statsmoneromooo-monero1-2/+24
2017-08-16Consistently print peer id in hex and on 16 charsmoneromooo-monero1-5/+12
2017-08-12daemon: print peers' top height in sync_infomoneromooo-monero1-1/+1
2017-08-07Merge pull request #2149Riccardo Spagni1-0/+68
158c3ecf core: thread most of handle_incoming_tx (moneromooo-monero) f57ee382 cryptonote_protocol: retry stale spans early (moneromooo-monero) 90df52e1 cryptonote_protocol: light cleanup (moneromooo-monero) 84e23156 cryptonote_protocol: avoid spurious SYNCHRONIZED OK messages (moneromooo-monero) 5be43fcd cryptonote_protocol_handler: sync speedup (moneromooo-monero)
2017-08-07cryptonote_protocol_handler: sync speedupmoneromooo-monero1-0/+68
A block queue is now placed between block download and block processing. Blocks are now requested only from one peer (unless starved). Includes a new sync_info coommand.
2017-07-29daemon: add average seconds per block in bc_dyn_statsmoneromooo-monero1-1/+4
2017-07-19Merge pull request #2170Riccardo Spagni1-5/+4
c3bb6bec daemon: fix status in command line mode if using restricted rpc (moneromooo-monero)
2017-07-13daemon: fix status in command line mode if using restricted rpcmoneromooo-monero1-5/+4
2017-07-10Fix #2164 histogram outputHoward Chu1-1/+1
When there are more than 50txs, the timestamp for the last bin was printed incorrectly. Subtracting "now" was omitted by mistake in 3fc22e7b78ab1dd409de4f3e8f5bff27be19735b
2017-06-04Add histogram to poolstatsHoward Chu1-1/+42
2017-06-01Speedup print_pool_statsHoward Chu1-34/+12
Since we're just counting txs, there's no reason to deserialize all the blobs.
2017-04-11Merge pull request #1956Riccardo Spagni1-1/+3
eb20f720 daemon: print average fee per byte in print_pool_stats (moneromooo-monero) 37be70bb daemon: add fee/byte when print pool transaction info (moneromooo-monero) 893f5a30 tx_pool: add blob size and fee/byte when logging a new tx (moneromooo-monero)
2017-04-04daemon: print average fee per byte in print_pool_statsmoneromooo-monero1-1/+1
2017-04-04daemon: add fee/byte when print pool transaction infomoneromooo-monero1-0/+2
2017-04-02daemon: new relay_tx command and RPCmoneromooo-monero1-0/+28
2017-03-21daemon: better error reporting in commandsmoneromooo-monero1-41/+48
2017-03-18daemon: fix missing close parenthesis in alt_chain_info outputmoneromooo-monero1-1/+1
Reported by assylias_ on IRC
2017-03-18daemon: alt_chain_info now prints fork depthmoneromooo-monero1-2/+14
2017-03-10fix dependency: put HardFork back to cryptonote_basic, made some ↵kenshi841-1/+1
BlockchainDB functions virtual again to avoid missing symbols error
2017-03-03Merge pull request #1814Riccardo Spagni1-2/+2
11a00df6 daemon: fix bc_dyn_stats via rpc (moneromooo-monero)
2017-03-03Merge pull request #1804Riccardo Spagni1-1/+1
12adb4a3 core: move hardfork back to cryptonote_core (moneromooo-monero)
2017-02-26daemon: fix bc_dyn_stats via rpcmoneromooo-monero1-2/+2
2017-02-25core: move hardfork back to cryptonote_coremoneromooo-monero1-1/+1
should fix a cross dependency betewen cryptonote_basic and blockchain_db
2017-02-24daemon/rpc: updates command and RPCmoneromooo-monero1-0/+47
subcommands "check", "download", and "update". update is not yet implemented.
2017-02-23Add print_pl_stats daemon commandMiguel Herranz1-0/+28
2017-02-21update copyright year, fix occasional lack of newline at line endRiccardo Spagni1-1/+1
2017-02-16More robust battery status handling.Dion Ahmetaj1-2/+3
Added an extra path to check for linux power supply status. Added ignore battery option. If set to true, then when we can't figure out the power status, we'll assume the system is plugged in.
2017-02-10Added a note about smart mining to status command. Fixed up a bug where I ↵Dion Ahmetaj1-1/+1
was resetting bg mining enabled instead of started. Upped the miner threshold. Also moved setting of enabled on start above miner thread creation since starting with true, then stopping, then starting with false resulted in race condition.
2017-02-10Background/smart mining. If a users' computer is plugged into a powerDion Ahmetaj1-1/+2
source, and CPU has been idle for some time, then begin mining to some threshold (don't destroy the users' CPU). This patch only supports windows and linux (I've only tested on Win64 and Ubuntu). The variables currently default to pretty conservative values (i.e. 20% CPU mining threshold).
2017-02-11Merge pull request #1689Riccardo Spagni1-2/+6
ce7fcbb4 Add server auth to monerod, and client auth to wallet-cli and wallet-rpc (Lee Clagett)
2017-02-11Merge pull request #1680Riccardo Spagni1-1/+1
db0a5392 Clarify in/out connections for users (NanoAkron)
2017-02-08extract some basic code from libcryptonote_core into libcryptonote_basickenshi841-1/+1
2017-02-06Add server auth to monerod, and client auth to wallet-cli and wallet-rpcLee Clagett1-2/+6
2017-02-05Clarify in/out connections for usersNanoAkron1-1/+1
2017-02-02Fix missing parenthesesMiguel Herranz1-2/+2
2017-02-02Merge pull request #1654Riccardo Spagni1-4/+6
084aef70 Added days uptime to the status message (NanoAkron)
2017-01-31Added days uptime to the status messageNanoAkron1-4/+6
Also broke down the time calculations for legibility
2017-01-23rpc: fix bc_dyn_stats not setting grace blocksmoneromooo-monero1-0/+1
This caused a random value to be used, and the resulting incorrect fee when it wasn't 0.
2017-01-16Change logging to easylogging++moneromooo-monero1-0/+31
This replaces the epee and data_loggers logging systems with a single one, and also adds filename:line and explicit severity levels. Categories may be defined, and logging severity set by category (or set of categories). epee style 0-4 log level maps to a sensible severity configuration. Log files now also rotate when reaching 100 MB. To select which logs to output, use the MONERO_LOGS environment variable, with a comma separated list of categories (globs are supported), with their requested severity level after a colon. If a log matches more than one such setting, the last one in the configuration string applies. A few examples: This one is (mostly) silent, only outputting fatal errors: MONERO_LOGS=*:FATAL This one is very verbose: MONERO_LOGS=*:TRACE This one is totally silent (logwise): MONERO_LOGS="" This one outputs all errors and warnings, except for the "verify" category, which prints just fatal errors (the verify category is used for logs about incoming transactions and blocks, and it is expected that some/many will fail to verify, hence we don't want the spam): MONERO_LOGS=*:WARNING,verify:FATAL Log levels are, in decreasing order of priority: FATAL, ERROR, WARNING, INFO, DEBUG, TRACE Subcategories may be added using prefixes and globs. This example will output net.p2p logs at the TRACE level, but all other net* logs only at INFO: MONERO_LOGS=*:ERROR,net*:INFO,net.p2p:TRACE Logs which are intended for the user (which Monero was using a lot through epee, but really isn't a nice way to go things) should use the "global" category. There are a few helper macros for using this category, eg: MGINFO("this shows up by default") or MGINFO_RED("this is red"), to try to keep a similar look and feel for now. Existing epee log macros still exist, and map to the new log levels, but since they're used as a "user facing" UI element as much as a logging system, they often don't map well to log severities (ie, a log level 0 log may be an error, or may be something we want the user to see, such as an important info). In those cases, I tried to use the new macros. In other cases, I left the existing macros in. When modifying logs, it is probably best to switch to the new macros with explicit levels. The --log-level options and set_log commands now also accept category settings, in addition to the epee style log levels.
2017-01-15Merge pull request #1571Riccardo Spagni1-0/+2
81c384e4 fix do_not_relay not preventing relaying on a timer (moneromooo-monero)
2017-01-14fix do_not_relay not preventing relaying on a timermoneromooo-monero1-0/+2
Also print its value when printing pool
2017-01-13rpc: add a command to get info about the current blockchainmoneromooo-monero1-0/+103
About the tip of the main chain, and the last N blocks
2017-01-12Add start_time to get_info methods and show uptimeMiguel Herranz1-1/+6
2017-01-06rpc: add block size to GET_BLOCK_HEADER RPCmoneromooo-monero1-1/+2
and print it in print_bc
2016-12-17rpc: new function and RPC to get alternative chain infomoneromooo-monero1-0/+33
2016-11-09add lightweight block propagation ("fluffy blocks")Dion Ahmetaj1-0/+2
Added a new command to the P2P protocol definitions to allow querying for support flags. Implemented handling of new support flags command in net_node. Changed for_each callback template to include support flags. Updated print_connections command to show peer support flags. Added p2p constant for signaling fluffy block support. Added get_pool_transaction function to cryptnote_core. Added new commands to cryptonote protocol for relaying fluffy blocks. Implemented handling of fluffy block command in cryptonote protocol. Enabled fluffy block support in node initial configuration. Implemented get_testnet function in cryptonote_core. Made it so that fluffy blocks only run on testnet.
2016-10-23daemon: fix min/max tracking using the wrong sizemoneromooo-monero1-4/+4
Reported by iDunk
2016-10-23daemon: even when switching branches, compile the damn thing ffsmoneromooo-monero1-1/+1