HomePhabricator

Fix RPC signrawtransaction silently accepting missing amount field, make it…
425af746dfddUnpublished

Unpublished Commit · Learn More

Repository Importing: This repository is still importing.

Description

Fix RPC signrawtransaction silently accepting missing amount field, make it throw an error instead

Summary:
After hard fork, replay protected tx's require the amount field to be non-zero for previous outputs in signed tx's. JSON RPC code was accepting transactions with this field missing when it should have been throwing an error. Users had the impression the transaction that was signed was good, but when trying to sent to network, they would get an error that the tx is bad. See github issue https://github.com/Bitcoin-ABC/bitcoin-abc/issues/63.

Depends on D448

Test Plan:
Depends on D448

make check and also rpc-tests.py

Reviewers: #bitcoin_abc, sickpig, freetrader, dgenr8, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D449

Details

Provenance
CCulianuAuthored on Aug 10 2017, 11:33
schancelPushed on Jan 5 2018, 21:58
schancelPushed on Jan 5 2018, 21:39
schancelPushed on Jan 5 2018, 21:17
Reviewer
Restricted Project
Differential Revision
D449: Fix RPC signrawtransaction silently accepting missing amount field, make it throw an error instead
Parents
rSTAGINGd68e7e48547c: Peer preferentially with NODE_CASH nodes
Branches
Unknown
Tags
Unknown