<p>A block with a timestamp too far in the future is invalid. This seems to be discovered during <code>ProcessNewBlockHeaders</code> when learning about the block header. The node discards the invalid block header.</p>
<pre class="lang-cpp prettyprint-override"><code>// Check timestamp
if (block.Time() &gt; now + std::chrono::seconds{MAX_FUTURE_BLOCK_TIME}) {
    return state.Invalid(BlockValidationResult::BLOCK_TIME_FUTURE, &quot;time-too-new&quot;, &quot;block timestamp too far in the future&quot;);
}
</code></pre>
<p>via <a href="https://github.com/bitcoin/bitcoin/blob/e3b68b3b833984973401ceff43930f7c56a83f29/src/validation.cpp#L3807-L3810" rel="nofollow noreferrer">src/validation.cpp</a></p>

CC BY-SA 4.0
2024-01-26T16:22:54.933Z
2024-01-26T16:22:54.933Z
Murch
<p>One of the acceptance rule for the blocks is that the block timestamp cannot be more than 2 hours in the future. What happens to blocks whose timestamp does not meet this rule, i.e. blocks that generally do not meet <strong>the acceptance rules</strong> (not consensus rules)? Are they rejected as if they had never been seen?</p>

<bitcoin-core><block><p2p>
What happens to the blocks that do not pass the acceptance rules?
LeaBit
# What happens to the blocks that do not pass the acceptance rules?

(Asked by: username_0 on 2024-01-26)

One of the acceptance rule for the blocks is that the block timestamp cannot be more than 2 hours in the future. What happens to blocks whose timestamp does not meet this rule, i.e. blocks that generally do not meet **the acceptance rules** (not consensus rules)? Are they rejected as if they had never been seen?

**Tags:** bitcoin-core, block, p2p


---

## 1 answers

### Answer by username_1 on 2024-01-26. Score: 2 | Accepted answer

A block with a timestamp too far in the future is invalid. This seems to be discovered during ProcessNewBlockHeaders when learning about the block header. The node discards the invalid block header.
// Check timestamp
if (block.Time() > now + std::chrono::seconds{MAX_FUTURE_BLOCK_TIME}) {
    return state.Invalid(BlockValidationResult::BLOCK_TIME_FUTURE, "time-too-new", "block timestamp too far in the future");
}

via src/validation.cpp


---

