Skip to content
Please note that GitHub no longer supports Internet Explorer.

We recommend upgrading to the latest Microsoft Edge, Google Chrome, or Firefox.

Learn more
Lightning Network Daemon ⚡️
Branch: master
Clone or download
Roasbeef Merge pull request #2744 from cfromknecht/disable-before-close
cnct+chancloser: disable channel before closing
Latest commit c7ca387 Mar 22, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github docs: expand contributor checklist w/ commit structure Dec 20, 2018
aezeed Add a links to KDF and BIP39 Feb 2, 2019
autopilot autopilot+autopilotrpc: ignore local channels if ignore_local_state set Mar 18, 2019
brontide brontide/conn: expose ReadNextHeader+ReadNextBody Feb 22, 2019
buffer buffer+pool: add buffer.Read and pool.ReadBuffer Feb 16, 2019
build build: bump to psuedo version 0.5.2-99-beta Feb 22, 2019
chainntnfs multi: update build to latest version of neutrino+btcwallet Mar 13, 2019
chanbackup chanbackup: add new sub-system for keeping the on disk channels.backu… Jan 24, 2019
channeldb htlcswitch: hodl invoice Mar 15, 2019
channelnotifier lnd: introduce the ChannelNotifier. Feb 6, 2019
cmd/lncli Merge pull request #2794 from halseth/autopilot-query-heuristic-no-ac… Mar 22, 2019
contractcourt
contrib contrib: add basic bash completion for lncli Jan 30, 2017
discovery discovery+server: send lazy gossip msgs Mar 6, 2019
docker Change simtest to testnet for connection to testnet faucet Feb 26, 2019
docs fix links to BIP 157 and 158 Feb 27, 2019
htlcswitch htlcswitch/test: hodl invoice test Mar 15, 2019
input sweep/input: adds NewBaseInput to return reference Feb 6, 2019
invoices htlcswitch: hodl invoice Mar 15, 2019
keychain keychain: add new KeyFamily: KeyFamilyStaticBackup for SCB encryption… Jan 24, 2019
lncfg config: add sanity check to prevent non-negative worker counts Mar 14, 2019
lnpeer peer: add SendMessageLazy Mar 6, 2019
lnrpc Merge pull request #2794 from halseth/autopilot-query-heuristic-no-ac… Mar 22, 2019
lntest lnrpc+rpcserver: rename ScriptPubkey to PkScript on Utxo msg Feb 11, 2019
lntypes lntypes: return a value from constructors Mar 15, 2019
lnwallet lnwallet/interface_test: add testCreateSimpleTx Mar 15, 2019
lnwire Merge pull request #2590 from Crypt-iQ/init_message_payload_fix Mar 22, 2019
macaroons multi: move Input interface and related code Jan 31, 2019
make build: add routerrpc tag in itest Mar 21, 2019
multimutex multimutex: add new multimutex package Jan 24, 2018
nat
netann netann/chan_status_manager: remove unknown edges from passive disable Mar 13, 2019
pool pool/worker_test: add tests for concrete Worker pools Feb 22, 2019
queue Merge pull request #2419 from cfromknecht/brontide-buffer-pool Feb 19, 2019
routing zpay32: move HopHint and DefaultFinalCLTVDelta Mar 15, 2019
shachain multi: sort import paths with gofmt Aug 3, 2018
signal multi: init subsystem loggers via build pkg Oct 5, 2018
subscribe subscribe: add new subscribe package Feb 6, 2019
sweep multi: move Input interface and related code Jan 31, 2019
ticker
tor tor: add support for NULL authentication to controller Jan 19, 2019
walletunlocker
watchtower watchtower/wtclient: fix linter issue Mar 21, 2019
zpay32 zpay32: move HopHint and DefaultFinalCLTVDelta Mar 15, 2019
.gitignore
.travis.yml
Dockerfile fix dockerfile dependency bug Dec 2, 2018
LICENSE lnd: update copyright notice Nov 2, 2018
Makefile Merge pull request #2745 from cfromknecht/make-install-btcd Mar 9, 2019
README.md README: remove testnet3 specificity Mar 17, 2019
breacharbiter.go breacharbiter: detect all spends, add terminal states Mar 20, 2019
breacharbiter_test.go breacharbiter_test: add table-driven breach spend tests Mar 20, 2019
chainparams.go
chainregistry.go lnd: extract neutrino initialization to new function Mar 14, 2019
chancloser.go chancloser+cnct: disable channel before closing Mar 13, 2019
config.go Merge pull request #2736 from cfromknecht/config-num-workers Mar 19, 2019
doc.go add some daemon related skeleton files Dec 26, 2015
fundingmanager.go multi: remove ErrDoubleSpend check for PublishTransaction Mar 14, 2019
fundingmanager_test.go peer: add SendMessageLazy Mar 6, 2019
go.mod
go.sum build: update to latest btcwallet with deadlock bug fix, neutrino bump Mar 21, 2019
lnd.go lnd: extract neutrino initialization to new function Mar 14, 2019
lnd_test.go lnd_test: test disable is sent during close Mar 13, 2019
log.go
logo.png README: add logo to top portion of page Sep 29, 2017
mock.go mock: support late registration of spend ntfns Mar 20, 2019
nursery_store.go utxonursery: connect to time-based sweeper Dec 18, 2018
nursery_store_test.go utxonursery: connect to time-based sweeper Dec 18, 2018
peer.go peer: preallocate errchans opt Mar 6, 2019
peer_test.go htlcswitch: remove lnrpc dependency Jan 3, 2019
pilot.go lnd+pilot+autopilot: use config to set active autopilot heuristics Jan 23, 2019
release.sh build: update release.sh to contain vendor archive + source code Jan 18, 2019
rpcserver.go routerrpc: adapt to changed interfaces of routing subsystem Mar 21, 2019
sample-lnd.conf Merge pull request #1108 from sangaman/sever-server Sep 28, 2018
server.go Merge pull request #2736 from cfromknecht/config-num-workers Mar 19, 2019
server_test.go Improved color validation - now with fixes and a table driven test Nov 9, 2018
subrpcserver_config.go routerrpc: adapt to changed interfaces of routing subsystem Mar 21, 2019
test_utils.go test_utils: start chan status manager Mar 13, 2019
utxonursery.go utoxnursery: allow nursery to start up if timeout spend happens Mar 19, 2019
utxonursery_test.go utxonursery: report unconfirmed htlc on commit tx Feb 1, 2019
witness_beacon.go channeldb: store hold invoice Mar 15, 2019

