一个可扩展、默认保护隐私的支付和交换网络
Fiber Network Node (FNN) is a reference node implementation of Fiber Network Protocol (FNP). Fiber network is a peer-to-peer payment/swap network (like Lightning Network). We believe payment and swap are the two foundational primitives of finance.
Features
!!! The implementation is still a work-in-progress and will have iterations even after mainnet, please use it with caution and report any issues/limitations in the issue tracker.
TODO
# Install to default location (~/.fiber)
curl -sSfL https://raw.githubusercontent.com/nervosnetwork/fiber/main/tools/install/install.sh | bash
# Install mainnet non-interactively with a trusted CKB RPC endpoint
curl -sSfL https://raw.githubusercontent.com/nervosnetwork/fiber/main/tools/install/install.sh | INSTALL_DIR=/opt/fiber FNN_VERSION=0.9.0 NETWORK=mainnet CKB_RPC_URL=https://your-trusted-mainnet-ckb-rpc.example bash
Mainnet installations do not select a public CKB RPC endpoint automatically.
The guided installer prompts for one; bootstrap or non-interactive installations require
CKB_RPC_URL to be set explicitly.
cargo build --release
mkdir /folder-to/my-fnn
// if you are using the released binary, replace target/release/fnn with the path of released binary
cp target/release/fnn /folder-to/my-fnn
cp config/testnet/config.yml /folder-to/my-fnn
cd /folder-to/my-fnn
ckb/key. You may use the ckb-cli to generate a new key or export an existing key:mkdir ckb
ckb-cli account export --lock-arg --extended-privkey-path ./ckb/exported-key
// ckb-cli exports master private key and chain code, FNN only needs the private key part
head -n 1 ./ckb/exported-key > ./ckb/key
// the exported key file can be deleted after the private key is extracted
rm ./ckb/exported-key
FIBER_SECRET_KEY_PASSWORD environment variable to encrypt the wallet private key file (which was stored in plain text during the previous step). Additionally, you can configure logging verbosity with the RUST_LOG environment variable—use predefined levels like info, debug, or trace, or specify granular logging with patterns such as info,fnn=debug to enable debug logs only for the FNN module.FIBER_SECRET_KEY_PASSWORD='YOUR_PASSWORD' RUST_LOG='info' ./fnn -c config.yml -d .
Fiber release tags publish official container images to Docker Hub at nervos/fiber and mirror the same tags to GHCR at ghcr.io/nervosnetwork/fiber. Detailed Docker usage, including startup, local builds, fnn-cli, and migration, is documented in docker/README.md.
FNN is still under development, the protocol and storage format may changed between versions. We strongly recommend you to close the channel before upgrading the node, otherwise, you may lose channel data and funds!
list all channels and close them via RPC.
Stop the node and remove the storage of the node:
rm -rf /folder-to/my-fnn/fiber/store
If you want to keep the channel state, check whether your upgrade path supports
in-place migration before replacing binaries. Since v0.9.0, supported storage
migrations are integrated into the fnn startup process, and release bundles no
longer include a standalone fnn-migrate binary.
Stop the node.
Backup the storage folder /folder-to/my-fnn/fiber/store.
Replace the fnn binary with the new version and start the node again.
If the new fnn reports that the database is too old for the built-in migration
path, use the legacy fnn-migrate tool from the matching v0.8.x release first.
For the v0.7.x to v0.8.0 legacy migration flow, see
v0.8.0 Migration Guide.
We are in an actively developing stage, don't hesitate to report issues or ask for help in the channel of the Nervos dev community.
设计:支持多租户托管 LSP
TxAbort 将本地资金失败原因隐藏为通用的"资金取消"信息
QUIC 宣布的地址会被私有地址过滤器默认丢弃
设计: 纤维流动性管理里程碑
在 #1583 之后,终端 0xfe 结算可能会导致上游 TLC 未调节
在链上超时调解期间,未提交的 RemoteRemoved TLC 将被跳过
`fnn --restore` 无法覆盖现有的只读 Fiber 私密密钥文件
在 `node_info` 中暴露 `synced_to_graph`
在 Android 移动设备上运行 Fiber: 24/7 可用性和观察塔委托
代理 / 光纤整合解决方案设计