Difference between revisions of "Challenges May 2020"

From fulmo
Jump to navigation Jump to search
m (Protected "Challenges May 2020" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)))
 
(55 intermediate revisions by 21 users not shown)
Line 2: Line 2:
 
==Projects with Challenges==
 
==Projects with Challenges==
  
This is the list of Lightning Network related projects that registered for the HackSprint so far:
+
This is the list of Lightning Network related projects that registered for this HackSprint:
  
 
===RaspiBlitz===
 
===RaspiBlitz===
Line 13: Line 13:
  
 
'''Outcome:'''
 
'''Outcome:'''
* Repaired some peoples RaspiBlitzes
+
* Introductions into the RaspiBlitz v1.5 Release
* Plans on reviving BlitzD in the future
+
* Running tests on Routers public IP discovery
* Testing new ways of detecting public IP of RaspiBlitz
+
* Experimental Faraday Install Script
* Helped other RaspiBlitz related projects
+
* Experimental Thunderhub install Script
 
+
* JoinMarket ease of use hacks and menu
===LightningATM===
 
 
 
Github issues with label "hackathon": [https://github.com/21isenough/LightningATM/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon github.com/21isenough/LightningATM]
 
 
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-lightningatm
 
  
 
===LNbits===
 
===LNbits===
Line 33: Line 28:
  
 
see video: https://www.youtube.com/watch?v=xnHz6NbTgZg
 
see video: https://www.youtube.com/watch?v=xnHz6NbTgZg
 
===RTL (Ride The Lightning)===
 
 
https://github.com/Ride-The-Lightning/RTL
 
 
Github issues with label 'hackathon': https://github.com/Ride-The-Lightning/RTL/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon
 
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rtl-ride-the-lightning
 
  
 
===Quickening - Room77 Point of Sale===
 
===Quickening - Room77 Point of Sale===
  
 
Github issues starting with "Room77" https://github.com/arcbtc/M5StackSats/issues
 
Github issues starting with "Room77" https://github.com/arcbtc/M5StackSats/issues
 
Please work on the branch"payment_connector" use the version in the folder [https://github.com/arcbtc/M5StackSats/tree/payment_connector/TheQuickening "TheQuickening"]
 
  
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-pos-room77-quickening
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-pos-room77-quickening
  
===Lightnite===
+
===TOR2IP-Tunnelservice===
  
Challenges: https://issues.lightnite.io
+
A service to give a Lightning node running behind TOR a port on a public IP address.
 +
 +
Subpage with Challenge: [[TOR2IP-Tunnelservice]]
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-lightnite-game
+
Web service pooling servers (frennkie): https://github.com/frennkie/django-ip2tor
  
===Specter-Desktop===
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-tor2ip-tunnelservice
  
Quickinfo on Specter: https://twitter.com/CryptoAdvance/status/1233833767283941376?s=20
+
===Wiki Lightning Spam Protection===
  
Challenge: https://github.com/rootzoll/raspiblitz/issues/1059#issuecomment-605526623
+
Turn this prototype https://github.com/thorie7912/LightningPayment to add a Lightning SpamProtection into a [https://en.wikipedia.org/wiki/MediaWiki_extension Media Wiki Extension] thats easy to install and config on a standard Media Wiki.
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-specter-desktop
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/media-wiki-spam-protection
  
'''Outcomes:'''
+
===SendMany App===
* People were testing different hardware wallets
 
* k9ert: Fixed Bug on RaspiBlitz install https://github.com/rootzoll/raspiblitz/pull/1108/
 
  
===TOR2IP-Tunnelservice===
+
Challenges: https://github.com/fusion44/sendmany/issues?q=is%3Aissue+is%3Aopen+label%3Ahacksprint
  
A service to give a Lightning node running behind TOR a port on a public IP address.
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-keysendsendmany
 
Subpage with Challenge: [[TOR2IP-Tunnelservice]]
 
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-tor2ip-tunnelservice
+
'''Outcome''':
  
'''Outcome:'''
+
Worked on fetching invoices / messages in a background thread.  
* Emzy: Proof-of-Concept TOR2IP witch socat
 
* Openoms: SetUp-Tutorial: https://github.com/openoms/bitcoin-tutorials/blob/master/tor2ip_tunnel.md
 
* k9ert: prototyping multiuser-frontend (web service with Lightning Payment)
 
  
===SendMany App===
+
This can be used to finally implement notifications.
  
Project Info: https://github.com/fusion44/sendmany
+
(Unfortunately, nothing to show yet)
  
Challenge: https://github.com/rootzoll/raspiblitz/issues/1000#issuecomment-605526180
+
===Zapread.com===
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-keysendsendmany
+
Develop a C# LNURL-AUTH library which can integrate with .NET (MVC) websites.
  
'''Outcome:'''
+
List of Challenges: https://github.com/Horndev/zapread.com/issues?q=is%3Aopen+is%3Aissue+label%3Ahackathon
* Made a keysend chat over a RaspiBlitz with keysend activated (3 hops on LN)
 
* Add SendMany App to the RaspiBlitz for install
 
  
===Wiki Lightning Spam Protection===
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-zapread
  
Turn this prototype https://github.com/thorie7912/LightningPayment to add a Lightning SpamProtection into a [https://en.wikipedia.org/wiki/MediaWiki_extension Media Wiki Extension] thats easy to install and config on a standard Media Wiki.
+
'''Outcome:'''
 +
* Set up demonstration project on github at https://github.com/Horndev/lnurl.net
 +
* Research on protocol and starting references identified in issue tracker (linked above)
 +
* Foundation for middleware in place
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/media-wiki-spam-protection
+
===LightningATM===
  
===The Eye of Satoshi (python-teos)===
+
Github issues with label "hackathon": [https://github.com/21isenough/LightningATM/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon github.com/21isenough/LightningATM] (Python)
  
The Eye of Satoshi is a Lightning watchtower compliant with BOLT13, written in Python 3.
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-lightningatm
  
Github issues with label "hackathon": [https://github.com/talaia-labs/python-teos/labels/hackathon github.com/talaia-labs/python-teos]
+
===Bitcoin Bounty Hunt (Online FPS)===
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-the-eye-of-satoshi
+
Challenges coming up.
  
===Exchange Union/OpenDEX===
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/bitcoin-bounty-hunt-online-fps
  
Integrate c-lightning as swap client (and more): https://github.com/ExchangeUnion/xud/issues?q=is%3Aopen+is%3Aissue+label%3Ahackathon
+
===Weenode===
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-opendex
+
This is the new name for the [https://blog.bitcoinprivacy.net/2019/12/20/news-from-the-cheapnode-project/ cheapnode project]: Building the cheapest possible bitcoin fullnode (+lightning and other services) on old Android phones.
  
===getroutevia: a c-lightning plugin for route search with restrictions===
+
Help wanted on [https://github.com/bitcoinprivacy/weenode/labels/hacksprint Github issues with label "hacksprint"]
  
Find routes that satisfy additional criteria, for instance, must go through certain nodes. More info and discussion here: https://github.com/s-tikhomirov/getroutevia/issues/1
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-weenode
 
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-getroutevia-c-lightning-plugin
 
 
 
The initial version is implemented, it lets you specify a list of nodes that a route must go through. Apart from this extra parameter, the usage is similar to getroute. It is possible to enforce either that it goes through all or any of them (you have to modify the source code). Other restrictions are also possible (a simple example is in the code). Some questions I faced are in the [https://github.com/s-tikhomirov/getroutevia/issues/ issues].
 
  
 
===Rust Lightning network node===
 
===Rust Lightning network node===
Line 130: Line 107:
 
* protocols on top of LN (layer 3), like [https://hackmd.io/@lpQxZaCeTG6OJZI3awxQPQ/LN-DLC DLCs on LN] or proposed [https://github.com/LNP-BP/lnpbps/issues/24 Lightspeed payments], which require modification on the structure of the commitment transaction.
 
* protocols on top of LN (layer 3), like [https://hackmd.io/@lpQxZaCeTG6OJZI3awxQPQ/LN-DLC DLCs on LN] or proposed [https://github.com/LNP-BP/lnpbps/issues/24 Lightspeed payments], which require modification on the structure of the commitment transaction.
  
We will try to build a node that is highly modular and is ready for the future LN extensions. More information here: https://github.com/LNP-BP/lnpd
+
Last time we started building new rust LN node based on LNP/BP library — and this time we will continue the challenge! We will work on further node development; for more details you can refer our project backlog and todo issues here: https://github.com/LNP-BP/lnp-node/projects/1
  
During the hackathon we will try to:
+
In brief, we will
* compose core architecture with non-blocking multithreading
+
* update to use the latest version of rust-lightning, that had migrated on new rust-bitcoin type system
* add lightning network wire protocol
+
* update the code to use the lates version of rust-lnpbp library
* implement BOLT-9 (using rust-lightning it should be simple)
+
* improve multi-thread architecture, in particular message bus with ZMQ
* implement BOLT-1: do connection to other LN nodes + send/receive `connect`, `ping` & `ping` messages
+
* complete BOLT-1 implementation
 
* (optionally) implement gossip protocol
 
* (optionally) implement gossip protocol
  
Contact [[User:Dr-Orlovsky]] for details
+
Contact [[User:Dr-Orlovsky]] and check https://github.com/LNP-BP/lnp-node/projects/1 for details
  
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rust-ln-node
 
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rust-ln-node
  
===Weenode===
+
'''Outcome:'''
 +
 
 +
1. The node was updated to use the most recent version of rust-lightning and LNP/BP library:
 +
https://github.com/LNP-BP/lnp-node/commit/5d6fc3d1c85ca35bbcda0bec59b27c641fd07994
 +
 
 +
2. We decided to split input and output parts of the stream into separate threads within peer module of wire connection daemon; however it turned out to be not possible to implement due to the current rust-lightning and rust-lnpbp architectures. In order to fix this:
 +
* we have adopted PR from rust-lightning that modularizes peer components https://github.com/LNP-BP/rust-lightning/commit/d88c59c48da986b1eda6a19334e64494b31958d4
 +
* also we proposed the required changes to it: https://github.com/rust-bitcoin/rust-lightning/pull/494#pullrequestreview-408763344
 +
* made Connection and Peer objects splittable: https://github.com/LNP-BP/rust-lnpbp/commit/92fa54f5a45d3f91e78f39bf67a839fce231f20d , https://github.com/LNP-BP/rust-lnpbp/commit/fe01f5401f96596520f67e7ff4ec665a9855b7c3
 +
 
 +
===RTL (Ride The Lightning)===
 +
 
 +
https://github.com/Ride-The-Lightning/RTL
 +
 
 +
Github issues with label 'hackathon': https://github.com/Ride-The-Lightning/RTL/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon
 +
 
 +
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rtl-ride-the-lightning
 +
 
 +
=== c-lightning ===
 +
 
 +
[[User:Cdecker]] is available on Mattermost for mentoring of c-lightning projects. Feel free to propose your own ideas, and we'll help you design and implement them :-)
  
This is the new name for the [https://blog.bitcoinprivacy.net/2019/12/20/news-from-the-cheapnode-project/ cheapnode project]: Building the cheapest possible bitcoin fullnode (+lightning and other services) on old Android phones.
+
Some ideas for projects / challenges:
  
Help wanted on [https://github.com/bitcoinprivacy/weenode/labels/hacksprint Github issues with label "hacksprint"]
+
* Hardware wallet integration: c-lightning has supported external funding via the `fundchannel_start` and `fundchannel_complete` RPC methods for quite some time, in addition the `close_to` parameter allows you to specify where funds should be sent once the channel closes. These can be combined to have all on-chain funds sourced from a hardware wallet and, after they were borrowed to operate a channel, they can be returned to the hardware wallet. The idea here is to write a plugin that interacts with the hardware wallet to fund channels, so funds are only temporarily controlled by c-lightning.
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-weenode
+
* `hsm_secret` generation from a seed-phrase: c-lightning will securely generate a random seed when first starting a new node. Given the lack of functional backup, and the seed not being sufficient to restore all the state, c-lightning has so not included any seed-phrase to restore the seed. However due to recent improvements both in backups and replicated DB backends, it would be great to also safely store the `hsm_secret` using existing tooling, such as paper backups, encrypted BIP39 seed-phrases, or even steel backups. Goal of this challenge is the creation of a launcher or plugin that takes a seed-phrase and generates the associated `hsm_secret` file.
  
'''Outcome:'''
+
* Trampoline Proof-of-concept: Trampoline routing is a recent proposal to outsource some aspects of route-finding to another node in the neighborhood of the sending node. This is useful for nodes that may be unable to sync the network topology through gossip, or do not have time to sync before they need to send out a payment, e.g., mobile nodes. Using c-lightning's ability to implement custom protocol extensions (`custommsg`) and the ability to create routing onions with arbitrary payloads, you can implement a fast gossiping extension with which nodes announce their ability to route on behalf of others, and the sender to encapsulate the instructions for a trampoline node (where to go and how much to send).
  
* weenode scripts got tested and updated on my own hardware, and finally merged into master
+
* Networked RPC interface: c-lightning is purposefully not exposing its JSON-RPC over the network, in order not to mandate a specific method of interaction. Plugins can take care of exposing the API in a variety of ways (grpc, JSON-RPC, REST, ...) and they can also be used to enforce arbitrary access policies using the `rpc_command` hook. These two aspects can be handled independently, i.e., one plugin exposes the API over some transport while another plugin enforces the authentication and authorization required to access the API. This in turn allows to mix and match arbitrary networked API endpoints and authentication mechanisms. Goal of this challenge is to come up with a generic way to have one plugin expose the API, and pass along any authentication information that was submitted with the request, so another plugin can enforce access policies.
* so now it's time for everybody to get their own weenode running!
 
  
 +
* Backup plugin: https://github.com/lightningd/plugins/tree/master/backup Currently it supports only backup to the local file. There are several rooms for improvement, contact [[User:mrostecki]] if interested.
 +
** "partial file" backend - saving each database change/transaction to a separate file, which will be helpful for ideas below
 +
** PGP backend - based on the "partial file" plugin, which encrypts each file
 +
** Dropbox, Google Drive backends - uploading backups to Dropbox and Google Drive, based on "partial file" backend (to not upload a huge file every time), with optional usage of PGP
  
===Backup plugin for c-lightning===
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/c-lightning, https://mm.fulmo.org/fulmo/channels/x-backup-plugin-c-lightning
  
Backups are a major issue in the Lightning Protocol, given that any sort of
+
==== What was done during the May 2020 HackSprint ====
dataloss could potentially result in loss of funds. This means that restoring
 
an old backup of the database could result in the node broadcasting an old
 
state, which is a cheat attempt in the protocol, which is punished.
 
  
The backup c-lightning plugin (https://github.com/lightningd/plugins/pull/97)
+
* `hsm_secret` - https://github.com/ElementsProject/lightning/issues/3717
implements the basic mechanisms to create a synchronous backup of
+
** Development branches:
any change to the database, and ensures that the backup stays in sync with the
+
*** https://github.com/mrostecki/lightning/tree/bip39
database. It does so in a generic way allowing to write backups to a variety
+
** code in HSM daemon `hsm.c` is mostly done and should be working (although we need to add Python tests covering HSMD launch)
of backends, but initially only implements a file-system based backup backend
+
** currently working input of mnemonic and passphrase in c-lightning, which then will be passed to HSMD
that is located on the same machine, but on a separate disk. Doing so already
 
provides protection against data corruption on the primary disk. Potential
 
future improvements could include:
 
  
* Backup to Google services. Examples include:
+
=== JIT Routing / Sharing balance information ===
** GDrive
 
** Google Docs - Sheets
 
** Google Cloud Storage
 
* Backup to Dropbox
 
* Send backup data to a peer using the custommsg hook
 
* Backups to a dedicated backup server
 
  
In the case of a dedicated backup server the plugin could also manage a
+
**RESULTS**: https://github.com/renepickhardt/plugins/tree/balancesharing-plugin/balancesharing
subscription that is used to pay for the backup service.
 
  
[[User:cdecker]] is available for additional information and mentorship. See his [[User:cdecker|Wiki page]] for contact information.
+
Recent - unpublished / work in progress - research that i am conducting suggests that JIT routing is indeed superior to our current path finding mechanism of probing channels until a path is found as JIT Routing
  
 +
* has on average a higher success rate
 +
* invokes on average less network communication messages to be sent
 +
* on average leaks less information of channel balances of the network to the sender / participating nodes
 +
* seems to prevent channel probing attacks (c.f: https://arxiv.org/abs/2004.00333 )
  
'''Outcome:'''
+
Previous research (c.f.: https://arxiv.org/abs/1912.09555) suggests that even without JIT rebalancing if the channel rebalancing is used proactively and opportunistically by nodes the overall payment success rates and routable amounts increase.
  
* The backup plugin now has a matching `backup-cli` tool to initialize the backend and to restore from a backup
+
Thus on the Lightning Hacksprint we want to start working on a proof of concept implementation of JIT - routing. This effort has two parts:
* In addition to the file-backend we now have a dropbox backend that minimizes bandwidth requirements by splitting the backup into multiple files that are uploaded separately
 
* The Dropbox backend also allows the backup to be GPG encrypted
 
  
===Low Bandwidth Lightning Channels===
+
# a communication protocol for nodes to share balance information with neighbors
 +
# a modified transport layer for fee free rebalancing.
  
There is a need to strengthen the Bitcoin ecosystem for people whose only computing device is a low end mobile phone and who live where Internet access is expensive, unreliable, intermittent or censored. [https://github.com/willcl-ark willcl-ark] created a way to proxy Lightning channels over low-bandwidth communication systems using a c-lightning patch "[https://github.com/willcl-ark/lnproxy/blob/master/clightning/noencrypt_final.patch noencrypt]" and python plugin called [https://github.com/willcl-ark/lnproxy lnproxy]. This plugin is written specifically to use a goTenna radio connected to a computer over USB, but this system can also be adapted for other low-bandwidth channels like SMS (for people who cannot afford mobile internet), LoRa mesh radio or similar systems. [https://github.com/jharveyb jharveyb] is working on [https://github.com/jharveyb/fldigi-proxy fldigi-proxy] to help adapt LNProxy for ham radio and willcl-ark has created a [https://github.com/willcl-ark/lnproxy/commits/2020-02-23-ham fork of lnproxy that uses sockets] to work with the fldigi-proxy.
+
This weekend we will focus mainly on the communication protocol for sharing balance information with peers as an extension of BOLT7 as this would be needed in the JIT case and the proactive rebalancing case.  
 +
If time permits we shall also look at the second goal to achieve fee free rebalancing.  
  
You can read more about LNProxy [https://inthemesh.com/archive/lntenna-python-3/ here] to get an overview of the project.
+
We will write a spec for new gossip messages and provide a proof of concept as a c-lightning plugin.  
 +
If time pemits we also invoke the rebalancing with fees during forwarding of HTLCs - which later can be exchanged with the fee free version.
  
The challenge is to adapt LNProxy to a different low-bandwidth communication method. For example, LoRa radio, Bluetooth or an SMS API.
+
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-jit-routing
  
Chatroom to get started: https://mm.fulmo.org/fulmo/channels/lnproxy
+
==== Background ====
  
[[User:Remyers]] is available for additional information and mentorship. Contact Richard at [https://mm.fulmo.org/fulmo/messages/@remyers @remyers] on fulmo.org or [https://twitter.com/remyers_ @remyers_] on twitter.
+
To participate one should have a good understanding of BOLT1 https://github.com/lightningnetwork/lightning-rfc/blob/master/01-messaging.md  which explains Lightning Messages and be familiar with BOLT07 https://github.com/lightningnetwork/lightning-rfc/blob/master/07-routing-gossip.md which is about the gossip protocol which we plan to extend:
  
=== Point Time Locked Contracts (PTLC) ===
+
JIT Routing is explained at:
 +
https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-March/001891.html
 +
The proposal for 2 (or more) new gossip messages to share balance information is initiated here:
 +
https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-December/002406.html
 +
The Plugin API is documented here:https://github.com/ElementsProject/lightning/blob/master/doc/PLUGINS.mdWe most likely need
 +
* custommsg command
 +
For invoking it at routing time we also need:
 +
* htcl_accepted Hook
  
The current Lightning network uses HTLCs to forward payments across multiple hops.
+
It would be great to also come up with a fee free circular rebalancing protocol and transport but I guess this will not be achievable during the weekend.
There are a lot of proposals for improving the Lightning building on an alternative to HTLCs, so called Point Time Locked Contracts (PTLC).
 
They allow improving privacy ("payment decorrelation"), improving multipath payments ("high AMP"), payments conditional on signatures ("DLCs over Lightning") and more (https://suredbits.com/category/payment-points/).
 
However, it was thought that PTLCs either require complicated cryptography or a Schnorr signature soft fork in Bitcoin.
 
But it turned out that this can be achieved in today's Bitcoin using relative simple cryptography using a construction called "single signer ECDSA adaptors" (https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-November/002316.html).
 
This challenge is about demoing PTLCS using this adaptor construction on mainnet.
 
  
https://mm.fulmo.org/fulmo/channels/poodles
+
=== Executing a DLC (discreet log contract) on Rust Lightning ===
  
Work in progress code: https://github.com/bitcoin-s/secp256k1/pull/2 and https://github.com/jonasnick/secp256k1/pull/14/
+
A discreet log contract is a protocol that allows for the use of oracles in bitcoin. They have been designed such that they can be lifted off of the bitcoin protocol into the Lightning Network.  
  
* https://github.com/LLFourn/one-time-VES
+
The current discreet log contract spec is available here: https://github.com/discreetlogcontracts/dlcspecs
* https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-November/002316.html
 
* Getting started with bitcoin-s: https://bitcoin-s.org/docs/getting-setup
 
* Getting started with libsecp: https://github.com/ElementsProject/secp256k1-zkp
 
  
'''Outcome:'''
+
Here is the github issue describing the work we are trying to accomplish this weekend to execute a DLC on the Lightning Network (using Rust Lightning):  
* Implemented single signer ECDSA adaptor signatures on top of libsecp:  https://github.com/jonasnick/secp256k1/pull/14/
 
* Almost finished GUI that actually executes a PTLC for payer or receiver https://github.com/bitcoin-s/bitcoin-s/pull/1302
 
  
=== Bitcoin Router ===
+
https://github.com/rust-bitcoin/rust-lightning/issues/605#issuecomment-625573830
  
A high powered plug-and-play router built for the modern Internet user running a bitcoin and lightning fullnode, VPN and Tor so that all your private data stays secure inside your home. Find out more here: https://wiki.fulmo.org/index.php?title=Bitcoinrouter
+
Please join us in this chatroom: https://mm.fulmo.org/fulmo/channels/rust-ln-dlc
  
Chatroom to get started: https://router.bitcoin-node.org/mattermost
 
  
'''Outcome'''
+
=== Lightning Donation Tool for Rubygems ===
  
* Run TOR hidden services
+
https://github.com/bumi/bundler-thankyou
* Sync Bitcoin on Turris MOX
 
* Demo for user interface configuration
 
  
'''Challenges'''
+
Outcome: Working Prototype (DemoVideo): https://asciinema.org/a/9MfCfcKLaKu4mp4lT9w4XHr2d?autoplay=1
* One of the main challenges with running on the Mox A out of the box (https://www.turris.cz/en/mox/overview) is that the Marvell Armada 3720 processor is designed to be used on low powered devices that are always on. Syncing the Bitcoin blockchain is processor intensive and can lead to stability issues. Our longer term solution is to come up with our own Mox module which could have its own processor.
 
* We are concerned that hosting blockchain data so close to the router could make it an attractive target for hackers. One solution would be to create our own PCB with a dedicated CPU for all blockchain data and tasks.
 
* We would love to get feedback on security issues and very much welcome the help of anyone with experience in WRT.
 
  
=== Build a LApp ===
+
==Need more ideas?==
  
Looking for yet another idea to build a small LApp? Check out [[ideas for LApps]]!
+
Looking for yet another idea to build a small LApp? Check out [[Ideas for LApps]]!
  
 
==Adding your Project==
 
==Adding your Project==
  
Feel free to add a challenge yourself! The wiki is open to any Bolter (you'll figure out how to edit). If you have a GitHub Repo best practice is to put the label "hackathon" (yellow) next to issues you like people to join/help for the weekend. If you added a challenge please also get in touch on [https://mm.fulmo.org/fulmo/channels/lightning-hacksprint Mattermost] for more information and collaboration.
+
Feel free to add a challenge yourself! Ask Jeff or Rootzoll on the [https://mm.fulmo.org Mattermost] for the password to edit the Wiki-Page. If you have a GitHub Repo best practice is to put the label "hackathon" (yellow) next to issues you like people to join/help for the weekend. If you added a challenge please also get in touch on [https://mm.fulmo.org/fulmo/channels/lightning-hacksprint Mattermost] for more information and collaboration.

Latest revision as of 11:32, 13 March 2021

Projects with Challenges

This is the list of Lightning Network related projects that registered for this HackSprint:

RaspiBlitz

Github issues with label "hackathon": https://github.com/rootzoll/raspiblitz/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon

Video helping you to get started with RaspiBlitz development: https://youtu.be/qTHDkFppsz0

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/raspiblitz

Outcome:

  • Introductions into the RaspiBlitz v1.5 Release
  • Running tests on Routers public IP discovery
  • Experimental Faraday Install Script
  • Experimental Thunderhub install Script
  • JoinMarket ease of use hacks and menu

LNbits

https://github.com/arcbtc/lnbits

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-lnbits

In a push to get lnbits new update out and extend its functionality, x3 0.03btc bounties are available for anyone developing extensions. If you're interested in making an extension, pop into the stream for a chat. If the community likes the idea, you can make it and on completion get one of the bounties!

see video: https://www.youtube.com/watch?v=xnHz6NbTgZg

Quickening - Room77 Point of Sale

Github issues starting with "Room77" https://github.com/arcbtc/M5StackSats/issues

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-pos-room77-quickening

TOR2IP-Tunnelservice

A service to give a Lightning node running behind TOR a port on a public IP address.

Subpage with Challenge: TOR2IP-Tunnelservice

Web service pooling servers (frennkie): https://github.com/frennkie/django-ip2tor

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-tor2ip-tunnelservice

Wiki Lightning Spam Protection

Turn this prototype https://github.com/thorie7912/LightningPayment to add a Lightning SpamProtection into a Media Wiki Extension thats easy to install and config on a standard Media Wiki.

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/media-wiki-spam-protection

SendMany App

Challenges: https://github.com/fusion44/sendmany/issues?q=is%3Aissue+is%3Aopen+label%3Ahacksprint

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-keysendsendmany

Outcome:

Worked on fetching invoices / messages in a background thread.

This can be used to finally implement notifications.

(Unfortunately, nothing to show yet)

Zapread.com

Develop a C# LNURL-AUTH library which can integrate with .NET (MVC) websites.

List of Challenges: https://github.com/Horndev/zapread.com/issues?q=is%3Aopen+is%3Aissue+label%3Ahackathon

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-zapread

Outcome:

  • Set up demonstration project on github at https://github.com/Horndev/lnurl.net
  • Research on protocol and starting references identified in issue tracker (linked above)
  • Foundation for middleware in place

LightningATM

Github issues with label "hackathon": github.com/21isenough/LightningATM (Python)

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-lightningatm

Bitcoin Bounty Hunt (Online FPS)

Challenges coming up.

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/bitcoin-bounty-hunt-online-fps

Weenode

This is the new name for the cheapnode project: Building the cheapest possible bitcoin fullnode (+lightning and other services) on old Android phones.

Help wanted on Github issues with label "hacksprint"

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-weenode

Rust Lightning network node

Another LN node? Why we need it?

The problem with the existing Lightning node implementations is their very limited extensibility for such things as:

  • future LN upgrades (channel factories, pay-to-ec-point, taproot),
  • protocols on top of LN (layer 3), like DLCs on LN or proposed Lightspeed payments, which require modification on the structure of the commitment transaction.

Last time we started building new rust LN node based on LNP/BP library — and this time we will continue the challenge! We will work on further node development; for more details you can refer our project backlog and todo issues here: https://github.com/LNP-BP/lnp-node/projects/1

In brief, we will

  • update to use the latest version of rust-lightning, that had migrated on new rust-bitcoin type system
  • update the code to use the lates version of rust-lnpbp library
  • improve multi-thread architecture, in particular message bus with ZMQ
  • complete BOLT-1 implementation
  • (optionally) implement gossip protocol

Contact User:Dr-Orlovsky and check https://github.com/LNP-BP/lnp-node/projects/1 for details

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rust-ln-node

Outcome:

1. The node was updated to use the most recent version of rust-lightning and LNP/BP library: https://github.com/LNP-BP/lnp-node/commit/5d6fc3d1c85ca35bbcda0bec59b27c641fd07994

2. We decided to split input and output parts of the stream into separate threads within peer module of wire connection daemon; however it turned out to be not possible to implement due to the current rust-lightning and rust-lnpbp architectures. In order to fix this:

RTL (Ride The Lightning)

https://github.com/Ride-The-Lightning/RTL

Github issues with label 'hackathon': https://github.com/Ride-The-Lightning/RTL/issues?q=is%3Aissue+is%3Aopen+label%3Ahackathon

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-rtl-ride-the-lightning

c-lightning

User:Cdecker is available on Mattermost for mentoring of c-lightning projects. Feel free to propose your own ideas, and we'll help you design and implement them :-)

Some ideas for projects / challenges:

  • Hardware wallet integration: c-lightning has supported external funding via the `fundchannel_start` and `fundchannel_complete` RPC methods for quite some time, in addition the `close_to` parameter allows you to specify where funds should be sent once the channel closes. These can be combined to have all on-chain funds sourced from a hardware wallet and, after they were borrowed to operate a channel, they can be returned to the hardware wallet. The idea here is to write a plugin that interacts with the hardware wallet to fund channels, so funds are only temporarily controlled by c-lightning.
  • `hsm_secret` generation from a seed-phrase: c-lightning will securely generate a random seed when first starting a new node. Given the lack of functional backup, and the seed not being sufficient to restore all the state, c-lightning has so not included any seed-phrase to restore the seed. However due to recent improvements both in backups and replicated DB backends, it would be great to also safely store the `hsm_secret` using existing tooling, such as paper backups, encrypted BIP39 seed-phrases, or even steel backups. Goal of this challenge is the creation of a launcher or plugin that takes a seed-phrase and generates the associated `hsm_secret` file.
  • Trampoline Proof-of-concept: Trampoline routing is a recent proposal to outsource some aspects of route-finding to another node in the neighborhood of the sending node. This is useful for nodes that may be unable to sync the network topology through gossip, or do not have time to sync before they need to send out a payment, e.g., mobile nodes. Using c-lightning's ability to implement custom protocol extensions (`custommsg`) and the ability to create routing onions with arbitrary payloads, you can implement a fast gossiping extension with which nodes announce their ability to route on behalf of others, and the sender to encapsulate the instructions for a trampoline node (where to go and how much to send).
  • Networked RPC interface: c-lightning is purposefully not exposing its JSON-RPC over the network, in order not to mandate a specific method of interaction. Plugins can take care of exposing the API in a variety of ways (grpc, JSON-RPC, REST, ...) and they can also be used to enforce arbitrary access policies using the `rpc_command` hook. These two aspects can be handled independently, i.e., one plugin exposes the API over some transport while another plugin enforces the authentication and authorization required to access the API. This in turn allows to mix and match arbitrary networked API endpoints and authentication mechanisms. Goal of this challenge is to come up with a generic way to have one plugin expose the API, and pass along any authentication information that was submitted with the request, so another plugin can enforce access policies.
  • Backup plugin: https://github.com/lightningd/plugins/tree/master/backup Currently it supports only backup to the local file. There are several rooms for improvement, contact User:mrostecki if interested.
    • "partial file" backend - saving each database change/transaction to a separate file, which will be helpful for ideas below
    • PGP backend - based on the "partial file" plugin, which encrypts each file
    • Dropbox, Google Drive backends - uploading backups to Dropbox and Google Drive, based on "partial file" backend (to not upload a huge file every time), with optional usage of PGP

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/c-lightning, https://mm.fulmo.org/fulmo/channels/x-backup-plugin-c-lightning

What was done during the May 2020 HackSprint

JIT Routing / Sharing balance information

Recent - unpublished / work in progress - research that i am conducting suggests that JIT routing is indeed superior to our current path finding mechanism of probing channels until a path is found as JIT Routing

  • has on average a higher success rate
  • invokes on average less network communication messages to be sent
  • on average leaks less information of channel balances of the network to the sender / participating nodes
  • seems to prevent channel probing attacks (c.f: https://arxiv.org/abs/2004.00333 )

Previous research (c.f.: https://arxiv.org/abs/1912.09555) suggests that even without JIT rebalancing if the channel rebalancing is used proactively and opportunistically by nodes the overall payment success rates and routable amounts increase.

Thus on the Lightning Hacksprint we want to start working on a proof of concept implementation of JIT - routing. This effort has two parts:

  1. a communication protocol for nodes to share balance information with neighbors
  2. a modified transport layer for fee free rebalancing.

This weekend we will focus mainly on the communication protocol for sharing balance information with peers as an extension of BOLT7 as this would be needed in the JIT case and the proactive rebalancing case. If time permits we shall also look at the second goal to achieve fee free rebalancing.

We will write a spec for new gossip messages and provide a proof of concept as a c-lightning plugin. If time pemits we also invoke the rebalancing with fees during forwarding of HTLCs - which later can be exchanged with the fee free version.

Chatroom to get started: https://mm.fulmo.org/fulmo/channels/x-jit-routing

Background

To participate one should have a good understanding of BOLT1 https://github.com/lightningnetwork/lightning-rfc/blob/master/01-messaging.md  which explains Lightning Messages and be familiar with BOLT07 https://github.com/lightningnetwork/lightning-rfc/blob/master/07-routing-gossip.md which is about the gossip protocol which we plan to extend:

JIT Routing is explained at: https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-March/001891.html The proposal for 2 (or more) new gossip messages to share balance information is initiated here: https://lists.linuxfoundation.org/pipermail/lightning-dev/2019-December/002406.html The Plugin API is documented here:https://github.com/ElementsProject/lightning/blob/master/doc/PLUGINS.mdWe most likely need

  • custommsg command

For invoking it at routing time we also need:

  • htcl_accepted Hook

It would be great to also come up with a fee free circular rebalancing protocol and transport but I guess this will not be achievable during the weekend.

Executing a DLC (discreet log contract) on Rust Lightning

A discreet log contract is a protocol that allows for the use of oracles in bitcoin. They have been designed such that they can be lifted off of the bitcoin protocol into the Lightning Network.

The current discreet log contract spec is available here: https://github.com/discreetlogcontracts/dlcspecs

Here is the github issue describing the work we are trying to accomplish this weekend to execute a DLC on the Lightning Network (using Rust Lightning):

https://github.com/rust-bitcoin/rust-lightning/issues/605#issuecomment-625573830

Please join us in this chatroom: https://mm.fulmo.org/fulmo/channels/rust-ln-dlc


Lightning Donation Tool for Rubygems

https://github.com/bumi/bundler-thankyou

Outcome: Working Prototype (DemoVideo): https://asciinema.org/a/9MfCfcKLaKu4mp4lT9w4XHr2d?autoplay=1

Need more ideas?

Looking for yet another idea to build a small LApp? Check out Ideas for LApps!

Adding your Project

Feel free to add a challenge yourself! Ask Jeff or Rootzoll on the Mattermost for the password to edit the Wiki-Page. If you have a GitHub Repo best practice is to put the label "hackathon" (yellow) next to issues you like people to join/help for the weekend. If you added a challenge please also get in touch on Mattermost for more information and collaboration.