Journal

AI-built apps, safe to launch5 min read

Is your AI-built app safe for real users? A security checklist

Built your app with Codex or Claude Code? Here is a plain security checklist covering login, database rules, secret keys and rate limits, plus when to get an independent review.

By

Researched and drafted with AI assistance, then checked and approved by Isaac Vicliph before it was published.

An AI-built app that works is not necessarily safe. Before real users arrive, check four things: login and access, database rules, secret keys and rate limits. Test them yourself this week. If you hold personal data or take payments, get someone who did not build the app to review it before launch.

AI tools write code that works, not always code that is safe

Probably not yet, unless someone has checked it. Tools like Codex and Claude Code are good at producing an app that runs. Running and being safe for real users are different things.

Veracode's 2026 research into AI models found that roughly 44% of AI coding tasks it tested produced code with a known vulnerability, meaning a well-documented type of security weakness. Veracode also makes the point that code which compiles, runs and looks tidy can still contain weaknesses someone can exploit. That is the trap for founders: the app looks finished, so it feels finished.

Picking a different model does not solve it. In Veracode's tests, models built for coding averaged 51% on security tasks and general-purpose models averaged 52%. None of the models tested produced secure code reliably enough to skip checking the work. The checking still has to happen.

Database rules decide who can read your data

If your app uses Supabase, a hosted database that apps often talk to straight from the browser, access is controlled by Row Level Security, or RLS. RLS is a set of rules that decide which rows each user can read or change.

Supabase's own guidance is clear. A table in an exposed schema without RLS can be read and written by any role that has a grant on it, so you should turn RLS on for every table in that schema. Once RLS is on, nothing is reachable through the API with the publishable key until you write policies, so expect parts of your app to stop working until the rules are in place. Views, which are saved queries over tables, can hand out rows that a table's rules were meant to hide, so they need checking too. Supabase also says you do not know your rules work until tests confirm it. Switching RLS on and writing a few policies is a start, not the whole job.

This is not only theory. A published vulnerability record, CVE-2025-48757, says weak RLS in sites generated by Lovable up to 15 April 2025 let unauthenticated attackers read or write database tables. Lovable disputes that record, saying each customer is responsible for protecting their own app's data. Whichever view you take, the practical point for you is the same: do not assume the platform is guarding your data for you.

Login, secret keys and rate limits

Database rules are one part of the picture. A useful yardstick is the OWASP Top 10, a standard list of the most critical security risks to web applications. You do not need to read it all, but it is a fair thing to ask any reviewer about.

For a small app, these are the basics we would start with. They are easy for an AI tool to miss, because it was likely asked to make a feature work, not to defend it.

  • Login and access. Every page and every request that returns private data should check who the user is on the server, not just hide buttons in the browser. Try changing a record number in the address bar and see whether you can open someone else's details.
  • Secret keys. Keys for payments, email or full database access belong on the server. They should never sit in code sent to the browser or in a public code repository. If one ever has, replace it with a new key.
  • Rate limits. A rate limit caps how often someone can repeat an action. Put limits on login, sign-up, password reset and anything that costs you money, such as AI calls or text messages, so one script cannot guess passwords or run up your bill.

What to do this week

You can do most of this yourself, or with whoever helped you build the app. Set aside an afternoon and work through the list in order.

If you get stuck on any step, or the answer is not clear, treat that as a sign the app needs a closer look before launch.

  • List your data. Write down what personal information the app stores: names, emails, phone numbers, addresses, payment details and anything users upload.
  • Check every table and view. In Supabase, confirm RLS is on for every table in the exposed schema, that each table has policies, and that no view exposes rows it should not.
  • Test as a stranger. Create two test accounts. Try to see account A's data while logged in as B, and again while logged out.
  • Hunt for secrets. Search your code for keys and passwords. Move them to server-side settings and replace any that were ever exposed.
  • Add rate limits. Cover login, sign-up, password reset and any paid action.
  • Write a one-page breach plan. Who decides, who you call, and how you tell users if something goes wrong.

Your privacy duties in New Zealand, and when to get a review

Under the Privacy Act 2020, if a privacy breach has caused or is likely to cause serious harm, you must notify the Privacy Commissioner and the people affected as soon as you practically can. The Act says as soon as practicable, so do not wait. Check the Commissioner's guidance for what that means in practice. The Commissioner recommends having a breach plan and practising it before anything goes wrong. Vulnerabilities in computer systems should be reported to the National Cyber Security Centre (NCSC). For anything about your own legal obligations, check the Commissioner's guidance or ask a lawyer.

Get an independent review before you take real personal data or payments, before you sign a business customer, and any time you cannot confidently answer the checklist above. It matters most when the app was largely written by AI and nobody has read the code line by line. Someone who did not build it will see things you no longer notice.

This is work we do. For StaffChecks Ltd, a New Zealand pre-employment screening company operating since 1997, we reviewed, secured and redesigned a new client portal and ran the switch to it. You can read about the StaffChecks client portal, which went live on 5 October 2026.

An AI tool can get you to a working app quickly. Making it safe for real people's data is a separate job, and it is easier to do before launch than after. If you would like a second pair of eyes on yours, get your AI-built app checked before you open the doors.

Frequently asked questions

Is code written by Claude Code or Codex secure?

No AI tool should be assumed secure. Veracode's 2026 testing of AI models found roughly 44% of the coding tasks it tested produced code with a known vulnerability, and no model it tested was reliable enough to skip checking. Models built for coding did no better on security than general-purpose ones. The code may run and look clean but still contain weaknesses, so treat it as a draft that needs review before real users rely on it.

How do I check if my Supabase database is exposed?

Open each table in an exposed schema and confirm Row Level Security is switched on and has policies. Check any views as well, because a view can show rows the table's rules were meant to hide. Then test: create two accounts and try to read one account's data from the other, and while logged out. Supabase says you cannot know your rules work until tests confirm it.

Do I have to report a data breach in New Zealand?

Yes, if it has caused or is likely to cause serious harm. Under the Privacy Act 2020 you must notify the Privacy Commissioner and the affected people as soon as you practically can. The Commissioner also recommends having a breach plan and practising it beforehand. Report computer system vulnerabilities to the National Cyber Security Centre. For advice on your specific situation, check the Commissioner's guidance or speak to a lawyer.

When should I get a security review for my AI-built app?

Before you collect real personal data, take payments or sign your first business customer. Also get one if you cannot confidently confirm your login checks, database rules, secret keys and rate limits, or if most of the code was written by AI and nobody has read it closely. A reviewer who did not build the app is more likely to spot gaps you have stopped noticing.

Sources

Share this article

  • #ai-built apps
  • #app security
  • #supabase
  • #privacy act
  • #launch checklist