Work

Rafu: An Offline-First Ledger for Small Shops with Privacy-Preserving Mobile-Money Reconciliation

Year: 2026
Type: article
Abstract: Small retail shops such as kiosks, small pharmacies and hardware stores often keep stock and customer credit in paper notebooks, while a growing share of their income arrives as mobile-money transfers announced by text message. Two bookkeeping problems follow: the recorded stock drifts away from the shelf, and it is hard to tell which sale a given payment message settled. This report describes Rafu, an Android application that treats both as ledger problems under three constraints: no dependence on connectivity, no server, and no access to the phone's message inbox. Every quantity change is an append-only stock movement written in the same database transaction as the quantity, and money is represented as 64-bit integers of minor currency units with an ISO 4217 code. Mobile-money sales stay open until a payment message, shared or pasted by the owner, is read by a deterministic rule-based interpreter (English and Arabic, including Arabic-Indic digits), stored as extracted fields with the sender's phone number masked, and matched by amount, currency and time window to open sales, with the owner confirming each match. Several phones in one shop synchronise without a server through per-phone operation journals exchanged as AES-256-GCM encrypted files or over Bluetooth, with a QR code distributing the key. The report describes the algorithms as implemented and reports only quantities verifiable from the source tree; no field evaluation has been carried out. This technical report describes Rafu version 1.5.0 for Android.
Language: English
Open Access status: green
OpenAlex ID: W7233855247
FWCI:
Cites:
Cited by:
Related to: 10