[Bitcoin-development] BIP70 message delivery reliability

Roy Badami roy at gnomon.org.uk
Thu Jan 30 12:20:16 UTC 2014


On Thu, Jan 30, 2014 at 07:03:57PM +0700, Chuck wrote:
> On 1/30/2014 7:02 PM, Pieter Wuille wrote:
> > On Thu, Jan 30, 2014 at 12:59 PM, Mike Hearn <mike at plan99.net> wrote:
> >> With the way it works in bitcoinj, the tx is only committed to the wallet if
> >> the server accepts the Payment message and ACKs it. So the tx would not be
> >> retried if there's a failure submitting or some kind of internal server
> >> error, and the UI would show that the payment failed. That seems
> >> straightforward and how I'd expect things to work as a user.
> > That's one right way to do it imho, but not what is suggested or
> > required by the specification, and not what bitcoin core master
> > currently implements.
> >
> If you sent the Payment message and the server goes silent after 
> receiving it, you retry to delivery.  However, the merchant can 
> broadcast the transactions and force them into your wallet anyway. You 
> could, quite likely, pay and never get an ACK.

I think in that case, you absolultely have to invalidate all the
transactions in the Payment message by broadcasting a send-to-self
transaction as soon as possible; until that point your wallet balance
is indeterminate.  Otherwise what will happen if the merchant did in
fact receive the Payment message, and then processes it (and
broadcasts the transaction) after some delay?

Then what the user will see is: an apparently failed attempt to pay,
leaving their wallet balance unchanged.  Then, perhaps many hours
later, their wallet balance will appear to spontaneously decrement.

roy






More information about the bitcoin-dev mailing list