Commit Graph

264 Commits

Author SHA1 Message Date
Ricardo de Vries e54e5668a8 daemon: Show mining address 2018-10-18 10:45:42 +02:00
moneromooo-monero 5ec929fb3a
daemon: do not display uptime when not known 2018-10-02 08:40:38 +00:00
Riccardo Spagni 7ab49f96ad
Merge pull request #4341
e6117282 daemon: request no PoW hashes we don't need when asking for blocks (moneromooo-monero)
2018-09-18 17:39:56 +02:00
moneromooo-monero 5ffb2ff9b7
v8: per byte fee, pad bulletproofs, fixed 11 ring size 2018-09-11 13:38:07 +00:00
moneromooo-monero e611728228
daemon: request no PoW hashes we don't need when asking for blocks
This fixes the horrendous slowdown in bc_dyn_stats
2018-09-05 09:43:44 +00:00
stoffu 3940e12933
daemon.print_bc: don't print difficulty twice 2018-07-24 16:17:49 +09:00
luigi1111 138aefd0e7
Merge pull request #4029
bd9e4e3 daemon: show a bit more info with print_block (stoffu)
2018-07-19 13:52:41 -05:00
luigi1111 d518dae4bf
Merge pull request #3973
50af357 alt_chain_info can now give more info about a particular alt chain (moneromooo-monero)
2018-07-19 13:37:10 -05:00
moneromooo-monero 50af3579ee
alt_chain_info can now give more info about a particular alt chain 2018-06-26 08:19:51 +01:00
stoffu bd9e4e3149
daemon: show a bit more info with print_block 2018-06-20 12:04:03 +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
luigi1111 737712c0c6
Merge pull request #3561
353e9c0 Core RPC: optionally add POW hash to block_header_response (stoffu)
2018-05-31 14:38:01 -05:00
moneromooo-monero a87980f6c2
fix build with GCC 8.1.0 2018-05-26 14:54:10 +01:00
moneromooo-monero 29fbaeaae5
daemon: request unpruned transactions for print_tx
instead of uninitialized
2018-05-19 00:04:46 +01:00
moneromooo-monero d9d002c3c1
daemon: print peer state in sync_info
It's often relevant
2018-04-28 19:56:39 +01:00
rbrunner7 f9d0827bba Fix broken interactive daemon 'limit' commands plus RPC calls 2018-04-25 21:37:10 +02:00
stoffu 353e9c0c90
Core RPC: optionally add POW hash to block_header_response 2018-04-05 23:15:15 +09:00
stoffu af773211cb
Stagenet 2018-03-05 11:55:05 +09:00
Riccardo Spagni 04a676397f
Merge pull request #3165
7539603f Bootstrap daemon (stoffu)
2018-02-16 14:18:50 +01:00
stoffu 7539603f94
Bootstrap daemon 2018-01-30 20:15:47 +09:00
Erik de Castro Lopo 628b78ae8a Fix in_peers/out_peers RPC operations
Original implementations could never have worked.
2018-01-29 11:54:57 +11:00
Erik de Castro Lopo 32c0f908cd Allow the number of incoming connections to be limited
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-29 11:14:02 +11:00
xmr-eric 18216f19dd Update 2018 copyright 2018-01-26 10:03:20 -05:00
Riccardo Spagni 3bbe2481ce
Merge pull request #2946
1a686bf8 daemon: print num txes in print_bc (moneromooo-monero)
2017-12-28 08:59:31 +02:00
moneromooo-monero b51dc56687
use const refs in for loops for non tiny types 2017-12-18 15:15:54 +00:00
moneromooo-monero 1a686bf8cc
daemon: print num txes in print_bc 2017-12-17 12:55:40 +00:00
Riccardo Spagni 49ce59462a
Merge pull request #2783
416a7933 Print msg upon success for commands that were silent (binaryFate)
2017-11-20 12:09:02 +09:00
moneromooo-monero 383ff4f689
remove "using namespace std" from headers
It's nasty, and actually breaks on Solaris, where if.h fails to
build due to:

  struct map *if_memmap;
