The Bitcoin malleability attack graphed hour by hour
righto.com
righto.com
When a transaction was rejected by the Bitcoin network that MtGox sent, the MtGox software would detect the rejection and immediately re-credit your account for the attempted transfer amount. MtGox also had an api that allowed you to see the exact contents of the transactions that they sent to the Bitcoin network. This meant that what someone could do is just grab the rejected transaction, fix the malformed portion, modify the transaction id hash and resend the transaction, causing it to go through, but MtGox was unaware of the successful transfer and would re-credit the account. The user could then rinse and repeat over and over.
The interesting twist of this is that it means MtGox knows which user accounts were used to steal coins from them since the malformed transaction could be modified to change the transaction id hash, but the receiving bitcoin address could not be modified without invalidating the transaction.
Could someone outline loosely what the implications are of this in layperson's terms?
Thanks.
however, not all parts of a transaction are signed. modifying those parts allows one to create a valid transaction with the same bitcoin transferring effect, but with a different overall hash.
the hash of the entire transaction is used as a transaction id.
so a modified transaction would have a different id.
some bitcoin management software (a wallet) loses track of transfers, because those transfers don't occur under the transaction-id it expected.
the implication is that some bitcoin services could get confused about who they've successfully sent bitcoins to.
an attacker could socially engineer a "robbery" by transmitting a mutation of an official withdrawal transaction, then appealing to the helpdesk of that service that their withdrawal never went through. it did go through - just under a different transaction id.
a transaction only becomes immutable once it has been included in the blockchain. after this point, searching for a tx by hash is ok.
calling this a bug of the bitcoin protocol is akin to saying that array decay in C is a bug in the language spec. it is known, and and has been talked about for a long time. in both cases.
Do you know why scripts aren't signed? I don't fully understand bitcoin but it seems like they're an integral part of the transaction.
Any help is appreciated
Transaction hashes are a misnomer -- the hash is a has of the message, NOT of the transaction. Many messages match one transaction.
(discussion: https://news.ycombinator.com/item?id=7211286)
Discussion: https://news.ycombinator.com/item?id=7232175
Discussion on HN: https://news.ycombinator.com/item?id=7234010
It's only an "attack" if your wallet software doesn't validate against the recommended (iirc: to_addy, from_addy, amount, time-in-tx), correct?
Linguistic arguments are kind of pointless, but it's still an attack even if they are just trying to disrupt the system and not steal anything. e.g. a denial-of-service attack.
Various definitions of "attack" are at http://en.wikipedia.org/wiki/Attack_(computing)
It's certainly not an attack on not-bitcoin, so therefore it's an attack on bitcoin.
See, I can say ridiculous things too. Someone using bitcoins didn't follow protocol and as such as scammed out of money. This isn't a bitcoins-protocol issue, this is a people issue.
Note that the other exchanges are up now, very quickly after everyone stopped to check themselves.
I would argue it was an attack on Bitcoin the ecosystem, due to an _oddity_ of Bitcoin the protocol. Bitcoin the idea is still fully alive. The attack worked from within Bitcoin, the network.
The standard client just assumes that the transaction is legit and you can use the remaining coins immediately. But to use these coins the program has to know the ID of the transaction.
But due to the malleability, it's possible that the ID that is generated in your client is not the same ID that is finally added to the blockchain. If you use the original ID and it is changued, then the next transactions will be invalid. So you must wait to see the final ID and use it to create the next transactions.