1

a smart contract store the internal balance per owner. when we transfer tokens from Owner A to Owner B, we update the internal balance sheet. but the internal balance sheet is a most recent snap shot. it does not tell you that Owner A balance was updates 15 blocks ago, while Owner B balance was update just 2 blocks ago. when i call the balanceOf(address) it will read the balance from the local node. so, How can i tell if the value is confirmed? should i store the recent tx-hash per owner and relay on it to calculate the confirmation level?

thnx

  • 1
    Have you looked at the behavior on Cryptocurrency Exchanges and services like Etherscan? ERC20 and ERC721 do not handle confirmations within the protocol, but services that manage these tokens do track the block height of transactions using these tokens. – Shawn Tabrizi Oct 1 '18 at 17:00
2

The short answer is contracts (ERC20 and ERC721 tokens are contracts) don't need to deal with confirmations because that concern is handled by lower levels in the protocol stack.

When you receive tokens from someone, the attack vectors are about the same as a regular transaction. You should watch a specific transaction to be sure it's confirmed.

Hope it helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.