Is there a built-in function that allows a contract to make the calling transaction invalid, and thus ineligible to be included in a block? I've searched Google, but wasn't able to find even a discussion concerning it. Such behavior can already be implemented using an infinite loop, so a built-in would simply be a convenience function. Is it planned on being implemented, or is the concept of invalidating a transaction from a contract discouraged because it would mess with the strict serial nature of the transactions coming from a specific address?
0 ·
Comments
Perhaps an invalid EVM opcode could do the job? I don't see that behavior defined anywhere, and the current EVM implementation just throws a exception.
Also, i like the idea of not needing to execute the code before accepting transactions.(code from prior blocks does have to be executed, of course)
PS. Out of curiosity, what hashes to 0x1bfcd53a87e20ae004cd931d092057d5852f54701c52dc0e607f29a82a1e8e6c?
Whereas with an 'invalid' statement in the code, you do need to compute, and cannot keep track of those numbers, an attacker can keep sending new ones. Besides, client-side logic might be able to determine whether to send that transaction in the first place. Maybe you could have a instruction that asks the miners nicely, and good defaults about it. Dunno, generated it with
echo $RANDOM$RANDOM$RANDOM$RANDOM |sha256sum
(or more/less$RANDOM
s) which actually the wrong way to do it, it takes the number as a string, and includes the newline.