4
How Lightning Network handles double-spend? What will happen when the other person is not available online to enforce the integrity of the transactions?
PFB my understanding of the Lightning Network.
Lightning Network builds an additional layer on top of the Bitcoin network that enables instant off-chain transfer of the ownership of the Bitcoin. Lightning Network utilises bi-directional payments channels that consist of multi-signature addresses. Meaning Bitcoin will be held in a multi-signature address where transactions will use a multi-signature address as their input and point at two different addresses as their output. The transactions inside the lighting network are not broadcasted to the bitcoin network as long the channel is open (in order to reduce the load on the blockchain).
In this example how is Alice prevented from double spending?
Alice and Bob both send 0.05 BTC into a shared 2-of-2 multisig address. This requires a transaction on the Bitcoin blockchain.
Alice wants to pay 0.1 BTC to Bob. a. Alice creates a new transaction B2 and changes the balance to 0.4 BTC to Alice and 0.6BTC to Bob. b. Alice signs B2 and sends to Bob c. Now Bob creates a new transaction A2 and changes the balance to 0.4 BTC to Alice and 0.6BTC to Bob. d. Bob signs A2 and sends to Alice. After step 2a (before Bob verifies the transaction), can Alice close the channel and double spend the money?
In your example both the transactions are identical. They have the same balances. – Matthew Charles Stannard – 2018-01-01T14:51:57.983
Thanks! Have edited the question. Need to know how LN is stopping Alice from spending the same BTC to Bob and transfer the same by closing the channel if Bob is not online ? – Holmes – 2018-01-01T15:00:26.863
Which transaction is Alice broadcasting to close the channel? – Matthew Charles Stannard – 2018-01-01T15:19:15.627
can she broadcast the initial transaction balance 0.5 BTC to the blockchain & unilaterally close the channel? while Bob is unavailable to verify the transaction in the LN channel – Holmes – 2018-01-01T15:21:54.207
Did Bob receive and broadcast the 'anti-cheat' transaction from Alice after she sent him B2? – Matthew Charles Stannard – 2018-01-01T15:38:11.467
No, in that case can Alice double spend her coins ? – Holmes – 2018-01-01T15:47:49.767
Did Bob provide any goods or services to Alice? If so, Yes. But only because Bob hasn't followed the protocol correctly. – Matthew Charles Stannard – 2018-01-01T15:50:18.483
Thanks! In general how does the protocol enforce integrity of the transactions since its not broadcasted to the blockchain? – Holmes – 2018-01-01T21:20:00.163