News for hackers. Stuff that matters.
Re:BTC Stolen from Poloniex by curveship on Tuesday March 04, 2014 @11:49AM (#7341349)
Seriously. I thought this bit of code from the MtGox leak was interesting. Sure looks like a potential double-spend race condition:

  $out = \DB::DAO('Money_Bitcoin_Block_Tx_Out')->searchOne(array('Hash' => $bean->Hash, 'N' => $bean->N));
  if ($out) {
      if ($out->Claimed == 'Y') {
          $bean->Available = 'N';
          $bean->commit();
          continue;
      }
  }
What if someone else claims $out between the read and commit? Is no one at BTC exchanges really asking these kinds of questions?

There are no comments on this comment yet.