<blockquote>
  <p>When opening a lightning channel, is there any data immediately written to the blockchain? I mean, the channel is not considered opened until the data is on the blockchain. The data may be the funding transaction, or may be some sort of 2-to-2 multisignature script, I don't know.</p>
</blockquote>

<p>The channel has a funding transaction which must be included in the blockchain before the channel is considered to be opened. Of course, you can use it before it is confirmed, but there is no guarantee of anything that happens in the channel.</p>

<blockquote>
  <p>If the answer is yes, then... is it possible that an opened channel becomes invalid due to a blockchain fork, i.e., the blockchain where the data reside being replaced by a longer,conflicting blockchain?</p>
</blockquote>

<p>Yes, that is possible. However it is extremely unlikely. Like with other transactions, nodes won't consider the funding transaction to actually be complete until it has several confirmations (usually 6). The probability that a fork of length 6 occurs is extremely low. Note that the risk of a fork here is the same as a fork effecting your normal Bitcoin transactions.</p>

<blockquote>
  <p>If the answer is further yes, then, is it possible that some sort of double-spending attacks can be launched on the lightning network?</p>
</blockquote>

<p>The same double spending attacks and risks that you can do to a normal Bitcoin transaction also effect the Lightning Network funding transactions because it really is just a normal Bitcoin transaction.</p>

CC BY-SA 3.0
2018-02-16T06:12:15.460Z
2018-02-16T06:12:15.460Z
Ava Chow
<p>When opening a lightning channel, is there any data immediately written to the blockchain?
I mean, the channel is not considered opened until the data is on the blockchain.
The data may be the funding transaction, or may be some sort of 2-to-2 multisignature script, I don't know.</p>

<p>If the answer is yes, then... is it possible that an opened channel becomes invalid due to a blockchain fork, i.e., the blockchain where the data reside being replaced by a longer,conflicting blockchain?</p>

<p>If the answer is further yes, then, is it possible that some sort of double-spending attacks can be launched on the lightning network?</p>

<lightning-network><ln-opening-channels>
Any data immediately written to the blockchain when opening a lightning channel?
Zijiang Hao
# Any data immediately written to the blockchain when opening a lightning channel?

(Asked by: username_0 on 2018-02-16)

When opening a lightning channel, is there any data immediately written to the blockchain?
I mean, the channel is not considered opened until the data is on the blockchain.
The data may be the funding transaction, or may be some sort of 2-to-2 multisignature script, I don't know.

If the answer is yes, then... is it possible that an opened channel becomes invalid due to a blockchain fork, i.e., the blockchain where the data reside being replaced by a longer,conflicting blockchain?

If the answer is further yes, then, is it possible that some sort of double-spending attacks can be launched on the lightning network?

**Tags:** lightning-network, ln-opening-channels


---

## 1 answers

### Answer by username_1 on 2018-02-16. Score: 1 | Accepted answer

> When opening a lightning channel, is there any data immediately written to the blockchain? I mean, the channel is not considered opened until the data is on the blockchain. The data may be the funding transaction, or may be some sort of 2-to-2 multisignature script, I don't know.

The channel has a funding transaction which must be included in the blockchain before the channel is considered to be opened. Of course, you can use it before it is confirmed, but there is no guarantee of anything that happens in the channel.

> If the answer is yes, then... is it possible that an opened channel becomes invalid due to a blockchain fork, i.e., the blockchain where the data reside being replaced by a longer,conflicting blockchain?

Yes, that is possible. However it is extremely unlikely. Like with other transactions, nodes won't consider the funding transaction to actually be complete until it has several confirmations (usually 6). The probability that a fork of length 6 occurs is extremely low. Note that the risk of a fork here is the same as a fork effecting your normal Bitcoin transactions.

> If the answer is further yes, then, is it possible that some sort of double-spending attacks can be launched on the lightning network?

The same double spending attacks and risks that you can do to a normal Bitcoin transaction also effect the Lightning Network funding transactions because it really is just a normal Bitcoin transaction.


---

