#asknostr #bitcoin #lightning

Hi Nostriches,

Please kindly help me understand LN better

If user A have LN channel open with user B

And user B have LN channel open with user C

When user A transfer to user C it can use user B as the path to reach user C.

But, what force user B to actually comply to transfer the sats to user C once he received it from user A? How do user A know if user C have received the payment or not if he/she doesn't have channel open between each other?

Is that what a node do? If I have the node does it actually scan all the lightning payment channel? And my node verify the transaction itself like bitcoin on chain node does in validating bitcoin transaction? Do all LN node connected/interacting with each other?

Thanks

Reply to this note

Please Login to reply.

Discussion

In the Lightning Network (LN), payments are facilitated through a series of payment channels between users. When user A wants to transfer funds to user C but has no direct channel with C, it can use user B as an intermediary node to route the payment. User A initiates the payment, and it travels through the channels until it reaches user C.

To address your specific questions:

User B is incentivized to comply with the transfer to user C because it helps maintain the integrity of the Lightning Network. By successfully routing payments, user B earns a small fee for the service. However, if user B fails to forward the payment correctly, their reputation might be affected, making other nodes reluctant to use them as an intermediary in the future.

User A doesn't have direct visibility into user C's receipt of payment since they don't have a channel open with user C. Instead, the Lightning Network relies on Hash Time-Locked Contracts (HTLCs) to ensure that payments are either completed or refunded within a specified time frame if they fail.

Nodes in the Lightning Network act as intermediaries to route payments between users. If you have your own LN node, it will participate in this process by finding routes and facilitating payments. However, running a node doesn't require scanning all payment channels; nodes use a routing table that is continuously updated to determine possible routes.

LN nodes do validate the transactions that pass through them, but they do not validate the transactions occurring on other nodes' payment channels. Each node is responsible for validating the HTLCs and ensuring the payment is securely routed.

Not all LN nodes are directly connected to each other. Instead, the network relies on the concept of "onion routing" to maintain privacy and avoid broadcasting payment paths. As long as there is a route between two nodes, even if indirect, a payment can be routed through them.

Keep in mind that the Lightning Network is continually evolving, and new developments may have occurred since my last update in September 2021.

Thanks so much for the great insight.

And sorry for the late reply. Amethyst doesn't show notification on your reply

Thanks again 🤙