2017-11-14 16:56:10 +00:00
Riccardo Spagni fd0740e5e7
Merge pull request #2615
10013e94 Protect node privacy by proper filtering in restricted-mode RPC answers (binaryFate)
2017-11-14 14:53:10 +02:00
binaryFate 416a793326 Print msg upon success for commands that were silent 2017-11-10 09:42:40 +01:00
binaryFate 10013e9434 Protect node privacy by proper filtering in restricted-mode RPC answers
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-08 13:07:07 +01:00
moneromooo-monero ccf53a566c
track double spending in the txpool
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-06 00:05:44 +00:00
Riccardo Spagni 7452359d8f
Merge pull request #2591
93ad1f87 Fix #2559: more flexible print_tx daemon command (binaryFate)
2017-11-06 01:54:48 +02:00
Riccardo Spagni f484b162db
Merge pull request #2599
b776c725 daemon: use @N syntax to output_histogram for specific amounts (moneromooo-monero)
2017-10-15 18:48:19 +02:00
binaryFate 93ad1f8723 Fix #2559: more flexible print_tx daemon command 2017-10-08 22:35:35 +02:00
moneromooo-monero b776c72568
daemon: use @N syntax to output_histogram for specific amounts
Makes debugging tx verification easier
2017-10-07 16:45:54 +01:00
kenshi84 53ad5a0f42
Subaddresses 2017-10-07 13:06:21 +09:00
Riccardo Spagni 3bab2676ec
Merge pull request #2512
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-02 23:28:59 +04:00
Riccardo Spagni 3bf20a77f2
Merge pull request #2470
2e59f6ea rpc: add new RPCs to get and set limits (MaxXor)
2017-10-02 23:15:22 +04:00
moneromooo-monero 06c1e05735
daemon: initialize decode_as_json in RPC request
CID 161886
2017-09-25 15:48:03 +01:00
moneromooo-monero 792ba4f0fe
Log categories can now be added to and removed from
Also, set_log without parameters now prints the log categories
2017-09-22 18:08:14 +01:00
stoffu c09aa94d34
daemon: indicate whether the spent key image is mined or unconfirmed 2017-09-21 07:46:44 +09:00
MaxXor 2e59f6ea50 rpc: add new RPCs to get and set limits 2017-09-19 10:30:55 +02:00
Howard Chu 1181848748
Use latest height for fork date estimate 2017-09-02 11:44:12 +01:00
Riccardo Spagni 72b5f37f58
Merge pull request #2349
1914c999 txpool: update db tx metadata when it changes (moneromooo)
4dbf29bd txpool: add tx size median to the pool stats (moneromooo)
2017-08-27 18:15:13 +02:00
moneromooo-monero 19393115dc
daemon: fix backlog estimating at max block size
Block size will pretty much never be fully used, unless all txes
are using max fee.
2017-08-26 17:11:40 +01:00
moneromooo 4dbf29bd32
txpool: add tx size median to the pool stats 2017-08-25 22:21:38 +01:00
Riccardo Spagni 335681896a
Merge pull request #2311
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-25 00:21:28 +02:00
moneromooo-monero 5524bc3151
print peer id in 0 padded hex for consistency 2017-08-23 13:37:56 +01:00
moneromooo-monero 679a5ab85b
daemon: print estimated tx backlog in print_pool_stats 2017-08-23 12:12:06 +01:00
moneromooo-monero 42b34b3545
Consistently print peer id in hex and on 16 chars 2017-08-16 10:56:55 +01:00
moneromooo-monero 2ec15a6931
daemon: print peers' top height in sync_info 2017-08-12 20:36:31 +01:00
Riccardo Spagni 6db8a60a18
Merge pull request #2149
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-07 15:24:58 +02:00
moneromooo-monero 5be43fcdba
cryptonote_protocol_handler: sync speedup
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-08-07 09:33:04 +01:00
moneromooo-monero d37e8f8868
daemon: add average seconds per block in bc_dyn_stats 2017-07-29 18:43:50 +01:00
Riccardo Spagni c0f155d3a0
Merge pull request #2170
c3bb6bec daemon: fix status in command line mode if using restricted rpc (moneromooo-monero)
2017-07-19 11:51:35 +02:00
moneromooo-monero c3bb6becd9
daemon: fix status in command line mode if using restricted rpc 2017-07-13 10:17:57 +01:00
Howard Chu 8db68a57f5
Fix #2164 histogram output
When there are more than 50txs, the timestamp for the last
bin was printed incorrectly. Subtracting "now" was omitted by mistake
in 3fc22e7b78
2017-07-10 15:51:03 +01:00
Howard Chu 3fc22e7b78
Add histogram to poolstats 2017-06-04 22:48:14 +01:00
Howard Chu 5414970dcd
Speedup print_pool_stats
Since we're just counting txs, there's no reason to deserialize all the blobs.
2017-06-01 17:34:03 +01:00
Riccardo Spagni 9ed496bbc5
Merge pull request #1956
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-11 00:34:46 +02:00
moneromooo-monero eb20f7209e
daemon: print average fee per byte in print_pool_stats 2017-04-04 19:00:57 +01:00
moneromooo-monero 37be70bbd7
daemon: add fee/byte when print pool transaction info 2017-04-04 09:04:39 +01:00
moneromooo-monero 548075b1f5
daemon: new relay_tx command and RPC 2017-04-02 12:17:35 +01:00
moneromooo-monero c94f8facf5
daemon: better error reporting in commands 2017-03-21 19:21:00 +00:00
moneromooo-monero d5fbfd677c
daemon: fix missing close parenthesis in alt_chain_info output
Reported by assylias_ on IRC
2017-03-18 19:19:32 +00:00
moneromooo-monero 63d7cd8882
daemon: alt_chain_info now prints fork depth 2017-03-18 16:59:57 +00:00
kenshi84 7d07c64fe5
fix dependency: put HardFork back to cryptonote_basic, made some BlockchainDB functions virtual again to avoid missing symbols error 2017-03-10 11:22:39 +09:00
Riccardo Spagni 9e10fac223
Merge pull request #1814
11a00df6 daemon: fix bc_dyn_stats via rpc (moneromooo-monero)
2017-03-03 14:14:51 +02:00
Riccardo Spagni 3787ffca80
Merge pull request #1804
12adb4a3 core: move hardfork back to cryptonote_core (moneromooo-monero)
2017-03-03 14:11:09 +02:00
moneromooo-monero 11a00df699
daemon: fix bc_dyn_stats via rpc 2017-02-26 23:12:55 +00:00
moneromooo-monero 12adb4a3f3
core: move hardfork back to cryptonote_core
should fix a cross dependency betewen cryptonote_basic and
blockchain_db
2017-02-25 16:41:35 +00:00
moneromooo-monero ea873ceb2c
daemon/rpc: updates command and RPC
subcommands "check", "download", and "update".
update is not yet implemented.
2017-02-24 23:18:27 +00:00
Miguel Herranz 3bdda60f3e Add print_pl_stats daemon command 2017-02-23 18:20:17 +01:00
Riccardo Spagni c3599fa7b9
update copyright year, fix occasional lack of newline at line end 2017-02-21 19:38:18 +02:00
Dion Ahmetaj 69ab14d91e More robust battery status handling.
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-16 14:35:01 -05:00
Dion Ahmetaj ad95e65028 Added a note about smart mining to status command. Fixed up a bug where I 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-10 18:07:43 -05:00
Dion Ahmetaj 345ed4823c Background/smart mining. If a users' computer is plugged into a power
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-10 18:07:39 -05:00
Riccardo Spagni eacf2124b6 Merge pull request #1689
ce7fcbb4 Add server auth to monerod, and client auth to wallet-cli and wallet-rpc (Lee Clagett)
2017-02-11 00:35:25 +02:00
Riccardo Spagni 4feaa790e2
Merge pull request #1680
db0a5392 Clarify in/out connections for users (NanoAkron)
2017-02-11 00:21:12 +02:00
kenshi84 8027ce0c75 extract some basic code from libcryptonote_core into libcryptonote_basic 2017-02-08 22:45:15 +09:00
Lee Clagett ce7fcbb4ae Add server auth to monerod, and client auth to wallet-cli and wallet-rpc 2017-02-06 01:15:41 -05:00
NanoAkron db0a5392a5
Clarify in/out connections for users 2017-02-05 11:15:51 +00:00
Miguel Herranz 03ff363982 Fix missing parentheses 2017-02-02 22:05:31 +01:00
Riccardo Spagni f4fe39ca92
Merge pull request #1654
084aef70 Added days uptime to the status message (NanoAkron)
2017-02-02 21:38:15 +02:00
NanoAkron 084aef700b
Added days uptime to the status message
Also broke down the time calculations for legibility
2017-01-31 09:49:32 +00:00
moneromooo-monero a39cd745c9
rpc: fix bc_dyn_stats not setting grace blocks
This caused a random value to be used, and the resulting
incorrect fee when it wasn't 0.
2017-01-23 19:28:00 +00:00
moneromooo-monero 5833d66f65
Change logging to easylogging++
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-16 00:25:46 +00:00
Riccardo Spagni 10c6afd316
Merge pull request #1571
81c384e4 fix do_not_relay not preventing relaying on a timer (moneromooo-monero)
2017-01-15 14:50:10 -05:00
moneromooo-monero 81c384e408
fix do_not_relay not preventing relaying on a timer
Also print its value when printing pool
2017-01-14 13:07:05 +00:00
moneromooo-monero 5b5017e267
rpc: add a command to get info about the current blockchain
About the tip of the main chain, and the last N blocks
2017-01-13 23:21:38 +00:00
Miguel Herranz 19be7225cc Add start_time to get_info methods and show uptime 2017-01-12 00:15:21 +01:00
moneromooo-monero 9731b4e54f
rpc: add block size to GET_BLOCK_HEADER RPC
and print it in print_bc
2017-01-06 19:38:27 +00:00
moneromooo-monero 55fa0479a0
rpc: new function and RPC to get alternative chain info 2016-12-17 11:28:49 +00:00
Dion Ahmetaj d61bd8187e add lightweight block propagation ("fluffy blocks")
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-11-09 14:24:27 -05:00
moneromooo-monero eb4ecd442d
daemon: fix min/max tracking using the wrong size
Reported by iDunk
2016-10-23 23:18:34 +01:00
moneromooo-monero 30946700a3
daemon: even when switching branches, compile the damn thing ffs 2016-10-23 20:21:00 +01:00
moneromooo-monero 2f4f6c7c26
daemon: do not divide by 0 when the pool is empty 2016-10-23 20:05:13 +01:00
Riccardo Spagni a0975e59ed
Merge pull request #1250
839280d daemon: add a print_pool_stats daemon command (moneromooo-monero)
2016-10-23 19:25:33 +02:00
moneromooo-monero 839280d5fc
daemon: add a print_pool_stats daemon command
Helps see what's going on now that Monero is getting used
2016-10-23 16:11:20 +01:00
moneromooo-monero 10a79eae24
daemon: report transaction relay status in print_pool* commands 2016-10-23 00:32:55 +01:00
moneromooo-monero 88faec75fe
wallet: select part of the fake outs from recent outputs
25% of the outputs are selected from the last 5 days (if possible),
in order to avoid the common case of sending recently received
outputs again. 25% and 5 days are subject to review later, since
it's just a wallet level change.
2016-10-15 18:17:16 +01:00
Dion Ahmetaj 7db29d6903 print_coinbase_tx_sum now breaks output into fee and emission components 2016-10-10 19:55:18 -04:00
Dion Ahmetaj dd6c44327b changed params from start/end index to height/count 2016-10-10 17:19:36 -04:00
Dion Ahmetaj e95d3f359b attempted to remove whitespace spam 2016-10-10 16:41:24 -04:00
Dion Ahmetaj 412da63622 added print_coinbase_tx_sum option 2016-10-10 15:45:51 -04:00
Riccardo Spagni ab60c0503c
Merge pull request #1164
179b1f4 daemon: implement missing print_bc and matching RPC (moneromooo-monero)
2016-10-04 12:14:12 +02:00
Riccardo Spagni e34ef4de6c
Merge pull request #1171
6390673 Removed all code related to fast_exit (NanoAkron)
2016-10-04 11:41:41 +02:00
Riccardo Spagni 298a0723e8
Merge pull request #1149
25be1d3 Noticed two spellings of the word 'response' in the codebase, one 'responce' and the other 'response'. (NanoAkron)
2016-10-04 11:34:53 +02:00
NanoAkron 6390673137 Removed all code related to fast_exit 2016-10-03 02:06:55 +01:00
moneromooo-monero 179b1f43af
daemon: implement missing print_bc and matching RPC 2016-10-02 10:21:21 +01:00
NanoAkron 25be1d3ed4 Noticed two spellings of the word 'response' in the codebase, one 'responce' and the other 'response'.
Fixed to the standard spelling 'response'. This may fix some functionality - some calls had mixed spellings.
2016-09-29 14:38:12 +01:00
moneromooo-monero 8b4e7c6c9c
daemon: report status at 99.9% rather than 100% when not quite synced
Less confusing for users.
2016-09-24 11:45:19 +01:00
moneromooo-monero eeb2bbc0fc
epee: optionally restrict HTTP service to a configurable user agent
This is intended to catch traffic coming from a web browser,
so we avoid issues with a web page sending a transfer RPC to
the wallet. Requiring a particular user agent can act as a
simple password scheme, while we wait for 0MQ and proper
authentication to be merged.
2016-09-18 20:32:02 +01:00
iDunk5400 f1381388ec Daemon: fix hashrate display in diff command output 2016-09-10 23:16:25 +02:00
Riccardo Spagni df63e0704a
fix remaining bitmonero and simplewallet bits 2016-09-03 22:03:44 +02:00
moneromooo-monero 7e4e0021f4
daemon: print time to next fork 2016-08-12 20:32:23 +01:00
moneromooo-monero 78cc10f3fa
daemon: fix ban seconds being misinterpreted as absolute
Absolute to relative conversion is already done by the callee.
2016-07-10 15:13:53 +01:00
Riccardo Spagni c2e9866fc6
Merge pull request #797
d662ab5 rpc: print human readable time since received when printing pool (moneromooo-monero)
5c9dd23 rpc: add a do_not_relay boolean to tx submission (moneromooo-monero)
2016-04-14 16:20:41 +09:00
moneromooo-monero f17b2f42b2
rpc: add pool/blockchain and block height results to gettransactions 2016-04-09 12:40:32 +01:00
moneromooo-monero d662ab5cec
rpc: print human readable time since received when printing pool 2016-04-05 20:16:05 +01:00
moneromooo-monero 600a3cf0c0
New RPC and daemon command to get output histogram
This is a list of existing output amounts along with the number
of outputs of that amount in the blockchain.