README.md

Lightning Network Daemon

Build Status MIT licensed Irc Godoc

The Lightning Network Daemon (lnd) - is a complete implementation of a Lightning Network node. lnd has several pluggable back-end chain services including btcd (a full-node), bitcoind, and neutrino (a new experimental light client). The project's codebase uses the btcsuite set of Bitcoin libraries, and also exports a large set of isolated re-usable Lightning Network related libraries within it. In the current state lnd is capable of:

  • Creating channels.
  • Closing channels.
  • Completely managing all channel states (including the exceptional ones!).
  • Maintaining a fully authenticated+validated channel graph.
  • Performing path finding within the network, passively forwarding incoming payments.
  • Sending outgoing onion-encrypted payments through the network.
  • Updating advertised fee schedules.
  • Automatic channel management (autopilot).

Lightning Network Specification Compliance

lnd fully conforms to the Lightning Network specification (BOLTs). BOLT stands for: Basis of Lightning Technology. The specifications are currently being drafted by several groups of implementers based around the world including the developers of lnd. The set of specification documents as well as our implementation of the specification are still a work-in-progress. With that said, the current status of lnd's BOLT compliance is:

  • BOLT 1: Base Protocol
  • BOLT 2: Peer Protocol for Channel Management
  • BOLT 3: Bitcoin Transaction and Script Formats
  • BOLT 4: Onion Routing Protocol
  • BOLT 5: Recommendations for On-chain Transaction Handling
  • BOLT 7: P2P Node and Channel Discovery
  • BOLT 8: Encrypted and Authenticated Transport
  • BOLT 9: Assigned Feature Flags
  • BOLT 10: DNS Bootstrap and Assisted Node Location
  • BOLT 11: Invoice Protocol for Lightning Payments

Developer Resources

The daemon has been designed to be as developer friendly as possible in order to facilitate application development on top of lnd. Two primary RPC interfaces are exported: an HTTP REST API, and a gRPC service. The exported API's are not yet stable, so be warned: they may change drastically in the near future.

An automatically generated set of documentation for the RPC APIs can be found at api.lightning.community. A set of developer resources including talks, articles, and example applications can be found at: dev.lightning.community.

Finally, we also have an active Slack where protocol developers, application developers, testers and users gather to discuss various aspects of lnd and also Lightning in general.

Installation

In order to build from source, please see the installation instructions.

Docker

To run lnd from Docker, please see the main Docker instructions

IRC

  • irc.freenode.net
  • channel #lnd
  • webchat

Security

The developers of lnd take security very seriously. The disclosure of security vulnerabilities helps us secure the health of lnd, privacy of our users, and also the health of the Lightning Network as a whole. If you find any issues regarding security or privacy, please disclose the information responsibly by sending an email to security at lightning dot engineering, preferably encrypted using our designated PGP key (91FE464CD75101DA6B6BAB60555C6465E5BCB3AF) which can be found here.

Further reading

You can’t perform that action at this time.