Gate Square “Creator Certification Incentive Program” — Recruiting Outstanding Creators!
Join now, share quality content, and compete for over $10,000 in monthly rewards.
How to Apply:
1️⃣ Open the App → Tap [Square] at the bottom → Click your [avatar] in the top right.
2️⃣ Tap [Get Certified], submit your application, and wait for approval.
Apply Now: https://www.gate.com/questionnaire/7159
Token rewards, exclusive Gate merch, and traffic exposure await you!
Details: https://www.gate.com/announcements/article/47889
Fiber Network: Public Lighting Network based on CKB
Overview
Fiber Network is a next-generation public Lighting Network built on Nervos CKB and off-chain channels, providing fast, low-cost, and decentralized multi-currency payments and peer-to-peer transactions for RGB++ assets.
Background
Development and Challenges of Blockchain Technology
Blockchain technology has experienced rapid development since the emergence of Bitcoin. It has gradually expanded from simple payment functions to a wide range of applications such as smart contracts, decentralized finance (DeFi), and non-fungible tokens (NFTs). Although blockchain technology has significant advantages in security, transparency, and decentralization, it faces many challenges in terms of scalability and transaction speed.
Although Nervos CKB has made improvements in performance and confirmation time, it still needs to further improve transaction speed and dropTransaction Cost to meet the needs of small payments and instant payments.
The Enlightenment of Lighting Network
Lighting Network (Lightning Network) as a second-layer scaling solution for the BTC network, has successfully achieved fast and low-cost micropayments through off-chain transactions and payment channel technology. Its core concepts include:
Advantages of Nervos CKB
Nervos CKB is a Block chain platform that focuses on universality and security. Its unique design gives it unique advantages in solving Block chain scalability and interoperability issues:
The Significance of the Fiber Network project
By building off-chain channels on Nervos CKB, we hope to combine the successful experience of the Lighting Network with the technical advantages of CKB to create a fast, low-cost, and Decentralization multi-asset real-time payment exchange network. Specifically:
Architectural design
Overall Architecture
The overall architecture of the Fiber Network includes the following core modules:
Off-chain payment channel
The off-chain payment channel is the core of the Fiber Network, through which multiple off-chain transactions can be realized, and on-chain settlement is only conducted when the channel is closed. This mechanism significantly reduces the number of on-chain transactions, improves transaction speed, and drops Money Laundering.
The general workflow is as follows:
The specific message interaction format can refer to the Fiber Network P2P Message Protocol[2]
on-chain contract
Currently, we use the Hashed TimeLock Contract (HTLC) to ensure the security of off-chain transactions and to be compatible with the Lighting Network. Through it, we can avoid counterparty risk and ensure that users can obtain fund protection through on-chain contracts even in the event of off-chain transaction failure.
The general workflow is as follows:
Thanks to the Turing completeness of CKB, we can achieve more flexible and secure on-chain contracts. We will further expand the functionality of the contracts, such as introducing version-based revocation mechanisms and more secure Point Time-Locked Contracts.
Multi-hop routing
Multi-hop routing technology allows users to complete payments through multiple intermediate nodes without directly establishing payment channels with each other. This mechanism enhances the flexibility and coverage of the network.
Workflow:
At the same time, we will also use HTLC contracts here to implement payment for Cross-Chain Interaction, and support interoperability with Lighting Network through cross-chain hub service. For details, please refer to Payment Channel Cross-Chain Protocol with HTLC.[3]
Monitoring Service
The monitoring service is an important part of the Fiber Network, responsible for monitoring the status of off-chain payment channels to ensure the security of the channels and funds. The functions and roles are as follows:
Current Progress and Plans
We have completed a prototype of the Fiber Network, which implements the basic functions of creating, updating, and closing channels between two Nodes. At the same time, we have also verified the Cross-Chain Interaction with BTCLighting Network. The project code can be found in these two GitHub repositories:.
The next work plan is to complete multi-hop routing and monitoring services, as well as improve the RPC interface and SDK, so that more developers can easily access the Fiber Network.
The multi-hop routing protocol is based on the Dijkstra Algorithm to search for payment paths, in order to drop routing fees and improve the success rate of multi-hop path payments. After the launch of the Fiber Network, we will optimize the routing Algorithm based on network traffic and operation conditions. It is expected to provide 2-3 path search strategies to adapt to users’ different routing preferences and needs. Fiber Network will also introduce a multi-path payment strategy, dividing larger payments into multiple parts, each transmitted through different paths, further increasing the probability of payment success.
The monitoring service will be provided by some Nodes in the Fiber Network, they stay online, follow the abnormal situations in the network, and help protect the assets in the channel. The monitoring service will also track the cross-chain hub service. Even if the user is offline for a period of time, the monitoring service can ensure successful exchanges with the Lighting Network.
In addition, we will also consider adding more features to the Fiber Network, such as using the programmability of CKB to achieve privacy protection Algorithm, and based on this, optimizing the routing Algorithm and monitoring services to protect the security and privacy of user payment information.