The daemon command takes:
- no parameters: all outputs with at least 3 instances
- one parameter: all outputs with at least that many instances
- two parameters: all outputs within that many instances

The default starts at 3 to avoid massive spamming of all dust
outputs in the blockchain, and is the current minimum mixin
requirement.

An optional vector of amounts may be passed, to request
histogram only for those outputs.
2016-03-26 21:10:43 +00:00
moneromooo-monero f7301c3563
Revert "Print stack trace upon exceptions"
Ain't nobody got time for link/cmake skullduggery.

This reverts commit fff238ec94.
2016-03-21 10:12:23 +00:00
Riccardo Spagni 9b10e9cc75
Merge pull request #735
d2aa427 rpc: fix print_tx in command line mode (moneromooo-monero)
2016-03-20 21:27:28 +02:00
moneromooo-monero d2aa427c78
rpc: fix print_tx in command line mode
It was only filling the input in non rpc mode
2016-03-19 23:58:30 +00:00
moneromooo-monero fff238ec94
Print stack trace upon exceptions
Useful for debugging users' logs
2016-03-19 21:48:36 +00:00
Mike C 5dd91f6332 fix formatting error on bitmonero print_block return
Example of current return for `print_block 912345`:

    timestamp: 1452793716
    previous hash:
b61c58b2e0be53fad5ef9d9731a55e8a81d972b8d90ed07c04fd37ca6403ff78
    nonce: 1646
    is orphan: 0
    height: 912345
    depth: 85434
    hash:
