How does a wallet learn of a transaction it has received?

0

I'm curious how a wallet learns of an incoming transaction. Is it constantly searching the blockchain for blocks containing addresses it generated?

autr3go

Posted 2017-12-28T09:28:58.480

Reputation: 1

Answers

1

A bitcoin wallet application that runs as a full node client contains a copy of every unspent transaction in the blockchain. This allows a wallet to construct transaction inputs as well as quickly verify incoming transactions as having correct inputs. However, most user wallets run lightweight clients that only track a users own unspent outputs. If the wallet does not maintain a copy of unspent transaction outputs it can query the bitcoin network using a variety of APIs. The API's will return all the unspent transaction outputs for an address. Most wallets will not run continuously and so when a user starts up the application it will query the network to synchronize with it.

John Singh

Posted 2017-12-28T09:28:58.480

Reputation: 337