Friday, August 16, 2013

A Bilateral Hostage via Bitcoin

In "From Imperial China to Cyberspace: Contracting Without the State" I discussed the problem of contracts without court enforcement in the context of past practice in Imperial China and future practice online. There are at least two ways of doing it.

One is to rely on reputation. If both parties have sufficiently valuable reputations there is no problem, since the loss to either of being known to have broken its contract is more than the gain from doing so. All you have to do is to arrange things so that if one party does break the contract, the other can easily prove the fact to interested third parties. If only one party has a valuable reputation, the contract can be structured so that only that party has the opportunity to gain by failing to fulfill its obligations—most obviously, having the other party pay in advance. If neither party has a reputation, they can use a third party who does, an escrow agent or equivalent, to enforce the contract.

The other solution is to structure the contract in such a way that a party is always worse off pulling out than carrying his obligations to completion. In building a house, for instance, if the purchaser pays in advance the builder can pocket the money and leave. If the purchaser pays on completion, he can insist on "renegotiating" the price at that point. They solve the problem by a schedule of payments made as the house is built.

This may be difficult or impossible to do in a world of uncertainty, since we may not be able to predict how much a party will gain by fulfilling the contract or, alternatively, failing to do so. We can make reneging more costly to one party by having him put down a deposit in advance which the other can seize if the contract is not fulfilled. But doing so increases the incentive to the other party to reneg, since if he breaks the contract he can keep the deposit—all of this is happening in a world without courts to make him give it back. A solution to that problem is to replace the deposit with a hostage—something valuable to the party who gives it but not to the party who holds it. If I break the contract you destroy the hostage, but you cannot gain by yourself breaking the contract and holding the hostage. 

Someone recently pointed me at a blog post proposing an elegant bilateral version of the hostage solution: "Contracts Without Trust and Third Parties", by Oleg Andreev. It is a very simple idea. I make a contract with you which gives you the opportunity to cheat me out of ten dollars, perhaps by accepting an online payment but not delivering the goods or services paid for.  Before making the payment, we use bitcoin technology to deposit twenty dollars each in a form that is locked against both of us unless each of us releases it. If you never deliver the goods I refuse to unlock the deposit. I am worse off as a result but so are you, which is a good reason for you to fulfill your half of the contract.

My daughter, reading a draft of my article, pointed out a problem with the hostage solution. The hostage I deposit with you may be of no use to you but it is valuable to me, so after you break the contract you sell the hostage back to me for some substantial fraction of its value. The same problem exists for Andreev's proposal. After you fail to deliver the goods, you point out to me that leaving our deposit forever unclaimed hurts me as well as you, unlock your side of it, and wait for me to unlock mine.

Nonetheless, hostage have, historically, been used to guarantee fulfillment of promises in a variety of contexts, perhaps in part because selling my hostage back to me is a bilateral monopoly transaction with potentially high transaction costs and uncertain outcome, perhaps in part because someone who has just been cheated may be willing to accept a cost to punish the person who cheated him.

I have one improvement to offer to Andreev's scheme, in order to eliminate the deadweight cost of deposits that are never unlocked. Arrange that if the deposit is not unlocked after (say) ten days, it forfeits to a third party. Sell the right, in advance, to be that third party.

19 comments:

Tibor said...

I think it is not a good strategy in the long term to accept the essential extortion by the party who points out that it pays you both to unlock the account (or tries to sell back the hostage). If you do this a couple of times, you get a reputation of being someone others can cheat. Otherwise, you gain a reputation of a "tough guy" who cannot be cheated (at least not at a profit). It is like the example you give about Falklands in Machinery. It would perhaps be less expensive for the UK to give up those useless islands (by the way something similar happened rather recently between China and Japan, although it did not escalate into open military conflict...few Japanese embassies burned down in China though I think). But they would then build up a reputation of someone who is easy to poke. It is true though, that you may still lose a few times before you build the reputation unlike when you choose the escrow option...which seems to me to be a better solution to the problem anyway (at least once there is anyone at all who already has reputation...and there are such agents today already, so that is really only a theoretical constraint).

