Skip to content

LukasRada/DotNetLightning.Kiss

 
 

Repository files navigation

DotNetLightning: The utility for working with the Bitcoin Lightning Network (LN) in C#, F#

The main entry point is DotNetLightning.Core.

Installation

The package is compiled and published with two variants

  • DotNetLightning
    • This does not use native bindings for cryptographic operations.
    • This is the one you want to use if you run your code everywhere, but possibly slower than below.
  • DotNetLightning.Core
    • This uses a pre-compiled libsodium for cryptographic operations.
    • It only supports windows, mac and linux environments.
    • This is what you want if you need performance and the environments above are the only ones you are planning to support.

run dotnet add package with the one you want. Currently it is in alpha, so you probably want to install a latest version by specifying it with --version. The version is prefixed with git commit hash and date. Please take a look at the nuget page.

Features

Features in DotNetLightning.* sub-namespaces.

DotNetLightning.Utils

Contains a low-level primitives for LN. Mostly it is for internal usage but some are useful for consumer's point of view. (e.g. LNMoney to represent milli-satoshis value)

DotNetLightning.Serialization

Contains items for wire-protocol. FeatureBits, TLV, and P2P messages.

DotNetLightning.Crypto

Contains modules and types for working with Cryptographic operations. For example LN-onion network encoding, aezeed for seed backups

DotNetLightning.Chain

Interface to inject I/O (e.g. Signing key and Blockchain-interaction)

DotNetLightning.Transactions

This is a module for creating LN-specific Transactions. Mostly for internal usage.

DotNetLightning.Peer

Handles handshake and encryption against other peers

DotNetLightning.Channel

Handles channel state. This module is pretty much WIP. not sure if we can finish. (This is the most complex part in the LN protocol.)

DotNetLightning.Payment

Contains primitives for Payment-related operation. The most important class is PaymentRequest, a.k.a bolt11-invoice, LN-invoice.

It also contains primitives for LSAT, the LN based http authentication mechanism. See here for PoC of AspNetCore middleware for LSAT.

DotNetLightning.Routing

Module for calculating payment route. This is still much WIP.

Other features

Some sibling packages come together when you install DotNetLightning or DotNetLightning.Core These are mostly for internal usages but some might be useful for you.

AEZ

which contains managed code for aez cipher scheme.

It may be useful if you want to secure your data before saving it to disk. See official page for the detail: https://www.cs.ucdavis.edu/~rogaway/aez/index.html

Macaroon

Which contains macaroon authentication token.

The api is mostly the same with libmacaroon See libmacaroon's readme for the usage.

About

Lightning network daemon with F# (alpha)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • F# 64.8%
  • C# 35.2%