, ,

No Internet? You Could Still Use Bitcoin on the Lightning Network

Bitcoin lightning network with a phone with no wifi inside.

No access to the internet? In addition to not being able to browse tweets or the latest heart-melting cat eating corn on the cob video, lack of a connection means users can’t make Bitcoin payments.

Researchers have long been exploring how to get around this problem in the case of natural disasters or in areas of the world where internet access is spottier. Wireless computer researcher Ahmet Kurt pointed to the 2017 hurricane in Florida as an example. “There was a huge power outage. People were desperate. Unless you have cash, how are you going to pay for stuff? That was very troubling,” he told Decrypt.

No access to the internet? In addition to not being able to browse tweets or the latest heart-melting cat eating corn on the cob video, lack of a connection means users can’t make Bitcoin payments.

Researchers have long been exploring how to get around this problem in the case of natural disasters. Or in areas of the world where internet access is spottier. Wireless computer researcher Ahmet Kurt pointed to the 2017 hurricane in Florida as an example. “There was a huge power outage. People were desperate. Unless you have cash, how are you going to pay for stuff? That was very troubling,” he told Decrypt.

Instead of the Internet, they used local “mesh networks.” Where nodes are connected directly via Bluetooth and WiFi, building a local Lightning Network they call LNMesh.

Their results? They say, under the right circumstances, offline Lightning Payments should be feasible.

“Our proposed approaches work well and can achieve success rates up to 95 [percent] on large mobile wireless mesh networks”—at least when Lightning channels have sufficient liquidity, the paper explains.

The experiment

Diving into the details of their research, their first finding was that no changes need to be made to the existing Lightning protocol or code in order to get offline payments working.

Then they began their experiments. First they needed to set up a network of Bitcoin and Lightning nodes, which are the foundation of the digital currency. Nodes make up the foundations of Bitcoin and Lightning. Any time a user sends a Bitcoin transaction, they need to be connected to a node.

The researchers set these nodes up on eight Raspberry Pis—small, standalone computers that cost less than $100 a pop.

They then spread these nodes across their university. But instead of connecting these nodes to each other via the internet, as they usually would, they connected them in a local mesh network using WiFi and Bluetooth.

Luckily, even under these humble circumstances, they were successfully able to send Lightning payments back and forth between the nodes.

“The Lightning Network protocol allows such offline payments to settle since the payments are off-chain and not recorded to the Bitcoin blockchain. Thus, as long as nodes can communicate with each other through wireless technologies such as WiFi or Bluetooth, they can perform offline LN payments,” the research paper explains.

The researchers have open sourced their code and results for hyper-curious users who would like to try out the experiment for themselves.

Async payments?

Kurt et al’s research differs from past research on asynchronous payments. Which also offers a form of offline payments, but in a different set of circumstances.

Asynchronous payments allow for a node that’s online to send payments to a node that’s temporarily offline. This offers a UX improvement for the Lightning Network. As async payments click into place, users will be able to send payments to users even if they’re offline, instead of getting a dreaded “failed payment” error.

LNMesh, on the other hand, goes a step further. It shows how Lightning can work when all nodes are offline. Showing that it’s possible to set up channels and send payments only with WiFi and Bluetooth.

But, as Kurt explained, the tricky part is coordinating these channels from the outset. The paper explains: “Our problem boils down to the following: Given a community of people moving around in a neighborhood during a day, how to decide who opens a channel to who so that the overall success rate of the payments in the network will be satisfactory when people do not have access to the Internet?”

Users need to find a way to coordinate an efficient way of opening channels with other users. In the paper, they look at different ways of analyzing users’ “mobility patterns.” Or where users are during the day in relation to other Lightning nodes or merchants or markets. In order to make better decisions about where they should open channels to increase chances of connection. In the future this sort of coordination could be automated.

So while Kurt and co. have helped to show that Lightning payments are indeed possible, it’s still going to take a lot of work to make them smooth and practical.

Source