-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
multi: add README's for all sub-packages
- Loading branch information
Showing
9 changed files
with
267 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
brontide | ||
========== | ||
|
||
[![Build Status](http://img.shields.io/travis/lightningnetwork/lnd.svg)] | ||
(https://travis-ci.org/lightningnetwork/lnd) | ||
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)] | ||
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)] | ||
(http://godoc.org/github.com/lightningnetwork/lnd/brontide) | ||
|
||
The brontide package implements a secure crypto messaging protocol based off of | ||
the [Noise Protocol Framework](http://noiseprotocol.org/noise.html). The | ||
package exposes the raw state machine that handles the handshake and subsequent | ||
message encryption/decryption scheme. Additionally, the package exposes a | ||
[net.Conn](https://golang.org/pkg/net/#Conn) and a | ||
[net.Listener](https://golang.org/pkg/net/#Listener) interface implementation | ||
which allows the encrypted transport to be seamlessly integrated into a | ||
codebase. | ||
|
||
The secure messaging scheme implemented within this package is described in | ||
detail in [BOLT #8 of the Lightning Network specifications](https://github.com/lightningnetwork/lightning-rfc/blob/master/08-transport.md). | ||
|
||
This package has intentionally been designed so it can be used as a standalone | ||
package for any projects needing secure encrypted+authenticated communications | ||
between network enabled programs. | ||
|
||
## Installation and Updating | ||
|
||
```bash | ||
$ go get -u github.com/lightningnetwork/lnd/brontide | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
chainntnfs | ||
========== | ||
|
||
[![Build Status](http://img.shields.io/travis/lightningnetwork/lnd.svg)] | ||
(https://travis-ci.org/lightningnetwork/lnd) | ||
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)] | ||
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)] | ||
(http://godoc.org/github.com/lightningnetwork/lnd/chainntnfs) | ||
|
||
The chainntnfs package implements as set of interfaces which allow callers to | ||
receive notifications in response to specific on-chain events. The set of | ||
notifications available include: | ||
|
||
* Notifications for each new block connected to the current best chain. | ||
* Notifications once a `txid` has reached a specified number of | ||
confirmations. | ||
* Notifications once a target outpoint (`txid:index`) has been spent. | ||
|
||
These notifications are used within `lnd` in order to properly handle the | ||
workflows for: channel funding, cooperative channel closures, forced channel | ||
closures, channel contract breaches, sweeping time-locked outputs, and finally | ||
pruning the channel graph. | ||
|
||
This package is intentionally general enough to be applicable outside the | ||
specific use cases within `lnd` outline above. The current sole concrete | ||
implementation of the `ChainNotifier` interface depends on `btcd`. | ||
|
||
## Installation and Updating | ||
|
||
```bash | ||
$ go get -u github.com/lightningnetwork/lnd/chainntnfs | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
channeldb | ||
========== | ||
|
||
[![Build Status](http://img.shields.io/travis/lightningnetwork/lnd.svg)] | ||
(https://travis-ci.org/lightningnetwork/lnd) | ||
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)] | ||
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)] | ||
(http://godoc.org/github.com/lightningnetwork/lnd/channeldb) | ||
|
||
The channeldb implements the persistent storage engine for `lnd` and | ||
generically a data storage layer for the required state within the Lightning | ||
Network. The backing storage engine is | ||
[boltdb](https://github.com/boltdb/bolt), an embedded pure-go key-value stored | ||
based off of LMDB. | ||
|
||
The package implements an object-oriented storage model with queries and | ||
mutations flowing through a particular object instance rather than the database | ||
itself. The storage implemented by the objects includes: open channels, past | ||
commitment revocation states, the channel graph which includes authenticated | ||
node and channel announcements, outgoing payments, and invoices | ||
|
||
## Installation and Updating | ||
|
||
```bash | ||
$ go get -u github.com/lightningnetwork/lnd/channeldb | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
lnrpc | ||
===== | ||
|
||
[![Build Status](http://img.shields.io/travis/lightningnetwork/lnd.svg)] | ||
(https://travis-ci.org/lightningnetwork/lnd) | ||
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)] | ||
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)] | ||
(http://godoc.org/github.com/lightningnetwork/lnd/lnrpc) | ||
|
||
This lnrpc package implements both a client and server for `lnd`s RPC system | ||
which is based off of the high-performance cross-platform | ||
[gRPC](http://www.grpc.io/) RPC framework. By default, only the Go | ||
client+server libraries are compiled within the package. In order to compile | ||
the client side libraries for other supported languages, the `protoc` tool will | ||
need to be used to generate the compiled protos for a specific language. | ||
|
||
The following languages are supported as clients to `lnrpc`: C++, Go, Node.js, | ||
Java, Ruby, Android Java, PHP, Python, C#, Objective-C. | ||
|
||
The list of defined RPC's on the main service are the following (with a brief | ||
description): | ||
|
||
* WalletBalance | ||
* Returns the wallet's current confirmed balance in BTC. | ||
* ChannelBalance | ||
* Returns the daemons' available aggregate channel balance in BTC. | ||
* GetTransactions | ||
* Returns a list of on-chain transactions that pay to or are spends from | ||
`lnd`. | ||
* SendCoins | ||
* Sends an amount of satoshis to a specific addresses. | ||
* SubscribeTransactions | ||
* Returns a stream which sends async notifications each time a transaction | ||
is created or one is received that pays to us. | ||
* SendMany | ||
* Allows the caller to create a transaction with an arbitrary fan-out | ||
(many outputs). | ||
* NewAddress | ||
* Returns a new addresses, the following address types are supported: | ||
pay-to-public-key-hash (p2pkh), pay-to-witness-key-hash (p2wkh), and | ||
nested-pay-to-witness-key-hash (np2wkh). | ||
* ConnectPeer | ||
* Connects to a peer identified by a public key and host. | ||
* ListPeers | ||
* Lists all available connected peers. | ||
* GetInfo | ||
* Returns basic data concerning the daemon. | ||
* PendingChannels | ||
* List the number of pending (not fully confirmed) channels. | ||
* ListChannels | ||
* List all active channels the daemon manages. | ||
* OpenChannel | ||
* Attempts to open a channel to a target peer with a specific amount and | ||
push amount. | ||
* SendPayment | ||
* Send a payment over Lightning to a target peer. | ||
* AddInvoice | ||
* Adds an invoice to the daemon. Invoices are automatically settled once | ||
seen as an incoming HTLC. | ||
* ListInvoices | ||
* Lists all stored invoices. | ||
* LookupInvoice | ||
* Attempts to look up an invoice by payment hash (r-hash). | ||
* SubscribeInvoices | ||
* Creates a uni-directional stream which receives async notifications as | ||
the daemon settles invoices | ||
* ListPayments | ||
* List all outgoing Lightning payments the daemon has made. | ||
* DescribeGraph | ||
* Returns a description of the known channel graph from the PoV of the | ||
node. | ||
* GetChanInfo | ||
* Returns information for a specific channel identified by channel ID. | ||
* GetNodeInfo | ||
* Returns information for a particular node identified by its identity | ||
public key. | ||
* QueryRoute | ||
* Queries for a possible route to a target peer which can carry a certain | ||
amount of payment. | ||
* GetNetworkInfo | ||
* Returns some network level statistics. | ||
* SetAlias | ||
* Sets the node alias whchi is to be advertised on the network. | ||
|
||
## Installation and Updating | ||
|
||
```bash | ||
$ go get -u github.com/lightningnetwork/lnd/lnrpc | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
lnwallet | ||
========= | ||
|
||
[![Build Status](http://img.shields.io/travis/lightningnetwork/lnd.svg)] | ||
(https://travis-ci.org/lightningnetwork/lnd) | ||
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)] | ||
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)] | ||
(http://godoc.org/github.com/lightningnetwork/lnd/lnwallet) | ||
|
||
The lnwallet package implements an abstracted wallet controller that is able to | ||
drive channel funding workflows, a number of script utilities, witness | ||
generation functions for the various Lightning scripts, revocation key | ||
derivation, and the commitment update state machine. | ||
|
||
The package is used within `lnd` as the core wallet of the daemon. The wallet | ||
itself is composed of several distinct interface that decouple the | ||
implementation of things like signing and blockchain access. This separation | ||
allows new `WalletController` implementations to be be easily dropped into | ||
`lnd` without disrupting the code base. A series of integration tests at the | ||
interface level are also in place to ensure conformance of the implementation | ||
with the interface. | ||
|
||
|
||
## Installation and Updating | ||
|
||
```bash | ||
$ go get -u github.com/lightningnetwork/lnd/lnwallet | ||
``` |
Oops, something went wrong.