Roman said...

Yes, as Tibor pointed out, unfortunately, it might not be a good idea to transfer money to a third party. A lot more possibilities for fraud arise from such a scheme. This might be a solution if a third party has more to lose for cooperating with one side of the deal, however such a third party may not always be found and agreed upon. Thus, the point of the idea is to solve the problem by purely technical means. That's why the most reliable way is to destroy the collateral altogether.

Raphfrk said...

Another system where money is "locked" is the "micro-payment channels" system.

Alice creates 2 transactions

"Pay 1 BTC from Alice to account X, spendable by Bob & Alice (2 of 2)"

and

"Pay 1 BTC from account X to Alice, in 24 hours".

Alice sends the 2nd transaction to Bob. Bob signs it and sends it back.

Alice signs it giving "Pay 1 BTC from X to Alice, in 24 hours, signed Bob & Alice". This is called the "refund" transaction.

She knows that she can spend the funds in X (granted after 24 hours), so she submits the first transaction to the network.

This "locks" her money into the X account. If she submits her refund transaction, it will be ignored for 24 hours.

If X is empty by then, then it will also be ignored.

Alice can now send money to Bob without needing to deal with the bitcoin system at all.

She sends "Pay 0.001BTC to Bob and 9.999 BTC to Alice from X, signed Alice" to Bob.

He can sign the transaction and submit it (since spending X needs both signatures). This "closes" the channel, and he gets 0.001 BTC and Alice gets 9.999 BTC.

However, he doesn't have to close the channel immediately.

Alice might be buying wireless LAN access. Every 5 mins, she sends another 0.001BTC (sending a transaction increasing Bob's share and decreasing her's).

When 20 hours have passed, Bob would close the channel.

Only 2 transactions would end up in the main bitcoin chain.

If Bob hasn't closed the channel after 24 hours, Alice can do it.

She has 2 options, she can use her time-locked refund transaction, and get the 10BTC back or use the last transaction she sent to Bob (and so pay).

Tibor said...
This comment has been removed by the author.
Tibor said...
This comment has been removed by the author.
Tibor said...

Roman: Actually, I was arguing for just that. What I meant was the situation when you and the partner who cheated have put money to some locked account that requires both of your keys to be opened. And I agued that in such situation it is better to sacrifice the "hostage" in order to gain a reputation of someone who does not accept extortion.

Also, I have no idea what you mean by "solving the problem by purely technical means".

jdgalt said...

It seems to me that the only good solutions to this problem are going to turn out to be new versions of the solutions already discussed.

What I'm getting at is, a society without a "government" in your sense of the word (one protected by a double standard) is going to have to develop one of the workarounds seen in places like Renaissance Italy (which was run by foreigners who didn't care what one Italian did to another). Assuming the people don't just create a traditional government, either they will develop what amount to private communities (such as the Jewish ghettos of the Middle Ages) -- which have the ability to banish and shun people, and thus have effective power over anyone who values belonging to one -- or they will form gangs to defend what they can, and turn into a feud society.

Without one or the other of these mechanism I see no real safety for anybody in such a system, unless you are powerful enough to declare your home an independent freehold and make it stick.

Anonymous said...

Where ever there is excess there will be arbitrage. So, the flaw is that in the somewhat likely event that one or the other party does not unlock the funds, a third party will appear to facilitate negotiation (or, perhaps assume the responsibilities of party who refuses to unlock the funds)...

...and that "authority" requires a state and lawyers.

Gordon said...

From David's paper: "In the figure, Party 1 is continuing to bear costs of performance from t=10 to t=20. Party 2 is no longer bearing costs of performance but is receiving benefits. So the gain to breach is falling for Party 1 but rising for Party 2."

It seems from the figure that the last sentence should read "loss from" rather than "gain to".

Anonymous said...

The third party could be a charity which both sides trust, something like the EFF or legal aid to whistleblowers may be popular among those using e-cash.

