Let's se if understood correctly. The "malelability" of transaction requests can cause two problems:
* First, old or custom wallet software may broadcast out "non-canonical" transaction requests (like writing "$020,0" on
check instead of "$20,00").
Such requests were originally accepted by the bitcoin network, but a few months ago the protocol was tightened
and they started being rejected.
An exchange that issued such a request in order to execute bitcoin withdrawals by clients had to either re-issue the transaction
request, or cancel the withdrawal and credit back those bitcoins to the client's account. If the exchange did either of these
two things, the result would be only annoyance to clients as their withdrawals were delayed or failed.
If the exchange did not do either of those things, the bitcoins would be subtracted from the client's account but would remain
in the exchange's own wallet. If the exchange also failed do proper accounting (which it probably did, or else it would have detected the
problem), it may have believed that the apparent BTC surplus (bitcoins in its own wallet minus sum of all bitcoins in the clients accounts)
was its profit from fees; and therefore converted that surplus into dollars to pay for expenses and dividends. In extreme situations,
the exchange may become insolvent (unable to produce enough bitcoins and dollars to honor all its client's accounts.)
* Second, some hackers exploited the malleability to steal coins from any exchange that issued non-canonical requests.
The hacker would open an account at the exchange, put some bitcoins there, and request a withdrawal. He would then watch
for the corresponding transaction request as it was broadcast by the exchange, and would broadcast a mutated copy (like
changing "$020" to "$20"). The network would execute the "canonical" version and reject the original for being non-canonical (and
also an attempted double spend).
The exchange would then think that the transaction had failed, and therefore would either re-try it, or cancel the withdrawal and
credit back the coins to the hacker's account. In the first case the hacker would get the withdrawal executed two or more times
but debited only once; in the second case he would get the withdrawal executed without his account being debited. Repeat
to taste.
Again, this hack could be spotted imediately if the exchange kept proper accounting, as it would notice that the coins
were taken out from its own wallet in spite of the transaction being apparently rejected.
Is this understanding correct?
If so, does anyone know whch exchanges had which of these problems, and how many bitcoins they overspent or had stolen?
It seems that for MtGOX the amount involved is at least 50,000 BTC or more, and one of those two problems had been occurring for several months. How could they fail to notice and diagnose such a big problem?
I believe that's correct although it wasn't the transaction amount but one of the transaction codes that was malleable. However, it was my understanding that no 'money' was ever actually stolen in this way from the exchanges at least (the SR example may the the exception that proves the rule).
NB I'm no expert and this is based on the reading I've done this week, no flaming thanks