<p>It is an accurate abstraction.</p>

<p>However, the most computationally expensive part of transaction verification is ECDSA signature verification. And the results of verification are cached and reused when they're done a second time. We don't cache the rest of transaction verification as it is subject to many parameters (new softfork rules can have been activated, height, locktime, ...), and it's relatively cheap anyway. We do however cache transaction verification failures.</p>

CC BY-SA 3.0
2016-01-23T17:56:50.727Z
Thanks much for the quick reply. You mention that "the results of verification are cached and reused when they're done a second time". Two clarifying questions:[1] that second time is when the full node receives a new block and is running through all of the transactions in that block? [2] every full node maintains its own "verification cache"?
Pressed250
CC BY-SA 3.0
2016-01-23T18:46:24.530Z
[1] Yes. [2] Yes.
Pieter Wuille
CC BY-SA 3.0
2016-01-23T17:24:10.850Z
2016-01-23T17:24:10.850Z
Pieter Wuille
<p>I am building my Bitcoin expertise, and want to verify my understanding on a specific point: at what point(s) do all full nodes verifies a new transaction?</p>

<p>Here is my understanding in a nutshell, please confirm or correct:</p>

<p>[1] Upon receiving each new transaction, every full node fully verifies it before adding the transaction to the its own mempool</p>

<p>[2] Upon receiving each new block, every full node fully verifies each transaction in the block before accepting the block</p>

<p>If the above understanding is correct, then every full node verifies each new transaction TWO TIMES: once when the shiny-new transaction is unconfirmed, and again a few minutes later when the transaction is included in a block.</p>

<p>I recognize the above is somewhat of an abstraction ... is it an ACCURATE abstraction?</p>

<p>Thanks in advance.</p>

<transactions><nodes><transaction-verification>
Does every full node verify every transaction TWO separate times?
Pressed250
# Does every full node verify every transaction TWO separate times?

(Asked by: username_0 on 2016-01-23)

I am building my Bitcoin expertise, and want to verify my understanding on a specific point: at what point(s) do all full nodes verifies a new transaction?

Here is my understanding in a nutshell, please confirm or correct:

[1] Upon receiving each new transaction, every full node fully verifies it before adding the transaction to the its own mempool

[2] Upon receiving each new block, every full node fully verifies each transaction in the block before accepting the block

If the above understanding is correct, then every full node verifies each new transaction TWO TIMES: once when the shiny-new transaction is unconfirmed, and again a few minutes later when the transaction is included in a block.

I recognize the above is somewhat of an abstraction ... is it an ACCURATE abstraction?

Thanks in advance.

**Tags:** transactions, nodes, transaction-verification


---

## 1 answers

### Answer by username_1 on 2016-01-23. Score: 4

It is an accurate abstraction.

However, the most computationally expensive part of transaction verification is ECDSA signature verification. And the results of verification are cached and reused when they're done a second time. We don't cache the rest of transaction verification as it is subject to many parameters (new softfork rules can have been activated, height, locktime, ...), and it's relatively cheap anyway. We do however cache transaction verification failures.

> **Comments:**
> **username_0**: Thanks much for the quick reply. You mention that "the results of verification are cached and reused when they're done a second time". Two clarifying questions:[1] that second time is when the full node receives a new block and is running through all of the transactions in that block? [2] every full node maintains its own "verification cache"?  
> **username_1**: [1] Yes. [2] Yes.  

---

