Skip to content

0016 guest accounts

github-actions[bot] edited this page Nov 18, 2026 · 2 revisions

Every install is a guest account, made in the background

Status: accepted · Implementation: planned · Date: 2026-11-18

From LibreLifts ADRs 0025 and 0033. Decided again for LibreBars on 2026-11-18: the guest account is made before the backup notice is answered, as in LibreLifts. Rate limits are kept in the API's memory, which is only right while there is one instance of it. As built, 2026-11-18: an install gets its guest account in the background, keeps its session, and is limited to ten requests an hour per address; seen against a local API in Chromium, where three launches made one account, and on the iOS simulator, where the session survived a relaunch. The privacy policy, the retention period and deletion do not exist, and the app only talks to an API on the developer machine until they do, so this stays planned.

Context

The server holds a copy of each person's log (0014). The question is who gets one. Requiring a sign-up before the app is useful is what LibreBars sets out not to do. Offering backup only after a sign-up leaves everyone else with a log that is lost with the phone.

A guest has no email, no password and nothing else that identifies it: only a session whose key the device holds. That raises three things. The app may first be opened with no connection. A session that runs out takes the account with it. And anyone can ask for a guest account, as often as they like.

Decision

  • Every install becomes a guest account by itself, without asking for anything. A guest is an ordinary account row with a mark that says it is a guest.
  • Signing up is never required. When sign-up exists, it turns the guest into a full account and keeps its data.
  • The app never waits for an account. It works at once from its own database. It asks for a guest account in the background the first time it has a connection, and keeps trying, at growing intervals, until it has one. "No account yet" is a normal state, not an error, and no screen shows it as a failure.
  • The account is asked for as soon as there is a connection, before the backup notice is answered and whether or not backup is on (0020). Only the person's data waits for the notice. A guest account whose owner declined backup holds nothing.
  • The device keeps the session in its secure storage. In the browser build it is a cookie.
  • A guest's session lasts a year and is renewed whenever the app is opened.
  • A session that is lost cannot be recovered. The device starts again as a new guest. Its own database is untouched, and its data reaches the new account at the next sync.
  • Asking for guest accounts is limited per address.
  • Before any real person's data is stored, the project has a privacy policy, a period after which an abandoned guest's data is deleted, and a way to delete one's data on request.

Consequences

  • The first launch works with no connection, and nothing in the app handles a missing account as an error.
  • Until sign-up exists, a guest's data on the server can only be reached from the install that made it. A lost phone still loses the log.
  • A guest account tied to a device is personal data under data-protection law, even with no name or email, and one is made for a person who then declines backup.
  • An account request whose answer is lost leaves an account nobody holds the key to. The job that removes abandoned guests clears it; that job does not exist yet.
  • A guest who does not open the app for more than a year loses the server's copy.
  • Signing in to an existing account from a device that has guest data needs a rule for joining the two. It is decided with sign-up.

LibreBars

Clone this wiki locally