Bitcoin Blockchain Forked By Backward-Compatibility Issue 351
Posted
by
Unknown Lamer
from the blame-california dept.
from the blame-california dept.
New submitter jhantin writes "The Bitcoin blockchain has forked due to a lurking backward-compatibility issue: versions older than 0.8 do not properly handle blocks larger than about 500k, and Slush's pool mined a 974k block today. The problem is that not all mining operations are on 0.8; blocks are being generated by a mix of several different versions of the daemon, each making its own decision as to which of the two forks is preferable to extend, and older versions refuse to honor or extend from a block of this size. The consensus on #bitcoin-dev is damage control: miners need to mine on pre-0.8 code so the backward-compatible fork will outgrow and thus dominate the compatibility-breaking one; merchants need to stop accepting transactions until the network re-converges on the backward-compatible fork of the chain; and average users can ignore the warning that they are out of sync and need to upgrade."
Turns out there's an approximately 512K limit to atomic updates in Berkeley DB which were used by versions prior to 0.8. 0.8 uses a new database, allowing blockchains that old versions won't accept to be created.
sorry, a bug eat your money! (Score:2, Insightful)
OTOH, it was a really big bug
Re:consensus should be put into specification (Score:4, Insightful)
Re:Gobble bobble wobblywob? (Score:1, Insightful)
Actually I think most of Slashdot's readership understands it perfectly. And if they don't, they probably don't care about the article anyway. This isn't a newspaper.
Re:Gobble bobble wobblywob? (Score:4, Insightful)
Nice explanation. Now can you explain why exactly is the preferred solution to revert to the old, flawed, code rather than updating everything to the newer code that can properly handle the larger transactions?
Re:Gobble bobble wobblywob? (Score:5, Insightful)
It's not the preferred solution.
The value of the currency is in the people who use it and most major exchanges have already reverted to 0.7, hence 0.7 blockchains are the de-facto standard at the moment. There was a bit of back-and-forth when the problem was discovered but all the large exchanges have settled on 0.7 as the standard for now.
It's like saying we're going to upgrade the dollar, and yet nobody moves to the "new dollar". The new dollar ends up valueless and everyone just stays on the old one.
The client fix is to accept large transactions but not create them - there's already code in a lot of BitCoin software to do that, but not all clients are running it - someone now has to force them to upgrade to a good version in order to stay compatible, and a lot of people might be generating coins that will later fail without knowing it.
Re:Ooh, exciting! (Score:4, Insightful)
I tend to think of fiat currencies as being on the 'lead standard', with their reality largely measured by how many guys with guns are available to uphold them. USD, among others, passes the test.
Best to figure this out now ... (Score:2, Insightful)
Just wait until countries start pulling out of the EU.
Then we'll have a real currency backwards-compatibility problem!
Re:Ooh, exciting! (Score:4, Insightful)
Currencies are as real as your ability to spend them. By that standard, USD is very real and Bitcoin is not.
Re:Gobble bobble wobblywob? (Score:5, Insightful)
"except for miners who lost their reward for mined blocks on the abandoned (v 0.8) chain."
Which currently amounts to about $25,000 of BitCoins, last I heard. That's $25,000 of BitCoins that might have been spent, sent, transferred, etc. but never existed in the chosen chain and the knock-on effects on your own wallet if you're dealt with someone who dealt with someone who dealt with someone.... (ad infinitum) ... who dealt with one of those mined blocks.
Sure, it'll "catch up", but saying nobody lost out is plainly false. And isn't the point of BitCoin that everyone is a miner in some small way?
Re:Gobble bobble wobblywob? (Score:4, Insightful)
Yes. At some point everyone will have to upgrade to 0.8 and people who don't will effectively be disconnected from the system. However that needs some kind of co-ordination. The fact that there was a chain split is not the emergency, the fact that it came unexpectedly was the problem.
Re:So much for being based on crypto (Score:4, Insightful)
It's worth noting, that Berkeley DB (the one with the weird limits) was already replaced. The problem is that not enough users have upgraded to the replacement yet, and it's better to match their brokenness than diverge unexpectedly. They'll have to upgrade sooner or later though.
Re:Gobble bobble wobblywob? (Score:3, Insightful)
Miners don't have access to their reward for 120 blocks, so they never had them in the first place. The rewards will instead go to the miners in the new chain. Again, no coins are lost.
Re: Was an issue for about four hours yesterday (Score:4, Insightful)
The very first words on their website state quite clearly that Bitcoin is an _experimental_ currency. If people choose to use it as more than that, that's their fault. Finding issues like this is exactly what Bitcoin's current purpose is.
This type of problem was solved a long time ago (Score:3, Insightful)
This sort of thing was solved a long time ago, but because it's "old", people just dismiss it out of hand.
It's called versioning the protocol and having compatibility lists. When two clients connect, they exchange version numbers and if one is too old then the newer one performs additional checks to verify compatibility. If the issue is reconcilable then it aborts the connection with an error. Or programatically enforce that the older version is discontinued and that anyone who is using it can no longer participate in the chain.
I apologize if I sound exasperated and holier than thou... actually, no, I don't. How the hell do people design a system that they intend to be the backbone of a major financial system but fail to accommodate for such things? It is nothing short of stupidity and incompetence.
If a major bank tried to pull this sort of nonsense, they'd be bankrupt so fast that the stockholders would have whiplash.
Re:So much for being based on crypto (Score:4, Insightful)
Do you even know what "crypto" means? How is that in any way related to the database chosen in the implementation?
Usually, cryptosystems do not rely on things like the maximum size of atomic transactions in a database to work or to be secure in the abstract sense; it seems that in the case of Bitcoin, that is exactly what happened. This bug is not some kind of side channel attack (e.g. as you saw with Skype, where the cryptosystem was theoretically secure but where the implementation had an easily exploited side channel), it is not an implementation that leaves a secret key in some publicly accessible place, it is not a failure to properly implement the abstract cryptosystem. This is a cryptosystem whose security depends on specific implementation details.
To put it another way, imagine if instead of the database implementation, it was the CPU architecture that determined the security of the system. As long as everyone uses x86, it is fine, but if a few people start using ARM or PowerPC the system "forks." Would you trust such a system? What differentiates that hypothetical scenario from the database issue?
Re:Ooh, exciting! (Score:5, Insightful)
Just ask yourself what Ayn Rand would do in the same situation.
Die in penniless poverty while dependent on the state to provide basic income and medical facilities that are necessary to maintain her life, all while maintaining that such a system is inherently evil? It's what I like to think of Ayn Rand doing in *any* situation.
Re:So much for being based on crypto (Score:4, Insightful)
Re:Ooh, exciting! (Score:5, Insightful)
Re:For those, like me, reading this and saying wtf (Score:5, Insightful)
Re:So much for being based on crypto (Score:5, Insightful)
A cryptographic currency system needs to be secure regardless of how it is implemented
That's kind of an impossible standard, don't you think?
Re: Was an issue for about four hours yesterday (Score:4, Insightful)
You misunderstand the parent post. There was no outage -- transactions were processed as normal during the event. Only miners (i.e. people running the network for the random chance of being rewarded as recipient of newly created coins) may have lost out due to the error. Events like this were anticipated in the design, and the system has an automatic method of resolving it, which unfortunately leaves some miners out of pocket, but has no effect on general users.
Re:Old news. (Score:5, Insightful)
You laugh, but some of the developers, the lead developer Gavin, and another core developer Mike Hearn, are pushing really hard to get the current 1MB limit (7 transactions/second) on blocks lifted so Bitcoin can directly scale to VISA-like volumes.
Never mind that Bitcoin is inherently an unscalable O(n^2) network - every transaction has to be broadcast to every node - and the issue they ran into was also a problem scaling. Mike's solution is to just throw thousands of dollars worth of hardware [bitcoin.it] at the problem. Never mind that for Bitcoin *any* issue the means that some nodes can process a large block, and some can't, turns into the same hard-fork we just saw. Never mind that it will make Bitcoin centralized, and lead to perverse incentives [bitcointalk.org] for large miners to attack smaller ones.
You'd think they'd say "OK, hold on, how about we just use ways to transfer funds that don't have to go into this shared state ball of mess?" but no, they're desperate to take the easy way out at any cost.
I really wonder if my Bitcoins will be worth anything in a few years.
Can we stop bitcoin stories? (Score:1, Insightful)
Bitcoins are used to buy drugs and illegal pornography. That is their primary application.
Let's not have Slashdot cater two of the most worthless communities to ever exist.
Re:Ooh, exciting! (Score:2, Insightful)
Yeah, right. If it was profitable to mine BTC then the people making BTC mining hardware would operate it, not sell it.
And yet the makers of oil, natural gas, coal, silver and gold mining equipment sell their equipment and don't operate it.
Re:Ooh, exciting! (Score:4, Insightful)
Just what would happen if the great and powerful architect decides to go it alone? Well, the bricklayer, the carpenter, the plumber, and the electrician build some houses following the well developed rules of thumb and then go have some beers while laughing at the architect as he tries to figure out how to rivet....
Re:Old news. (Score:4, Insightful)
Never mind that Bitcoin is inherently an unscalable O(n^2) network - every transaction has to be broadcast to every node
It may be possible to store the block chain as a distributed hash tree such that each node is responsible for maintaining its own transactions and a portion of the block chain. This would reduce the storage requirement to O(n*m) where n is the total number of transactions and m is the average number of addresses that appear in a transaction. Communication would also be reduced to O(n*m) because only nodes responsible for the addresses in a transaction would be responsible for checking and approving the transaction. The block chain itself would just be a merkle-tree of hashes of nodes' own block chains. Double-spending would be prevented by transactions incorporating the last hash of each responsible node's block chain so that an individual block chain exhibiting double spending would not be signed into the merkle tree. It would be possible for the history of particular coins to be lost but the overall hash tree would guarantee that at the time of a transaction all balances (including historically lost ones) were valid. Still, not being able to validate the entire economy could be a fairly large weakness. There wouldn't be a hard requirement that nodes could only store certain addresses, so it's entirely possible that some nodes would still try to collect and maintain the entire history. That would only add O(n*p) communication and storage where p is the number of full "archive" nodes. Of course then it wouldn't really be bitcoin anymore, but it might be possible to rebuild the existing block chain into such a structure while retaining the current mining payouts and total number of coins.
I really wonder if my Bitcoins will be worth anything in a few years.
Something, because there will always be some core of crazy people running miners and keeping the difficulty just high enough that it's not worth it to mine as many bitcoins as you want in the original chain. That value will probably be the cost of the electricity to run whatever the last ASIC miner produced is, at least before general purpose GPUs become more powerful than ASICs.