<p>Some things you need to remember about bitcoin:</p>
<ul>
<li>Bitcoin is cash, not a bank account. These are very different models.
<ul>
<li>You pay by handing over digital coins, not by making a bank-transfer between accounts.</li>
<li>No one but you cares what total amount of Bitcoin money you have, they don't need to know.</li>
</ul>
</li>
</ul>
<p>This fundamental misunderstanding comes up a lot in different forms. The questions below have answers which touch on this and may help form a clearer understanding:</p>
<ul>
<li><a href="https://bitcoin.stackexchange.com/q/106489/13866">How does Bitcoin verify that a user owns the bitcoins he/she spent?</a></li>
<li><a href="https://bitcoin.stackexchange.com/q/106403/13866">What is the meaning of difficulty in Bitcoin mining?</a></li>
<li><a href="https://bitcoin.stackexchange.com/q/106020/13866">Bitcoin Fraud/Recovery Protocol Proposals</a></li>
<li><a href="https://bitcoin.stackexchange.com/q/101797/13866">Why do so many Bitcoin wallets and accounts exist?</a></li>
<li><a href="https://bitcoin.stackexchange.com/q/103444/13866">What prevent someone to not use the receiver address of one transaction as the sender in another one?</a></li>
</ul>
<hr />
<blockquote>
<p><strong>For anonymity reasons key pair of a wallet can change.</strong></p>
</blockquote>
<p>HD wallets generate an extra key pair for each transaction but the old key-pairs are still valid and are not changed.</p>
<blockquote>
<p><strong>Then how does miner validate if a sender has enough bitcoins?</strong></p>
</blockquote>
<p>Miners don't care how much money is in a wallet. Bitcoin is cash and like other forms of cash, people don't care how much money you have, they only care that the cash you give them is enough and is genuine and not a forgery.</p>
<blockquote>
<p><strong>Is this has something to do with origin of bitcoin sent in transaction?</strong></p>
</blockquote>
<p>What you spend as inputs to a new transaction are the outputs of a previous transaction in which you received money. These are unspent transaction outputs (UTXOs).</p>
<blockquote>
<p><strong>what if sent sum is 30 BTC, but they are all received from 3 (3x10 BTC) separate wallets?</strong></p>
</blockquote>
<p>People don't care. Your transaction could have hundreds of inputs and hundreds of outputs - though that makes the fee higher. All that matters to the recipient and everyone else is that the cash is genuine. In Bitcoin this means UTXOs and that you provide proof of right to spend (you supply a mathematically derived number that satisfies the spending script of the UTXO)</p>

CC BY-SA 4.0
2021-06-04T21:39:41.873Z
I believe OP may be confused due to thinking Bitcoin has an account-based model.
Pieter Wuille
CC BY-SA 4.0
2021-06-04T21:48:16.757Z
@Pieter: Yes, I've made an edit to try to make this clearer.
RedGrittyBrick
CC BY-SA 4.0
2021-06-05T18:24:23.017Z
No, I understand that it is decentralized. Other answers you provided answered my question. I made implication that blockchain is made from blocks (which is made from transactions) not from transactions themselves, while block only encapsulate transactions. Thanks.
Vardenis
CC BY-SA 4.0
2021-06-04T21:37:47.520Z
2021-06-04T21:58:51.327Z
2021-06-04T21:58:51.327Z
RedGrittyBrick
<p>For anonymity reasons key pair of a wallet can change. Then how does miner validate if a sender has enough bitcoins?
After key pair change blockchain history contains only old public key as a wallet reference.</p>
<p>Is this has something to do with origin of bitcoin sent in transaction? If so, what if sent sum is 30 BTC, but they are all received from 3 (3x10 BTC) separate wallets?</p>

<transaction-verification>
Bitcoin wallet key pair change and transaction validation
Vardenis
# Bitcoin wallet key pair change and transaction validation

(Asked by: username_0 on 2021-06-04)

For anonymity reasons key pair of a wallet can change. Then how does miner validate if a sender has enough bitcoins?
After key pair change blockchain history contains only old public key as a wallet reference.

Is this has something to do with origin of bitcoin sent in transaction? If so, what if sent sum is 30 BTC, but they are all received from 3 (3x10 BTC) separate wallets?

**Tags:** transaction-verification


---

## 1 answers

### Answer by username_1 on 2021-06-04. Score: 0 | Accepted answer

Some things you need to remember about bitcoin:

* Bitcoin is cash, not a bank account. These are very different models.
  + You pay by handing over digital coins, not by making a bank-transfer between accounts.
  + No one but you cares what total amount of Bitcoin money you have, they don't need to know.

This fundamental misunderstanding comes up a lot in different forms. The questions below have answers which touch on this and may help form a clearer understanding:

* [How does Bitcoin verify that a user owns the bitcoins he/she spent?](https://bitcoin.stackexchange.com/q/106489/13866)
* [What is the meaning of difficulty in Bitcoin mining?](https://bitcoin.stackexchange.com/q/106403/13866)
* [Bitcoin Fraud/Recovery Protocol Proposals](https://bitcoin.stackexchange.com/q/106020/13866)
* [Why do so many Bitcoin wallets and accounts exist?](https://bitcoin.stackexchange.com/q/101797/13866)
* [What prevent someone to not use the receiver address of one transaction as the sender in another one?](https://bitcoin.stackexchange.com/q/103444/13866)

---

> **For anonymity reasons key pair of a wallet can change.**

HD wallets generate an extra key pair for each transaction but the old key-pairs are still valid and are not changed.

> **Then how does miner validate if a sender has enough bitcoins?**

Miners don't care how much money is in a wallet. Bitcoin is cash and like other forms of cash, people don't care how much money you have, they only care that the cash you give them is enough and is genuine and not a forgery.

> **Is this has something to do with origin of bitcoin sent in transaction?**

What you spend as inputs to a new transaction are the outputs of a previous transaction in which you received money. These are unspent transaction outputs (UTXOs).

> **what if sent sum is 30 BTC, but they are all received from 3 (3x10 BTC) separate wallets?**

People don't care. Your transaction could have hundreds of inputs and hundreds of outputs - though that makes the fee higher. All that matters to the recipient and everyone else is that the cash is genuine. In Bitcoin this means UTXOs and that you provide proof of right to spend (you supply a mathematically derived number that satisfies the spending script of the UTXO)

> **Comments:**
> **username_2**: I believe OP may be confused due to thinking Bitcoin has an account-based model.  
> **username_1**: @username_2: Yes, I've made an edit to try to make this clearer.  
> **username_0**: No, I understand that it is decentralized. Other answers you provided answered my question. I made implication that blockchain is made from blocks (which is made from transactions) not from transactions themselves, while block only encapsulate transactions. Thanks.  

---

