You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Rusty Russell e3d966c102 type_to_string: add channel_id 8 years ago
bitcoin type_to_string: add secp256k1_pubkey 8 years ago
ccan ccan: forgotten test files after last update. 8 years ago
contrib pytest: Separating new lightningd and legacy lightningd RPC client 8 years ago
daemon log: Flushing logs on each new entry 8 years ago
doc doc: add lightning-waitinvoice man page. 8 years ago
libsodium@fce6852d64 libsodium: add as submodule. 8 years ago
lightningd lightningd/Makefile: fix check-source 8 years ago
secp256k1 libsecp256k1: update. 8 years ago
test sphinx: Committing the onion packet to the payment-hash 8 years ago
tests Merge pull request #115 from ElementsProject/pytest-pathfix 8 years ago
tools tools/generate-wire.py: don't allocate on unknown names. 8 years ago
wire type_to_string: add channel_id 8 years ago
.gitignore gitignore: Ignoring some of the test-binaries. 8 years ago
.gitlab-ci.yml Add .gitlab-ci.yml 8 years ago
.gitmodules libsodium: add as submodule. 8 years ago
HACKING.md controlled_time: remove 8 years ago
INSTALL.md libsodium: use our local submodule. 8 years ago
LICENSE licensing: Make license explicit. 9 years ago
Makefile pytest: Added pytest target to Makefile 8 years ago
README.md README.md: add "upgrade" instructions and add port config for public nodes. 8 years ago
TODO.md TODO: remove to-dones. 8 years ago
check-bolt.c check-bolt: use new BOLTs. 8 years ago
close_tx.c Use global secp256k1_ctx instead of passing it around. 8 years ago
close_tx.h Use global secp256k1_ctx instead of passing it around. 8 years ago
find_p2sh_out.c scripteq: simple helper for comparing scripts. 9 years ago
find_p2sh_out.h Remove unused script functions now we use witness. 9 years ago
irc.c Merge remote-tracking branch 'origin/pr/44' 8 years ago
irc.h Merge remote-tracking branch 'origin/pr/44' 8 years ago
lightning.pb-c.c proto: Added nested_pkt 8 years ago
lightning.pb-c.h proto: Added nested_pkt 8 years ago
lightning.proto proto: Added nested_pkt 8 years ago
opt_bits.c opt_bits: parsing routines for 'bits' == 100 satoshi. 10 years ago
opt_bits.h header cleanup: sort include lines into alpha order, after config.h 9 years ago
overflows.h daemon: routing infrastructure. 8 years ago
permute_tx.c permute_tx: don't save permutation map. 8 years ago
permute_tx.h permute_tx: don't save permutation map. 8 years ago
protobuf_convert.c type_to_string: move formatting to appropriate files. 8 years ago
protobuf_convert.h Use global secp256k1_ctx instead of passing it around. 8 years ago
remove_dust.h channel: remove htlcs array. 8 years ago
status.c status: don't send overlarge messages. 8 years ago
status.h status: API for status reporting. 8 years ago
type_to_string.c type_to_string: move formatting to appropriate files. 8 years ago
type_to_string.h type_to_string: add channel_id 8 years ago
utils.c utils: add tal_hex() helper. 8 years ago
utils.h utils: add tal_hex() helper. 8 years ago
version.c getinfo: add version information 8 years ago
version.h options: --help and --version are early args. 8 years ago

README.md

Lightning Protocol Reference Implementation

In this repository we're developing a reference implementation of bitcoin lightning (see: http://lightning.network which proposed the original "lightning network").

This implementation is being developed in parallel with the protocol definition, which you can find on my fork of the protocol description repository.

If you're interested in using the daemon to test payments, the JSON-RPC interface is documented in the following manual pages:

Steps:

  1. If you're running a previous version, you'll need to shut it down (maybe close channels first) and delete the $HOME/.lightning directory.
  2. Install and compile the requirements.
  3. Make sure bitcoind is running in testnet mode, and has the latest blocks.
  4. Get some test bitcoins, such as from TPs' testnet faucet.
  5. If you want others to connect to your lightningd, create $HOME/.lightning/config and put port=8334 in it (or any other port).
  6. Run daemon/lightningd.
  7. Run daemon/lightning-cli getinfo to check it's working.
  8. Find a node using daemon/lightning-cli getnodes (this will populate over time).
  9. Create a new connection to the node using contrib/lightning-open-channel ADDRESS PORT AMOUNT where AMOUNT is in BTC (.04294967 is the maximum possible). If successful, this will return only once a block has been mined with the funding transaction in it.
  10. You can create more channels if you wish.
  11. You can accept payment using daemon/lightning-cli invoice MILLISATOSHI LABEL; it will give you a payment hash to give to the payer.
  12. You can send payments using contrib/lightning-pay DEST-ID MILLISATOSHI PAYMENT-HASH.

Final note: This is very much a testbed and work in progress; expect All The Things to change, all the time.

Welcome aboard!

Rusty.