e22cf75f39ae720e8b71b3d120a5ac03f0db50bba6379e2850975b4859190bc6difficul
ty: 815625611
    reward: 7388968946286
    {
      "major_version": 1,
      "minor_version": 2,
      …

Without `std::endl`, the difficulty gets smashed on the end of the hash.
2016-03-14 23:31:09 -06:00
moneromooo-monero d9f4b395e8
daemon: remove leftover debug log 2016-02-05 16:36:28 +00:00
Riccardo Spagni 39d73d2a27
Merge pull request #631
bcac101 daemon: fix a few issues reported by valgrind (moneromooo-monero)
a7e8174 tx_pool: fix serialization of new relayed data (moneromooo-monero)
601ad76 hardfork: fix mixup in indexing variable in get_voting_info (moneromooo-monero)
444e22f blockchain: remove unused timer (moneromooo-monero)
7edfdd8 blockchain: fix m_sync_counter uninitialized variable use (moneromooo-monero)
d97582c epee: use generate_random_bytes for new random uuids (moneromooo-monero)
17c7c9c epee: remove dodgy random code that nobody uses (moneromooo-monero)
2016-01-31 15:20:18 +02:00
moneromooo-monero bcac1018af
daemon: fix a few issues reported by valgrind
In particular, ensure we check the status of RPC response structures,
as some functions will return success, but with a BUSY status, when
the daemon is not yet synced, and the response will not filled.
2016-01-30 22:14:51 +00:00
moneromooo-monero bf6d1474c0
new flush_txpool command, and associated RPC call
It can flush a particular tx, or the whole pool (the RPC command
can flush a list of transactions too)
2016-01-30 13:28:26 +00:00
Riccardo Spagni afe2d1a09f
add received time to print_pool and print_pool_sh 2016-01-28 11:24:26 +02:00
binaryFate 0100e951d3 'max limit of...' is redundant wording, rephrase 2016-01-14 23:13:12 +01:00
binaryFate 80e38895b3 Print msg when successfully updating out_peers 2016-01-14 23:10:07 +01:00
moneromooo-monero eaf4dcd747
daemon: fix status command when run from command line 2016-01-11 21:50:41 +00:00
Riccardo Spagni de03926850
updated copyright year 2015-12-31 08:39:56 +02:00
moneromooo-monero 0ab56b80db
print top block hash in daemon diff command
and add top block hash in get_info RPC
2015-12-18 19:56:17 +00:00
moneromooo-monero f7464343ea
daemon: add mining status to the status command 2015-12-07 19:40:12 +00:00
Riccardo Spagni 83b412f471
Merge pull request #503
55e5a33 rpc: pass current block target in rpc (moneromooo-monero)
2015-11-30 00:16:58 +02:00
moneromooo-monero 55e5a33d85
rpc: pass current block target in rpc
This fixes the hash rate being wrong on testnet after the switch
to 2 minute blocks
2015-11-26 00:25:13 +00:00
moneromooo-monero 38ceb73848
add RPC calls and commands to get/set bans 2015-11-26 00:04:22 +00:00
moneromooo-monero 06c8b94925
daemon: fix blockchain height display not updating after sync 2015-11-23 13:16:05 +00:00
moneromooo-monero 051ddbc741
rpc: fix start_mining and status RPC crashes
They check whether they're running on testnet by accessing the
m_rpc_server object, which does not exist when in RPC mode.

Also, fix hard_fork_info being called with the wrong API.
2015-10-28 18:09:36 +00:00
Riccardo Spagni 0640cde88f
Merge pull request #448
06c65cb rpc: fix hard_fork_info RPC (moneromooo-monero)
6f5c129 rpc: fix a few commands not working as command line (moneromooo-monero)
2015-10-26 17:59:25 +02:00
moneromooo-monero 06c65cb0ef
rpc: fix hard_fork_info RPC
I had never tested it, obviously
2015-10-26 10:17:48 +00:00
moneromooo-monero 6f5c129c92
rpc: fix a few commands not working as command line
The method name to the "json_rpc" commands are names, not part
of URLs.
2015-10-26 10:17:03 +00:00
moneromooo-monero 9caf52bf5a
daemon: add a status command
Displays current block height and target, net hash, hard fork
basic info, and connections.
Useful as a basic user friendly "what's going on here" command.
2015-10-25 21:36:46 +00:00
moneromooo-monero ca23c0e5c8
core_rpc_server: add a getblock RPC command, and fix print_block 2015-10-13 21:37:35 +01:00
moneromooo-monero e546f3724a
Add an RPC call and daemon command to get info on hard fork voting 2015-09-19 16:47:48 +01:00