bitcoin/bitcoin — pull request #2342 by petertodd (2013-03-04 10:22:01+00:00)
Title: Fix off-by-one in IsStandard() IsFinal() test

Long story short, with the current IsFinal() test in IsStandard() we reject transactions even if they can be a part of the next block. Instead only transactions that could have been part of the *previous* block are accepted to the mempool. This should be changed, and I think adding an additional one block window is worthwhile for both fidelity bond sacrifice transactions, and for the use of nLockTime to discourage orphan mining. (so non-final transactions are sure to propagate) An attacker would need a heck of a lot of hashing power to double-spend transactions that can be mined after the next block.

Probably best to fix this now, before yet more code gets written that does it wrong...