Access audit
$129You cannot say who is able to read your customers' data.
The AI wrote the database rules and nobody has read them since. It is the first thing a buyer's IT checks, and the flaw behind the best known leaks in AI-built apps.
Every table, file store and API route checked and locked to the people who should have it.
You answer the access question on one page, and the leak that ends young companies is closed.
What is inside: 38 checks, each with its fix
- Database rulesWho can read, change and delete each table12 checks
- File storageUploads, exports and anything with a public link6 checks
- API routes and server functionsPermissions checked on the server, not on the screen9 checks
- Admin, staff and support accessWho on your side can see customer data7 checks
- Keys that bypass the rulesWhere they live and who holds them4 checks
- The access matrixThe one page you send when a buyer asks1 page
One page from the audit
Row level security is off on a table that holds customer data.
- What it means
- Anyone with your public project key can read every row in this table. That key is in your website's code, so that is anyone.
- How to test it
- Run this in the SQL editor. Any line that says false, on a table with customer data, is a fail.
select tablename, rowsecurity from pg_tables where schemaname = 'public';
- The fix
alter table public.invoices enable row level security; create policy "owner reads own invoices" on public.invoices for select using (auth.uid() = user_id);
- Say it to your AI tool
- Turn on row level security for every table in the public schema. Add policies so a signed-in user can only read and change rows where user_id is their own id. List any table with no user_id column and stop there.
- Evidence to keep
- The result of the test after the fix, with the date, in your access folder.
- Policies that allow everything
- Tables with no owner column
- The service key in client code
- Views that skip the rules
- Functions that run as the owner
- Public file buckets