Browse Source

Fill out TODO.md into a useful list (mainly by grepping for FIXMEs).

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ppa-0.6.1
Rusty Russell 9 years ago
parent
commit
01820a1a5a
  1. 2
      HACKING.md
  2. 70
      TODO.md

2
HACKING.md

@ -5,7 +5,7 @@ This repository contains a prototype for testing the lightning protocols.
Getting Started
---------------
It's in C, to encourage alternate implementations. It uses the Linux
coding style. Patches are welcome! Just look for FIXME if you want
coding style. Patches are welcome! See the TODO.md file if you want
ideas.
To read the code, you'll probably need to understand ccan/tal: it's a

70
TODO.md

@ -1,7 +1,69 @@
Looking for things to hack on? Great, here's a partial list:
# Looking for things to hack on? #
* Wean off openssl's -lcrypto: use libsodium for all RNG, gmp for base58.
* Grep for FIXME and fix one :)
* Look on https://github.com/ElementsProject/lightning/issues
I've marked things as simple if you want something easy to work on!
## Cleanups ##
* Wean off openssl's -lcrypto
* (simple) use libsodium for all RNG
* (simple) use libbase58
* Remove our specific libsecp256k1 in secp256k1/ and use the installed one.
* Implement `sig_valid`, using `secp256k1_ecdsa_signature_normalize`
* Use `secp256k1_ecdsa_signature_parse_compact`/`_serialize_compact` in `signature_to_proto`
## Minor improvements ##
* Optimize `bitcoind_poll_transactions` not to list all transactions every time
* Make `json_get_params` fail if unknown parameters are specified by user.
* Print backtrace in `log_crash`
* Support locktime in blocks in `accept_pkt_open`, `accept_pkt_htlc_add`, `commit_tx_depth`
* Get bitcoind's idea of time for `commit_tx_depth`, not our wall clock.
* When unpacking a packet, reject any with an unknown odd-numbered field as per BOLT #2.
* Provide details (string) when a command fails because state() returns CMD_FAIL
* logging: add `log_struct()` for common structs.
* `state_single` should only kill the specific peer when it enters an error state.
* Limit total number of peers in `new_peer`, or at least in `peer_connected_in`.
* logging: add IO logging for peers.
* implement on-chain HTLCs correctly (`peer_watch_our_htlc_outputs` etc in peer.c).
* Add `history` RPC command which shows all prior commit txs.
* Improve `getpeers` to show status of peers when connecting, DNS lookups etc.
* Add pings to protocol
* Timeout a peer if they don't respond in a given time (eg. 2 pings)
* Add timers to drop peer if we approach timeout for HTLCs and they're still
uncommitted to closing it (see BOLT #2 "Risks With HTLC Timeouts").
## Testing: ##
* Add more unit tests in bitcoin/test.
* Test more scenarios with daemon/test/test.sh
* Implement compile-time crypto-free mode
* Implement canned conversation files for fuzz testing (eg AFL).
* Write canned input/output test cases for various conversations, and
include them in a form suitable for other implementations to test.
## Major improvements: ##
* Use dynamic fee calculation for initial commitment fee rate.
* (MAJOR) Implement fee renegotiation acceptance.
* (MAJOR) Implement fee renegotiation as fee rate changes.
* Don't fail funding if fees insufficient, fall back as per BOLT #2.
* (MAJOR) Do proper close, still allowing ongoing HTLCs to resolve.
* (MAJOR) Use segregated witness for all transactions.
* (MAJOR) Implement reconnection.
* Save preimages in shachain.
* (MAJOR) Implement persistence.
* (MAJOR) Implement onion
* (MAJOR) Implement routing
* (MAJOR) Implement failure messages
## Other ##
* Grep for other FIXMEs and fix one :)
* Look on https://github.com/ElementsProject/lightning/issues
Happy hacking!<br>
Rusty.

Loading…
Cancel
Save