From 6e71efa9f020ee0a2b8050e8643deb03022b0b38 Mon Sep 17 00:00:00 2001 From: Jonas Schnelli Date: Wed, 27 May 2015 15:56:16 +0200 Subject: [REST] remove json input for getutxos, limit to query max. 15 outpoints Remove possibility to send json encoded parameters to `/rest/getutxos/` to avoid possible DoS scenarios. The JSON output option is untouched. --- doc/REST-interface.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'doc') diff --git a/doc/REST-interface.md b/doc/REST-interface.md index 0b718d664e..2219ceb65f 100644 --- a/doc/REST-interface.md +++ b/doc/REST-interface.md @@ -47,7 +47,7 @@ Only supports JSON as output format. * chainwork : (string) total amount of work in active chain, in hexadecimal ####Query UTXO set -`GET /rest/getutxos.` +`GET /rest/getutxos//-/-/.../-.` The getutxo command allows querying of the UTXO set given a set of outpoints. See BIP64 for input and output serialisation: @@ -55,7 +55,7 @@ https://github.com/bitcoin/bips/blob/master/bip-0064.mediawiki Example: ``` -$ curl --data '{"checkmempool":true,"outpoints":[{"txid":"b2cdfd7b89def827ff8af7cd9bff7627ff72e5e8b0f71210f92ea7a4000c5d75","n":0}]}' localhost:18332/rest/getutxos.json 2>/dev/null | json_pp +$ curl localhost:18332/rest/getutxos/checkmempool/b2cdfd7b89def827ff8af7cd9bff7627ff72e5e8b0f71210f92ea7a4000c5d75-0.json 2>/dev/null | json_pp { "chaintipHash" : "00000000fb01a7f3745a717f8caebee056c484e6e0bfe4a9591c235bb70506fb", "chainHeight" : 325347, -- cgit v1.2.3