Commit graph

95 commits

Author SHA1 Message Date
Peter Todd 08843ed998 Add relaytxes status to getpeerinfo 2015-11-20 16:07:12 -08:00
Jonas Schnelli f6d9d5ee75
add (max)uploadtarget infos to getnettotals RPC help 2015-11-12 15:01:30 +01:00
Wladimir J. van der Laan b2ce2c1f0f
Merge pull request #6870
040c0ea Init: Cleanup error and warning strings (MarcoFalke)
6782f58 [trivial] Latest config.guess (MarcoFalke)
bf68191 [trivial] rpcnet: fix typo (MarcoFalke)
95f4291 [trivial] Rewrite help text for feature enabled by default (MarcoFalke)
2015-10-29 13:30:42 +01:00
Jonas Schnelli 872fee3fcc
Introduce -maxuploadtarget
* -maxuploadtarget can be set in MiB
* if <limit> - ( time-left-in-24h-cycle / 600 * MAX_BLOCK_SIZE ) has reach, stop serve blocks older than one week and filtered blocks
* no action if limit has reached, no guarantee that the target will not be  surpassed
* add outbound limit informations to rpc getnettotals
2015-10-26 15:37:30 +01:00
MarcoFalke bf681918d7 [trivial] rpcnet: fix typo 2015-10-23 08:35:05 +02:00
Jonas Schnelli 9623e93473 [Univalue] add univalue over subtree
similar to secp256k1 include and compile univalue over a subtree
2015-10-01 10:49:57 +02:00
Jonas Schnelli 6135309816 [Qt] banlist, UI optimizing and better signal handling 2015-09-16 16:50:19 +02:00
Jonas Schnelli 5f42132950 [Qt] add ui signal for banlist changes 2015-09-16 16:50:19 +02:00
Matt Corallo a6eb4ba38b Report minimum ping time in getpeerinfo 2015-09-03 13:06:13 -07:00
Wladimir J. van der Laan c384800027
Merge pull request #6462
7b79cbd limit total length of user agent comments (Pavol Rusnak)
557f8ea implement uacomment config parameter which can add comments to user agent as per BIP-0014 (Pavol Rusnak)
2015-08-05 15:43:10 +02:00
Pavol Rusnak 7b79cbd722 limit total length of user agent comments
Reworked-By: Wladimir J. van der Laan <laanwj@gmail.com>
2015-08-05 09:38:20 +02:00
Ross Nicoll 9ca7857df7 Rationalize currency unit to "BTC"
Previously various user-facing strings have used inconsistent currency units "BTC",
"btc" and "bitcoins". This adds a single constant and uses it for each reference to
the currency unit.

Also adds a description of the unit for --maxtxfee, and adds the missing "amount"
field description to the (deprecated) move RPC command.
2015-08-03 22:58:30 +01:00
Pavol Rusnak 557f8eac7a implement uacomment config parameter
which can add comments to user agent as per BIP-0014
2015-07-31 16:19:23 +02:00
Jorge Timón 9dd793f499 TRIVIAL: Missing includes 2015-07-23 21:10:22 +02:00
Jonas Schnelli 409bccfbf5 use CBanEntry as object container for banned nodes
- added a reason enum for a ban
- added creation time for a ban

