News

Vibe coding security checklist for companies

November 30, 2026

Five ways AI-generated apps leak company data and a 12-point pre-launch checklist: RLS, secrets, auth, agent permissions and audit logs.

Short answer: Most AI-generated apps fail on the same five things: database tables without row-level security, secrets committed to repositories or shipped in front-end code, endpoints that answer without login, AI agents with more permissions than the task needs, and no audit log. Check all five before an app touches real company data.

Vibe coding is useful. A planner or maintenance engineer can build a working tool in an afternoon. The problem is not the speed. The problem is that the generated app looks finished while its access rules are not. This checklist is written for internal IT, digitalization teams and citizen developers in manufacturing who need to decide whether an AI-built app can go live.

What went wrong in 2026: two cases worth knowing

Supabase tables readable without login

In November 2026, the Hamburg consultancy Crissy Field, working with Handelsblatt, published an audit of Lovable projects collected from the Common Crawl archive, as reported by Streamline Feed. Of 159,041 projects, 34,545 used Supabase. On 24,664 sites, records came back on page load without any login, although some of that may be intentionally public data. 7,403 sites exposed email addresses through read-only queries with the public client key.

The cause was not a breach of Lovable or Supabase. Supabase puts a public key in the front end by design and relies on Postgres row-level security (RLS) to decide who sees which rows. When RLS policies are missing or wrong, anyone who opens the browser developer tools can query whole tables. The Supabase RLS documentation is direct: enable RLS on every table in an exposed schema, and never use a secret key in the browser.

Passwords saved in Claude Code settings files

Apiiro research from November 2026, summarized by CircleMount, looked at .claude/settings.local.json. When a user approves a command with “Yes, and don’t ask again”, the command can be saved there, including any password typed into it. Apiiro found the file in 103,617 public repositories. 1,122 of the files held at least one secret, 1,379 distinct secrets in total, including 379 database passwords. Common scanners missed part of them, and in half of the affected repositories the secret had sat on the default branch for at least 217 days.

The lesson for a plant: the leak did not come from the app code anyone reviewed. It came from a tool configuration file nobody thought of as code.

The five most common failures

1. Missing row-level security or access rules

A shift report app works fine in the demo. Every user sees every line, every shift and every quality complaint, because the generated query has no filter and the table has no policy. In a plant this means an operator can read HR notes, or a supplier with a guest account can see your scrap rates. Test it the way an attacker would: call the API with the public key and no session, and see what comes back.

2. Secrets in repositories and front-end code

API keys for the ERP, SMTP passwords or database connection strings end up in the bundle the browser downloads, in .env files pushed to GitHub, or in tool settings files as shown above. Anything shipped to the browser is public. GitHub push protection blocks known secret patterns before they land, but repository-level push protection is off by default, so turn it on for every repository.

3. Public endpoints without authentication

Generated apps often add a helper endpoint, a webhook or an export route and forget to protect it. Another typical bug is inverted logic: auth checks that block signed-in users and let anonymous ones through. Every route needs an explicit decision: who may call it, and what happens without a session.

4. AI agents with over-broad permissions

OWASP lists this as Excessive Agency in its Top 10 for LLM applications: too many functions, too many permissions, too much autonomy. A coding agent with production database credentials, or an assistant that can write to the ERP when it only needs to read work orders, turns a hallucination or a prompt injection into a real incident. The OWASP mitigations are practical: give the agent only the tools it needs, run it in the user’s context with least privilege, require human approval for high-impact actions, and let downstream systems check every request.

5. No audit log

When a maintenance order disappears or a quality record changes, someone will ask who did it. If the app has no audit log, the answer is “we don’t know”. In regulated or customer-audited plants (automotive, food, pharma), that is a finding on its own. Log who changed what, when, from which value to which value, and whether the change came from a person or an AI agent.

Try it yourself: start a 14-day free P4 trial and build a test app on demo data.

Pre-launch checklist for AI-generated apps

Run this before any app touches production data. Each item should have a named person who confirmed it.

  1. Data inventory. List every table and what it holds (personal data, HR, prices, quality records, machine data).
  2. RLS on every exposed table. Enabled, with policies written per role. Test with the public key and no session: the result should be empty or deliberately public.
  3. No secret in the browser. Search the built front-end bundle for keys and connection strings. Only publishable keys belong there.
  4. Repository hygiene. Push protection and secret scanning on. .env and tool settings files (including .claude/settings.local.json) in .gitignore. Scan the full git history, not only the latest commit, and rotate any secret ever committed.
  5. Every endpoint authenticated. List all routes, webhooks and functions. Call each one without a session and with a low-privilege user.
  6. Roles match the org chart. Operator, shift lead, maintenance, quality, admin. Each role sees and changes only what its job needs.
  7. Agent permissions scoped. AI agents use the user’s identity, read-only by default, with approval or a dry run for writes to ERP, MES or the database. No production credentials in coding agents.
  8. Separate environments. Dev, test and prod with separate databases and keys. No testing on production data.
  9. Audit log on. Changes to business records are logged with user, time, old and new value, and source (person or agent).
  10. Single sign-on and offboarding. Users log in through company SSO, so leaving the company removes access.
  11. Backup and restore tested. Restore once before go-live. An AI agent deleting production data has already happened to real teams.
  12. Owner and support. One named owner, a documented process for changes, and someone who answers when the app fails on the night shift.

Where a governed platform helps

Most items above are not about the code the AI writes. They are about the platform the code runs on. If each app is free-standing code, every team has to get RLS, secrets, SSO, environments and audit logs right by itself, every time. That is where we see the gap between AI-built and vibe-coded apps.

In Productoo P4, applications are configurations on one governed platform, not free-standing code. Dev, test and prod are separate, users log in through SSO, roles and access rights are set for each page, changes are versioned and checked before release, and an audit log is built in. When Claude, ChatGPT, Microsoft Copilot or your own agent works with P4 through the MCP server, it uses the user’s permissions and supports dry runs. You can still build fast in Configuration Studio; the controls are already there. More detail is on the trust and security page and in our article on MCP security for plants.

This does not mean vibe-coded apps are forbidden. A throwaway prototype on dummy data is fine. The line is real data and real users.

Related reading:

FAQ

Is a public Supabase key a security problem?

No, it is designed to be public. The protection comes from RLS policies. A public key plus missing RLS is the problem.

Does GitHub catch committed secrets automatically?

Partly. User-level push protection blocks known secret patterns pushed to public repositories, but repository-level push protection is off by default and passwords typed inside commands are often missed. Scan history and rotate anything exposed.

Should AI coding agents have production access?

No. Give them dev or test credentials only. Production changes go through review and a deployment step a human approves.

Who is responsible for data protection in an AI-built app?

Your company. Platform terms usually put data protection on the customer, so the app owner must sign off the checklist.

Can a citizen developer run this checklist?

Most items, yes. Testing RLS, endpoints and secrets in history is easier with someone from IT or security for the first app.

Summary

AI-generated apps fail in predictable places: access rules on data, secrets, unauthenticated endpoints, agent permissions and missing audit logs. The 2026 cases show these are not theoretical. Run the twelve-point checklist before real data goes in, name an owner, and prefer a platform where the controls are built in rather than rebuilt per app.

Want to build plant apps with AI and keep the controls? Start a 14-day free trial with demo data, or if you build apps for other manufacturers, become a partner.

Updated 30 November 2026.

Productoo P4 keeps growing, with new apps and features that move manufacturing forward.