News for hackers. Stuff that matters.
Re:Bitcoin transaction processing takes up to 10 hours by pash on Saturday March 05, 2016 @07:14PM (#11231794)
Your understanding of soft forks is incorrect. Changes to the consensus rules implemented by soft forks are in no way optional, nor are they backwards-compatible [0].

Nor are soft-forking changes meaningfully more limited in scope than hard-forking changes. Soft forks, by introducing new rules referring to data unreferenced by the old rules, can be used to make almost arbitrary changes to the protocol. Bitcoin Core's planned implementation of segregated witness uses this technique, which is how it is able effectively to loosen the constraint on block sizes. The technique can be extended to implement an arbitrary increase in the blocksize as a soft fork [1], or even to change the rule that limits the final supply of bitcoin to 21 million units [2]. Name a change you want to make to the consensus rules: chances are that with enough cleverness (and a willingness to make a big enough mess) you can find a way to implement it as a soft fork.

The most salient consequences of changing consensus rules by soft fork versus by hard fork, to my mind, are that (a) soft-forking changes ordinarily introduce substantial additional complexity compared to effecting the same change with a hard fork, and (b) developers can introduce changes via soft forks without having to secure the same degree of explicit consent from miners and users that hard forks require.

Phenomenon (a) occurs because soft-forking changes must be implemented by roundabout mechanisms that preserve formal (but not semantic) compatibility with the old rules, whereas hard forks provide the freedom to make changes in the simplest or most technically appropriate way. Point (b) perhaps helps to explain the preference of Bitcoin Core's team for soft-forking changes: they are less constrained by the desires of users and miners under a policy of implementing changes to the consensus rules by soft fork than they would be if they were to attempt the same changes with hard forks.

0. https://medium.com/@octskyward/on-consensus-and-forks-c6a050...

1. https://bitcointalk.org/index.php?topic=1296628.0

2. https://np.reddit.com/r/bitcoin_uncensored/comments/43w24e/r...

Edit: I encourage interested readers to verify what I have written by referring to the sources I cited or by doing their own research. Downvotes in discussions of Bitcoin here unfortunately tend to reflect the voters' loyalties in the blocksize brouhaha more than their honest assessment of whether a comment is informative and correct.

Re:Bitcoin transaction processing takes up to 10 hours by makomk on Sunday March 06, 2016 @04:38AM (#11233074)
No, you cannot "change the rule that limits the final supply of bitcoin to 21 million units" through a softfork. You can indeed append an "extension record" with "extension transactions" that generate and transfer whatever number of extension coins you like as https://np.reddit.com/r/bitcoin_uncensored/comments/43w24e/r... lays out, but you can never ever convert those extension coins into ordinary Bitcoins that existing nodes accept as valid. You've basically created a very elaborate altcoin as a sidechain of Bitcoin.

This is not the technique that segregated witness uses. All SegWit transactions are on-chain transactions that are visible to existing clients, which means that the coin cap and all the other Bitcoin rules still apply and the coins from them can subsequently be sent to non-SegWit clients - the only thing that's not available to older nodes is the information about who's allowed to spend SegWit transactions. It's similar to the P2SH fork a few years back in that respect. (That's also why the effective block size gain is limited. Any further increases are planned to be done through a hard fork.)

Now, technically of course 51%+ of miners could refuse to accept standard Bitcoin transactions of any kind and force everyone onto their extension chain. In fact, they could even declare a day zero after which they refused to accept any existing transactions or coins as valid, resetting the whole thing as an extension chain. This is an unavoidable consequence of miners being able to decide which valid transactions they accept - Bitcoin simply relies on the majority of miners not trying to shut the whole thing down.

Re:Bitcoin transaction processing takes up to 10 hours by pash on Sunday March 06, 2016 @04:04PM (#11235532)
Yes, you're right, but again only in a formalistic sense. It is the semantics of the rules that matter, not their form. And the semantics can be changed arbitrarily in the way I described. I don't think my point is pedantic. Segregated witness is just this sort of change, one that preserves the form of the old rules while significantly reinterpreting their meaning.

No, segregated witness doesn't change the semantics as drastically as, say, changing the effective cap on the final supply of monetary units. But that's beside the point—which is that it is wrong to think of soft-forking changes as intrinsically less significant or more acceptable than hard-forking changes. You can effectively change anything with either approach. To judge a change to the consensus rules, you must look at its semantics: whether it is implemented as a soft fork or a hard fork tells you essentially nothing.

Yet a large chunk of the Bitcoin community seems to believe that soft forks should be preferred to hard forks as a matter of principle. That is nonsense.

Re:Bitcoin transaction processing takes up to 10 hours by ikeboy on Saturday March 05, 2016 @07:55PM (#11231928)
Optional and backward compatible in the sense that old nodes continue to work and recognize the new block chain as valid.

Core prefers soft forks because they're less risky, and don't require all users to upgrade, only minors.

Re:Bitcoin transaction processing takes up to 10 hours by pash on Saturday March 05, 2016 @08:28PM (#11232038)
Old nodes continue to work only in a trivial sense: after a soft-fork, they can no longer properly interpret the meaning of data in the blockchain, so their ability to validate new transactions has been destroyed. If Bitcoin Core's soft fork to introduce segregated witness proceeds, for example, nodes that are not upgraded (and so have no understanding of the witness data) will happily interpret all seg-wit transactions as valid, whether they really are or not.

For this reason, some people view soft forks as insidious in a way that hard forks are not: the sole purpose of a Bitcoin node is to interpret data contained in the blockchain and in newly broadcast transactions to determine the validity of those transactions under a particular ruleset, and a soft-fork is a subterfuge specifically designed to make some of those nodes unaware that their ability to perform that function has been destroyed.

If soft forks are "less risky", it is precisely for that reason: soft forks ensure that the nodes of miners and users who do not explicitly consent to a rule change fail even to notice that the rules have changed!

Re:Bitcoin transaction processing takes up to 10 hours by ikeboy on Saturday March 05, 2016 @08:47PM (#11232093)
Firstly, not all soft forks introduce extra data. Some are simply about minor policy.

Second, soft forks have been the standard since the beginning, and everyone understands that minors can set their own rules.

Third, non upgraded nodes, if they follow the longest chain, do not break. If they mine themselves they'll get orphaned, but that doesn't break them as long as they wait for a couple of blocks before accepting transactions as valid.

Fourth, soft forks have traditionally repurposed non standard transactions, which shouldn't be issued by anyone expecting consistent behavior. Segwit uses anyone-can-spend which are non standard, and as the bip says "Wallets should always be wary of anyone-can-spend scripts and treat them with suspicion."

Fifth, anyone can "notice" by virtue of the block header changing. A majority of minors can reject transactions, that's not deceitful in any way.

Re:Bitcoin transaction processing takes up to 10 hours by ikeboy on Saturday March 05, 2016 @08:30PM (#11232047)
I do want to thank you for pointing out that many changes can be done with a soft fork, which I hadn't seen before. That got an upvote from me.

Some of those changes seem like they'd require users cooperation as well, though. The "meaning" of the extra data would only be useful by those that decide to acknowledge it.

I'm wondering if it might be a better idea in general to do all future changes as soft forks. Is anyone arguing this?

Re:Bitcoin transaction processing takes up to 10 hours by DCPOS_Anthony on Sunday March 06, 2016 @06:41AM (#11233404)
I don't know of a single responsible bitcoin developer that wouldn't prefer using soft-forks to hard-forks. Bitcoin has had hard-forks in the past, but they have been done in response to a specific issue, and were done very quickly. What's most important, everyone agreed that the hard-fork had to be done.

The current attempt by Coinbase to force a contentious hard-fork is dangerous. There are many people that even question its requirement, let alone whether it can be done safely.

I'm not saying it's not going to happen, but it isn't going to be done quickly, and if it is finally going to happen, it'll be managed by the core developers.