Using CBanEntry as container will keep banlist.dat extenable.
2015-07-02 20:29:36 +02:00
Jonas Schnelli f581d3d656 banlist.dat: store banlist on disk 2015-07-02 20:29:36 +02:00
Jonas Schnelli 1c043d5672 fix lock issue for QT node diconnect and RPC disconnectnode 2015-06-19 16:32:22 +02:00
Jonas Schnelli 1f02b80253 setban: add RPCErrorCode 2015-06-17 21:40:56 +02:00
Jonas Schnelli 4e36e9bcc7 setban: rewrite to UniValue, allow absolute bantime 2015-06-17 21:40:55 +02:00
Jonas Schnelli 3de24d7647 rename json field "bannedtill" to "banned_until" 2015-06-17 21:40:55 +02:00
Jonas Schnelli 433fb1a95d [RPC] extend setban to allow subnets 2015-06-17 21:40:55 +02:00
Jonas Schnelli d930b26a26 [RPC] add setban/listbanned/clearbanned RPC commands 2015-06-17 21:40:55 +02:00
Alex van der Peet 60dbe73016 New RPC command disconnectnode 2015-06-16 14:19:41 +02:00
Stephen ef2a3de25c Add paytxfee to getwalletinfo, warnings to getnetworkinfo 2015-06-11 16:12:34 -04:00
Philip Kaufmann a9ac95c1bc use const references where appropriate 2015-06-04 19:34:18 +02:00
Jonas Schnelli 9a8897f4ac Remove JSON Spirit wrapper, remove JSON Spirit leftovers
- implement find_value() function for UniValue
- replace all Array/Value/Object types with UniValues, remove JSON Spirit to UniValue wrapper
- remove JSON Spirit sources
2015-06-04 09:16:21 +02:00
Jonas Schnelli 3df0411ad9 remove JSON Spirit UniValue wrapper 2015-06-04 09:16:06 +02:00
Jonas Schnelli 6c7bee0624 expicit set UniValue type to avoid empty values 2015-06-04 09:16:05 +02:00
Jeff Garzik 15982a8b69 Convert tree to using univalue. Eliminate all json_spirit uses. 2015-06-04 09:16:05 +02:00
Wladimir J. van der Laan 67a7949397 privacy: Stream isolation for Tor
According to Tor's extensions to the SOCKS protocol
(https://gitweb.torproject.org/torspec.git/tree/socks-extensions.txt)
it is possible to perform stream isolation by providing authentication
to the proxy. Each set of credentials will create a new circuit,
which makes it harder to correlate connections.

This patch adds an option, `-proxyrandomize` (on by default) that randomizes
credentials for every outgoing connection, thus creating a new circuit.

    2015-03-16 15:29:59 SOCKS5 Sending proxy authentication 3842137544:3256031132
2015-04-17 13:26:47 +02:00
Eric Lombrozo 4401b2d7c5 Removed main.h dependency from rpcserver.cpp
Rebased by @laanwj:

- update for RPC methods added since 84d13ee: setmocktime,
  invalidateblock, reconsiderblock. Only the first, setmocktime, required a change,
  the other two are thread safe.
2015-01-28 07:41:54 +01:00
Wladimir J. van der Laan c986972ad7
Merge pull request #5476
73caf47 Display time offset in the debug window's Peers tab (Pavel Janík)
26a6bae Add time offset to getpeerinfo output (Pavel Janík)
2015-01-02 17:54:21 +01:00
sandakersmann f914f1a746
Added "Core" to copyright headers
Github-Pull: #5494
Rebased-From: 15de949bb9277e442302bdd8dee299a8d6deee60
2014-12-19 19:55:32 +01:00
Pavel Janík 26a6bae753 Add time offset to getpeerinfo output 2014-12-15 11:06:15 +01:00
Michael Ford 72fb3d295a Update comments in src/rpc* to be doxygen compatible 2014-11-20 10:19:39 +08:00
Cory Fields 71697f97d3 Separate protocol versioning from clientversion 2014-10-29 00:24:40 -04:00
Pieter Wuille ad6e601712 RPC additions after headers-first 2014-10-14 15:42:01 -07:00
Pieter Wuille 341735eb8f Headers-first synchronization
Many changes:
* Do not use 'getblocks', but 'getheaders', and use it to build a headers tree.
* Blocks are fetched in parallel from all available outbound peers, using a
  limited moving window. When one peer stalls the movement of the window, it is
  disconnected.
* No more orphan blocks. At all. We only ever request a block for which we have
  verified the headers, and store it to disk immediately. This means that a
  disk-fill attack would require PoW.
* Require protocol version 31800 for every peer (released in december 2010).
* No more syncnode (we sync from everyone we can, though limited to 1 during
  initial *headers* sync).
* Introduce some extra named constants, comments and asserts.
2014-10-14 15:42:01 -07:00
Philip Kaufmann b5ec5fe0cb update getnetworkinfo help with subversion
- add missing subversion field to getnetworkinfo help
- fix style and format errors in help string
- remove unneeded int casts
2014-10-01 10:23:00 +02:00
Jeff Garzik ff36cbe8d0 RPC getnetworkinfo: export local node's client sub-version string 2014-09-25 10:09:21 +02:00
imharrywu c15e483f23 typo fix of booleamn to boolean 2014-09-18 08:15:09 +08:00
Philip Kaufmann ee304b6e35 minor changes for help message of getpeerinfo 2014-09-16 09:00:36 +02:00
Philip Kaufmann 611116d4e3 header include cleanup
- ensures alphabetical ordering for includes etc. in source file headers
2014-09-14 12:43:56 +02:00
Wladimir J. van der Laan aa8279513b
Add detailed network info to getnetworkinfo RPC
This commit adds per-network information to the
getnetworkinfo RPC call:

- Is the network limited?
- Is the network reachable
- Which proxy is used for this network, if any

Inspired by #2575.
2014-08-18 13:36:10 +02:00
Philip Kaufmann 7de3f1cfd6 fix help message for RPC getpeerinfo 2014-07-17 15:10:29 +02:00
Gregory Maxwell c4a321f5c6 Add peerid to getpeerinfo to allow correlation with the logs.
This seems to have been missed in 3764.
2014-07-15 07:13:10 -07:00
Pieter Wuille dc942e6f27 Introduce whitelisted peers.
This adds a -whitelist option to specify subnet ranges from which peers
that connect are whitelisted. In addition, there is a -whitebind option
which works like -bind, except peers connecting to it are also
whitelisted (allowing a separate listen port for trusted connections).

Being whitelisted has two effects (for now):
* They are immune to DoS disconnection/banning.
* Transactions they broadcast (which are valid) are always relayed,
  even if they were already in the mempool. This means that a node
  can function as a gateway for a local network, and that rebroadcasts
  from the local network will work as expected.

Whitelisting replaces the magic exemption localhost had for DoS
disconnection (local addresses are still never banned, though), which
implied hidden service connects (from a localhost Tor node) were
incorrectly immune to DoS disconnection as well. This old
behaviour is removed for that reason, but can be restored using
-whitelist=127.0.0.1 or -whitelist=::1 can be specified. -whitebind
is safer to use in case non-trusted localhost connections are expected
(like hidden services).
2014-07-09 20:40:14 +02:00
Philip Kaufmann 0127a9be14 remove SOCKS4 support from core and GUI
- now we support SOCKS5 only
2014-07-07 08:15:14 +02:00
Gavin Andresen 13fc83c77b
Move fee policy out of core 2014-07-03 14:42:16 -04:00
Pieter Wuille aa81564700 Track peers' available blocks 2014-06-29 21:50:55 +02:00