Offline Lightning-enabled Vending Machines



Summary:

A solution has been proposed for vending machines to avoid theft. The machine must be offline and without secret keys, however, the owner has a separate Lightning node to receive payments. The solution involves each machine containing a fixed number of hashes and invoice signatures corresponding to each hash. Each hash has a 1-bit flag that is set to 1 when claimed. When a customer requests a purchase, the machine searches for an available hash and generates an invoice. The customer pays normally, and the vending machine owner receives the payment and releases the preimage as proof-of-payment. The customer provides the preimage to the machine, which checks it against the list of hashes and sets the claim flag if valid. The product is then released. The supply of hashes can be replenished by the owner of the vending machine when restocking the machine. However, there is no way to refund payment in case of mechanical failure.


Updated on: 2023-05-25T16:56:01.844567+00:00