Post
Topic
Board Development & Technical Discussion
Re: Sending locked coins
by
DannyHamilton
on 26/04/2021, 22:50:14 UTC
In my example, Albert's 10 BTC are already in Bob wallet, but locked for X hours, unspendable by Bob.

Coins are never "IN" a wallet.  They only EVER exist as value referenced by the transaction outputs (either stored in each node's mempool, or in the blockchain).

If they are not in Albert's wallet, how can Albert spend them again?

See my statement above.  Bob can spend the coins if he can meet the conditions of the output script.  Albert can spend the coins if he can meet the conditions of the output script.  Neither can spend the coins if neither can meet the conditions of the output script, and both can spend the coins if both can meet the conditions of the output script.

I imagine the lock having 2 options: 1 - If nothing happen, the 10 BTC return to Al wallet. 2 - If Al lock is cancelled, Bob can move the coins.

How is this different than Al just keeping control over the coins until he's ready to send them to Bob?

In both the "locked coins" system (without unlocking) that you are trying to invent AND in the scenario where Al doesn't send the coins, Bob never gets control over the coins at all.

Also in both the "locked coins" system (with eventual unlock) that you are trying to invent AND in the scenario where Al sends the coins eventually, Bob gets control over the coins when Al finally decides to let him have control.

The only difference is that in your scenario, there is a short period of time when NEITHER can spend the coins.  I don't see how having such a period of time provides security to either party, since either could just wait out the time.

If you are selling your house, you can sit around a table for 10 minutes before giving the guy your keys.

Wouldn't you just have the guy send the transaction, and then once it's confirmed give him the keys?