aboutsummaryrefslogtreecommitdiff
path: root/src/bitcoinrpc.cpp
Commit message (Collapse)AuthorAgeFilesLines
* bitcoinrpc.cpp: Removed outdated commentJeff Garzik2012-07-051-4/+0
| | | | Fixes #1373
* Use unsigned ints to fix signed/unsigned warningsGavin Andresen2012-07-051-1/+1
|
* Implement raw transaction RPC callsGavin Andresen2012-07-051-43/+23
| | | | | | Implement listunspent / getrawtransaction / createrawtransaction / signrawtransaction, to support creation and signing-on-multiple-device multisignature transactions.
* RPCTypeCheck method to make type-checking JSON Arrays easier.Gavin Andresen2012-07-051-0/+37
|
* Rework gettransaction / getblock RPC callsGavin Andresen2012-07-051-264/+28
| | | | | | | | | | | | | | | | | | | | | | This PULL reworks new (post-0.6.*) features of the gettransaction/getblock RPC calls as follows: It removes the 'decompositions' object argument from getblock, replacing it just a list of transaction hashes; equivalent (I believe) of passing the {"tx":"hash"} decomposition. It replaces the 'decompositions' object argument of gettransaction with a boolean flag; if true, returns the same stuff that the {"script":"obj"} decomposition would return (txins/txouts as hex, disassembled, and bitcoin addresses). It adds a "rawtx" field to the output of gettransaction, that is the entire transaction serialized and hex-encoded. It removes the "size" field from gettransaction, since the size is trivial to compute from the "rawtx" field (either take the length after hex-decoding, or just compute it as hex-length/2).
* RPC: add support for JSON-RPC 2.0-style request batchingJeff Garzik2012-07-031-5/+49
| | | | | | | | | If the top-level object is an array, it is assumed to be an array of JSON-RPC requests. An array is returned, containing one response (error or not) per request, in the order submitted. In a slight change in semantics, batched requests -always- return an HTTP 200 OK status, even ones full of invalid or incorrect requests.
* RPC: break out high level JSON-RPC req/resp into their own functionsJeff Garzik2012-07-031-30/+55
| | | | This prepares for JSON-RPC 2.0 batches.
* RPC: add 'getpeerinfo', returning easy-to-retrieve per-CNode dataJeff Garzik2012-06-291-0/+2
|
* Create new rpcnet module, and move 'getconnectioncount' RPC to itJeff Garzik2012-06-281-11/+1
|
* Fix build error.Matt Corallo2012-06-281-1/+1
|
* Lock vnThreadsRunning[THREAD_RPCHANDLER].Matt Corallo2012-06-281-3/+14
|
* Use a rpc-specific queue to tell asio connections to shutdown.Matt Corallo2012-06-281-2/+5
|
* Revert "*Always* send a shutdown signal to enable custom shutdown actions"Matt Corallo2012-06-281-1/+2
| | | | This reverts commit 896899e0d66e25f6549a92749d237c8a87b12f08.
* Cancel outstanding listen ops for RPC when shutting downGiel van Schijndel2012-06-241-31/+26
| | | | | | | Use Boost's signal2 slot tracking mechanism to cancel any (still open) listening sockets when receiving a shutdown signal. Signed-off-by: Giel van Schijndel <[email protected]>
* Merge branch 'master' into async-ipv6-rpcGiel van Schijndel2012-06-241-0/+18
|\
| * RPC: add 'getrawmempool', listing all transaction ids in memory poolJeff Garzik2012-06-221-0/+18
| |
* | *Always* send a shutdown signal to enable custom shutdown actionsGiel van Schijndel2012-06-171-2/+1
| | | | | | | | | | | | | | NOTE: This is required to be sure that we can properly shut down the RPC thread. Signed-off-by: Giel van Schijndel <[email protected]>
* | Merge branch 'master' into async-ipv6-rpcGiel van Schijndel2012-06-171-129/+133
|\| | | | | | | | | | | | | Conflicts: src/bitcoinrpc.cpp Signed-off-by: Giel van Schijndel <[email protected]>
| * introduce a new StartShutdown() function, which starts a thread with ↵Philip Kaufmann2012-06-121-7/+7
| | | | | | | | Shutdown() if no GUI is used and calls uiInterface.QueueShutdown() if a GUI is used / all direct uiInterface.QueueShutdown() calls are replaced with Shutdown() - this ensures a clean GUI shutdown, even when catching a SIGTERM and allows the BitcoinGUI destructor to get called (which fixes a tray-icon issue and keeps the tray-icon until Bitcoin-Qt exits)
| * Merge branch 'netopt' of https://github.com/sipa/bitcoinGavin Andresen2012-06-041-1/+4
| |\
| | * Rework network config settingsPieter Wuille2012-05-311-1/+4
| | |
| * | Use ConvertTo to simplify sendmany/addmultisigaddress argument handlingGavin Andresen2012-05-311-18/+5
| | |
| * | Make sendrawtx return txid to be consistent with other send methods.Gavin Andresen2012-05-311-1/+1
| |/
| * Refactor: split CKeyID/CScriptID/CTxDestination from CBitcoinAddressPieter Wuille2012-05-241-93/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces internal types: * CKeyID: reference (hash160) of a key * CScriptID: reference (hash160) of a script * CTxDestination: a boost::variant of the former two CBitcoinAddress is retrofitted to be a Base58 encoding of a CTxDestination. This allows all internal code to only use the internal types, and only have RPC and GUI depend on the base58 code. Furthermore, the header dependencies are a lot saner now. base58.h is at the top (right below rpc and gui) instead of at the bottom. For the rest: wallet -> script -> keystore -> key. Only keystore still requires a forward declaration of CScript. Solving that would require splitting script into two layers.
| * Encapsulate public keys in CPubKeyPieter Wuille2012-05-241-10/+10
| |
* | Use the QueueShutdown signal to stop accepting new RPC connectionsGiel van Schijndel2012-05-251-7/+7
| | | | | | | | Signed-off-by: Giel van Schijndel <[email protected]>
* | Allow all addresses on the loopback subnet (127.0.0.0/8) not just 127.0.0.1Giel van Schijndel2012-05-251-1/+4
| | | | | | | | Signed-off-by: Giel van Schijndel <[email protected]>
* | Generalise RPC connection handling code to allow more listening socketsGiel van Schijndel2012-05-251-43/+97
| | | | | | | | | | | | | | | | Using this modification it should be relatively easy to, at a later time, listen on multiple addresses (even Unix domain sockets should be possible). Signed-off-by: Giel van Schijndel <[email protected]>
* | Allow clients on the IPv6 loopback as wellGiel van Schijndel2012-05-251-3/+12
| | | | | | | | Signed-off-by: Giel van Schijndel <[email protected]>
* | Add dual IPv4/IPv6 stack support to the RPC serverGiel van Schijndel2012-05-251-19/+44
| | | | | | | | | | | | | | | | | | | | | | The RPC server now listens for, and handles, incoming connections on both IPv4 as well as IPv6. If available (and usable) it uses a dual IPv4/IPv6 socket on systems that support it (e.g. Linux and BSDs) and falls back to separate IPv4/IPv6 sockets on systems that don't (e.g. Windows). Signed-off-by: Giel van Schijndel <[email protected]>
* | Use asynchronous I/O to handle RPC requestsGiel van Schijndel2012-05-251-38/+82
|/ | | | | | | | | | This allows more flexibility in the RPC code, e.g. making it easier to handle multiple simultaneous connections later on. Currently asynchronous I/O is only used to listen for and accept incoming connections. Asynchronous reading/writing is more involved. Signed-off-by: Giel van Schijndel <[email protected]>
* JSON-RPC: Add 'sendrawtx' op, for sending pre-built TX's to networkJeff Garzik2012-05-231-0/+35
|
* Merge pull request #1354 from fanquake/masterPieter Wuille2012-05-201-1/+1
|\ | | | | Update Header Licenses
| * Update License in File HeadersFordy2012-05-181-1/+1
| | | | | | | | | | | | I originally created a pull to replace the "COPYING" in crypter.cpp and crypter.h, but it turned out that COPYING was actually the correct file.
* | Make testcases build, prevent windows symbol collisionWladimir J. van der Laan2012-05-201-2/+2
| |
* | Convert UI interface to boost::signals2.Wladimir J. van der Laan2012-05-201-8/+8
| | | | | | | | | | | | | | | | - Signals now go directly from the core to WalletModel/ClientModel. - WalletModel subscribes to signals on CWallet: Prepares for multi-wallet support, by no longer assuming an implicit global wallet. - Gets rid of noui.cpp, the few lines that were left are merged into init.cpp - Rename wxXXX message flags to MF_XXX, to make them UI indifferent. - ThreadSafeMessageBox no longer returns the value `4` which was never used, converted to void.
* | Merge pull request #1358 from luke-jr/shared_lockchkPieter Wuille2012-05-191-35/+31
|\ \ | | | | | | Shared code for wallet lock help and check
| * | Shared code for wallet lock help and checkLuke Dashjr2012-05-181-35/+31
| | |
* | | change strings to Bitcoin (uppercase), where it is used as a noun and update ↵Philip Kaufmann2012-05-181-13/+13
|/ / | | | | | | strings to use "Qt" (and not qt or QT) / update initialisation of notificator to use qApp->applicationName() instead of a static string
* / JSON-RPC: remove 'getblocknumber' deprecated RPCJeff Garzik2012-05-171-17/+1
|/ | | | RPC 'getblockcount' should be used instead.
* Merge pull request #1334 from rebroad/Exiting2ExitedJeff Garzik2012-05-171-1/+1
|\ | | | | Corrected grammar. As per Principle Of Least Surprise.
| * Corrected grammar. As per Principle Of Least Surprise.R E Broadley2012-05-171-1/+1
| |
* | Always check return values of TxnBegin() and TxnCommit()Jeff Garzik2012-05-141-2/+4
|/
* Fix warning about uninitialized valuePieter Wuille2012-05-131-1/+1
| | | | Only reported when using -flto.
* convert 4 tabs into 4 x 4 spaces in bitcoinrpc.cppPhilip Kaufmann2012-05-121-5/+5
|
* Merge pull request #1101 from jgarzik/http11Jeff Garzik2012-05-111-37/+97
|\ | | | | Multithreaded JSON-RPC with HTTP 1.1 Keep-Alive support
| * RPC: Support HTTP/1.0 and HTTP/1.1, including the proper use of keep-alivesDavid Joel Schwartz2012-05-081-12/+38
| |
| * Support multi-threaded JSON-RPCDavid Joel Schwartz2012-05-081-32/+66
| | | | | | | | | | | | | | | | | | | | | | Change internal HTTP JSON-RPC server from single-threaded to thread-per-connection model. The IP filter list is applied prior to starting the thread, which then processes the RPC. A mutex covers the entire RPC operation, because not all RPC operations are thread-safe. [minor modifications by jgarzik, to make change upstream-ready]
* | Kill warning from unavoidable signed/unsigned comparison in bitcoinrpc.cpp.Gregory Maxwell2012-05-091-1/+1
|/
* Support for decomposing scripts as "obj"Luke Dashjr2012-05-081-0/+74
|