Dimitriy said...

If I am the cheated buyer, why would I cut off my nose to spite my face? It seems like the threat of locking up the $40 is not really credible since I stand to loose an additional $20, making my total losses $30? Is the revenge really worth that much for most people?

js290 said...

Wouldn't this problem with the hostage be resolved with a demurrage fee?

Tibor said...

Dimitriy: It is really not revenge you are buying if you refuse to open the account once you were cheated. It is the reputation of someone it does not pay to cheat...so that the next time, the chances someone will try to do just the same thing are lower. On the other hand, if you essentially submit to extortion and open the account, other potentional cheaters will see that as a signal that it is easy to push you around and will do so. So in the end, you may actually lose more money that way.

Of course there is another factor present - the cheaters harm their reputation when they cheat (provided that you tell others and you probably will), so it only pays off to cheat if the gain is greater than the reputational cost. But for parties that are not well-established, the reputational costs are negligeable. They don't have any good reputation yet and if their reputation falls too much, they can simply come up with a new company or a new entity in general and start from zero again. It is even easier online and especially with bitcoin, because you can create a new e-mail adress and a new bitcoin wallet in about 3 minutes, so essentially for free.

Dimitriy said...

I was missing that there was a repeated game element to this. That makes a bit more sense now.

Matthew Hammer said...

Tibor: I'll point out that by construction this is a scenario where neither party is much affected by reputation effects.

There are (as listed) other solutions when either or both parties have a reputation to maintain.

David Rosen said...
This comment has been removed by the author.
David Rosen said...
This comment has been removed by the author.
David Rosen said...

Instead of destroying the collateral, there can be an agreement to fall back to a third-party arbitrator as in a traditional third-party escrow. This gives all the benefits of third-party escrow with zero fees so long as it isn't necessary to go to arbitration.

With a tradational third-party escrow you would add (say) a 1% transaction cost, even if there is NO dispute, which partly nullifies one of the main benefits of cryptocurrency: near-zero transaction costs.

In fact, the amount of the mutual collateral can be just enough for the arbitration fee, even if this is less than the transaction amount. Thus you tie up less money, yet still give some incentive (not present for traditional escrow) to both parties to avoid arbitration, and you still have zero transaction/escrow costs in the (presumably more common) case in which no arbitration is needed.

Let's call this the "arbitration fee collateral" approach.

In traditional escrow, the escrow service charges an amount that assumes a particular dispute rate. They have to price it a little higher to compensate them for taking the risk that the average dispute rate ends up being much higher. This "third-party risk fee" doesn't exist in the present arbitration fee collateral approach.

The two parties themselves, who are in the best position to determine the risk of a dispute (e.g. potential disagreements over "condition" of used items), might decide to add additional collateral beyond the arbitration fee, and this additional amount might be awardable to one party by the arbitrator, for additional incentive to the other parto to avoid the additional expense of a dispute.

Or, the parties simply wouldn't enter into the "arbitration fee collateral" type of contract if they thought there was a too-high probability of dispute -- they could decide to use a traditional escrow service instead. Of course that could ultimately raise the dispute rate among those who choose to use escrow, causing escrow services to raise their fees, thus ultimately making the arbitration-collateral approach even more attractive to the parties.

David Rosen said...

Widely-used return policies might be considered lightweight variants of Andreev's bilateral-collateral-forfeit concept: if returns are accepted without restocking fees, the seller stands to lose the opportunity cost of foregoing selling the item after shipping it and not yet receiving it back, and the loss if they have to re-sell it as "open box", and their original shipping cost if their policy refunds the original shipping cost or if they sold it with "free shipping. The buyer loses their return shipping cost and any non-refundable original shipping charge. Andreev's scheme takes it further by making the collateral amounts greater than the amount of the transaction.

BTW, a reputation system can be used simultaneously with any of these hostage approaches, and it can include some objective information on previous transactions and their outcomes (e.g. success rate for mutual collateral return), as well as the usual subjective ratings given by each side.