When an internal tool starts as a single-user application on SQLite, almost every query carries an unspoken assumption: whoever is running the app owns all the data. A request for record 42 just fetches row 42.
Moving that tool to a shared service breaks that assumption immediately. Once two people share the same database, a bare lookup by numeric ID becomes a data-leak bug. Adding login authentication at the front end is not enough, because the back end still has to know who owns each row and enforce that boundary on every read, write, and background job.
For example, say Alice and Bob both use a shared application, and Bob requests record 42 in a URL. If the query only checks WHERE id = 42, Bob can read or overwrite Alice’s record. With explicit ownership, the query checks both the record ID and the authenticated owner context, so Bob’s request returns “not found” or “unauthorized” instead of Alice’s data.
| Layer | Single-user assumption | Shared-service requirement |
|---|---|---|
| Request handling | User is implied by the local session | Authenticated owner identity is attached to every request |
| Database queries | Lookup by primary key (id = 42) | Lookup scoped by owner (id = 42 AND owner_id = ...) |
| Database policies | Application code is the only gate | Row-level security or equivalent enforces isolation |
| File storage | Shared local directory by filename | Owner-scoped paths or object keys |
| Background work | Runs with full local access | Carries explicit owner context, with external calls outside DB transactions |
Enforcing ownership in only one layer is rarely enough. Application code can miss a filter on a new endpoint, and a shared file directory can expose another user’s attachment when filenames collide. Pairing owner-scoped queries in the application with row-level policies in the database gives you a second line of defense, and passing the owner context explicitly to background jobs keeps external calls from assuming a global session.

Before you open a single-user tool to a second person, trace every query, file path, and background task and ask the same question: who owns this row?
—jhunterj