No description provided.
OP_CHECKBLOCKATHEIGHT anti-replay (BIP 115; logic only) #10391
pull luke-jr wants to merge 5 commits into bitcoin:master from luke-jr:cbah changing 21 files +210 −77-
luke-jr commented at 4:15 AM on May 12, 2017: member
-
script: Allow interpreter to fail with SCRIPT_ERR_NOT_FINAL to indicate a context-dependent/non-final status b779f5a12a
-
policy: Split STANDARD_SCRIPT_VERIFY_FLAGS between contextual and non-contextual 7aabfd8111
-
Pass CChain through to signature checker in contextual verifications 04b0a00c72
-
script: Implement OP_CHECKBLOCKATHEIGHT c1bf3d75ed
-
CHistoricalChain to fix context in CVerifyDB 316d727dda
-
dcousens commented at 4:22 AM on May 12, 2017: contributor
https://github.com/luke-jr/bips/blob/bip-0115/bip-0115.mediawiki - for others reference
-
in src/script/interpreter.cpp:443 in 316d727dda
439 | + if (stack.size() < 2) { 440 | + return set_error(serror, SCRIPT_ERR_INVALID_STACK_OPERATION); 441 | + } 442 | + 443 | + // nHeight is a 32-bit signed integer field. 444 | + const int32_t nHeight = CScriptNum(stacktop(-1), true, 4).getint();
WaveringAna commented at 2:39 AM on July 10, 2017:Can this cause a buffer overflow if a block height over 2147483647 occurs?
luke-jr commented at 3:29 AM on July 10, 2017:No? Why would it?
WaveringAna commented at 3:41 AM on July 10, 2017:nHeight is a int32_t, if someone makes a transaction with 2147483648 as the referenced block, it would cause an overflow
luke-jr commented at 4:25 AM on July 10, 2017:Not all overflows are buffer overflows. In this case, CScriptNum explicitly limits the size.
luke-jr commented at 7:05 PM on November 16, 2017: memberThe BIP needs revising for static analysis compat.
luke-jr closed this on Nov 16, 2017DrahtBot locked this on Sep 8, 2021Contributors
github-metadata-mirror
This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-14 15:15 UTC
This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-14 15:15 UTC
This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me
More mirrored repositories can be found on mirror.b10c.me