CVE-2025-48757: the Lovable RLS flaw, who is affected and how to fix it

CVE-2025-48757 is a disputed, critical (CVSS 9.3) flaw in apps built with Lovable: tables in the Supabase database behind the app had missing or weak row level security (RLS), so anyone holding the public key from the app's JavaScript could read or write them. A March 2025 scan found missing or weak RLS in 170 of 1,645 Lovable apps. There is no version to upgrade: each project fixes its own policies.

The team behind Keybrum's attacksUpdated 13 min read
CVE-2025-48757critical · CVSS 9.3
Component
Lovable-generated apps with a Supabase database (row level security)
Affected
Lovable through 2025-04-15, per the CVE record: projects with a database whose tables have missing or weak RLS. Later projects can have the same flaw
Fixed in
No fixed version: Lovable is a hosted service. Each project fixes its own RLS policies; Lovable added a security scan on 2025-04-24
Published
May 30, 2025
Keybrum tests your live app for this one, and proves it if it works.

In short

  • There is no package to upgrade. The CVE record lists Lovable as a hosted service, affected through 2025-04-15, with no fixed version: the fix lives in each project's database policies.
  • The CVE record scores it 9.3 (critical, CVSS 3.1), set by MITRE. NVD has not scored it, the researcher's own report gives 8.26, and Lovable disputes the CVE.
  • It is not in CISA's Known Exploited Vulnerabilities catalog. CISA rates exploitation as a public proof of concept, and automatable.
  • Projects created after April 2025 can have the same hole. Lovable's Quick scan flags tables with RLS off and rules that let everyone through, but Lovable says its scans cannot guarantee complete security: read the policies too.
  • The public key is meant to be public. Test every table as a stranger and as a second account: read, insert, update.
On this page

What CVE-2025-48757 is, in plain words

A Lovable app with a database talks to it straight from the browser. The frontend calls the database's REST API with the public anon key, which ships in the app's JavaScript. Nothing sits in between. The only thing that decides who can read or change a row is row level security (RLS): rules attached to each table in Postgres. When a table has RLS off, or a policy that lets everyone through, anyone who copies the key from the page can query that table without your app.

In March 2025, Matt Palmer found exactly that on a site built with Lovable. He then scanned 1,645 sites listed on Lovable Launched and found 170 projects, about 10.3%, with inadequate RLS, across 303 endpoints. His script only loaded homepages, signed out, so it missed anything behind a login. The CVE record that followed reads:

An insufficient database Row-Level Security policy in Lovable through 2025-04-15 allows remote unauthenticated attackers to read or write to arbitrary database tables of generated sites.
CVE-2025-48757, CVE record
FieldValue
ComponentApps generated by Lovable that use a database (Supabase)
WeaknessCWE-863, incorrect authorization
CVSS9.3 critical, CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:L/A:N, set by MITRE in the CVE record
Published30 May 2025
AffectedLovable through 2025-04-15, per the CVE record. Later projects can have the same flaw
Fixed versionNone. Lovable is a hosted service: each project fixes its own tables
StatusDisputed by Lovable
Known exploitedNot in CISA KEV (catalog of 6 November 2026)
Facts from the CVE record, NVD, the GitHub advisory GHSA-773x-pxjg-gxgx and the CISA KEV catalog.

What a stranger could do with it

No password, no account, no special tool. With the project URL and the public key, both visible in the browser, a visitor could send requests to the database the same way the app does, minus the screens that hide what the app does not show. The researcher's write-up lists what was reachable on the affected sites:

AccessWhat it meansData the researcher saw at risk
Read every rowSelect a whole table instead of the rows the screen showsNames and email addresses from users tables
Get secrets the backend hands outDatabase functions and edge functions that return keys answer anyone who calls themAPI keys and tokens for Google Maps, the Gemini API and eBay
Change rowsUpdate records the visitor does not ownPayment status in transactions and subscriptions tables
Add rowsInsert records with any valuesA test record marked payment_status: paid
Delete rowsWhere the role holds the grant and no policy stops itAny table left open: the report lists deletes as possible

The database did nothing wrong here. It answered exactly as configured. That is why this class of bug survives code review: every screen of the app shows the right data, and the open door is one level down.

Severity and exploitation status

CVSS 9.3, critical. That score comes from MITRE, which assigned the CVE, and the GitHub advisory GHSA-773x-pxjg-gxgx repeats it. NVD shows the same score as a secondary source and has not analyzed the CVE itself: its status is Deferred. The researcher's own report scores it lower, at 8.26, because it rates the scope as unchanged. The 9.3 vector describes a flaw reachable over the network, with no account and no action from a victim.

Disputed. The CVE record carries the tags disputed and exclusively-hosted-service, and this note: Lovable disputes it "because each individual customer of the Lovable platform accepts a responsibility over protecting the data of their application." The researcher's answer is that a platform which generates the database and its policies should ship safe defaults. For your app, the dispute changes nothing: an open table is open.

Who is affected

Three conditions together: the app was built with Lovable, it uses a database, and at least one table the public key can reach has RLS off or a policy that is too wide. Where the frontend is hosted does not matter, because the browser talks to the database directly.

SetupAffected?
Lovable project without a databaseNo. There is nothing to read.
Lovable project with a database, created on or before 15 April 2025Inside the range the CVE names. Check every table.
Lovable project created laterOutside the CVE's dates, but the researcher warns later projects may be affected too. Same check.
Lovable's built-in backend (Cloud)Same model: Lovable says it "utilizes Supabase's open-source foundation", and policies decide who reads what.
Lovable project connected to your own Supabase projectSame model, and you also get the Supabase SQL editor and Security Advisor.
Lovable app exported and hosted on Vercel, Netlify or your own serverSame exposure. Moving the frontend does not move the access control.
App built with Bolt, v0, Cursor or by hand on SupabaseNot this CVE, which names Lovable, but the same misconfiguration and the same fix. See the Supabase RLS guide.

How to check if your Lovable app is affected

There is no version to compare: no npm package carries the flaw, so npm ls, pnpm why and yarn why cannot tell you whether you are exposed. The one package check that helps tells you whether RLS is your only lock. In a local copy of the project's code, run:

bash
npm ls @supabase/supabase-js
pnpm why @supabase/supabase-js
yarn why @supabase/supabase-js
grep -n "@supabase/supabase-js" package-lock.json pnpm-lock.yaml yarn.lock
If the package is there, the browser talks to your database directly and your RLS policies are the access control. Then check the tables.
  1. 1

    Run Lovable's scans

    The Quick scan runs when you open the publish dialog. It flags tables without row level security, access rules that let everyone through, and leaked-password protection turned off. The Deep scan adds a review of the code, access control included: start it from the project's Security view or ask Lovable in the chat. Lovable's own docs say these tools "cannot guarantee complete security", so a clean result is a starting point.

  2. 2

    Read every policy

    Open More > Database > Manage > Policies. For each table, ask: is RLS on, who can read, who can write, and does the rule compare a column to the signed-in user? A rule that is just true lets everyone in. A rule for authenticated that never checks auth.uid() lets in anyone who signs up.

  3. 3

    On your own Supabase project, run the SQL below

    In the SQL editor. It changes nothing and lists, for each table in public, whether RLS is on, what the anon role may do and how many policies exist.

  4. 4

    Open Security Advisor

    In the Supabase dashboard, or run supabase db advisors with the Supabase CLI. Its checks include RLS disabled in public, permissive RLS policy and sensitive columns exposed. Treat each finding as a lead and confirm it.

  5. 5

    Read one table as a stranger

    Use the request below with the URL and public key your app already ships, then repeat it signed in as a second test account. A row you should not see is the finding.

sql
select c.relname as table_name,
       c.relrowsecurity as rls_on,
       has_table_privilege('anon', c.oid, 'select') as anon_select,
       has_table_privilege('anon', c.oid, 'insert') as anon_insert,
       (select count(*) from pg_policies p
         where p.schemaname = 'public' and p.tablename = c.relname) as policies
from pg_class c
join pg_namespace n on n.oid = c.relnamespace
where n.nspname = 'public' and c.relkind in ('r', 'p')
order by rls_on, table_name;
Rows with rls_on false and anon_select true are readable by anyone holding your public key.
sql
select tablename, policyname, cmd, roles, qual, with_check
from pg_policies
where schemaname = 'public'
  and (qual = 'true' or with_check = 'true'
       or coalesce(qual, with_check, '') not like '%auth.uid()%');
Policies that let everyone through, or never look at who is calling. Public blog posts can be fine. Profiles, orders and messages are not.
bash
curl "https://YOUR_PROJECT_REF.supabase.co/rest/v1/YOUR_TABLE?select=*&limit=1" \
  -H "apikey: YOUR_PUBLIC_KEY" \
  -H "Authorization: Bearer YOUR_PUBLIC_KEY"
Your own project only. With a publishable key (sb_publishable_...), send only the apikey header. An empty [] on a table you know has data means RLS filtered it out.

How to check your live app

The SQL tells you what your policies say. A live test tells you what a stranger actually gets. The free check reads your app's address the way a visitor's browser does: in about ten seconds it shows the backend, the exposed keys and the tables your JavaScript names, without sending anything to your database.

Keybrum's attacks then prove it, on apps whose owner proved ownership. The attack supabase.table-read lists every table the public key can reach, from the API schema, the app's own code and common table names, reads 10 rows and counts the rest, first with no account and then as a brand-new one. It keeps counts, column names and one redacted row. The attack supabase.table-insert sends an insert built to fail, with a null primary key, and asks the database to roll the transaction back: if the database answers with a constraint error instead of an RLS refusal, the policy let the write through.

How to fix CVE-2025-48757 in your project

There is no patch to install. Lovable added a security scan with Lovable 2.0 on 24 April 2025 and has extended it since, but the scan finds problems: the policies are yours to fix, table by table. Turn RLS on, then write rules that say who owns each row.

sql
-- Before (do not run): every visitor reads and writes every row
-- create policy "public access" on public.orders
--   for all using (true) with check (true);

-- After: each signed-in user sees and creates only their own orders
alter table public.orders enable row level security;
drop policy if exists "public access" on public.orders;

create policy "read own orders" on public.orders
  for select to authenticated
  using ((select auth.uid()) = user_id);

create policy "create own orders" on public.orders
  for insert to authenticated
  with check ((select auth.uid()) = user_id);

revoke insert, update, delete on public.orders from anon;
Replace orders, user_id and the name of the open policy with your own. With RLS on and no policy, a table is closed to the public key: the safe state while you write the rules.
  • Keep payment and role fields away from the browser. No policy should let a user update their own payment_status, plan or role. Set them from your server, for example from a signed Stripe webhook.
  • Move secrets out of tables and open functions. Lovable's docs say to keep sensitive values in Secrets and read them only in server-side code. A function that returns a key to any caller leaks it like an open table. Then rotate every key that was readable: follow what to do when an API key leaks.
  • Read the fixes Lovable proposes. The scan recommends fixes. Check each generated policy against the questions above before you accept it: the researcher's point was that a policy that exists is not a policy that is right.
  • Block risky publishes. Workspace admins and owners can turn on Block publishing with critical issues in Workspace settings > Security > Privacy & security > Publishing. Lovable turns it on for the new Enterprise workspaces it creates. On any other workspace, check that it is on.

What to check after fixing

  • Every table answers the stranger test with [] or a permission error, not only the table you fixed.
  • A second signed-up account cannot read or change the first account's rows. That is an IDOR at the database level.
  • Views and database functions called through /rest/v1/rpc/ check the caller too. In February 2026, The Register reported a Lovable-hosted app whose access check in its RPC functions was inverted, which a researcher said exposed 18,697 user records.
  • Every secret found in a readable table, or returned by a function anyone can call, has been rotated at its provider.
  • Records you did not create, or payment and role fields that changed without a reason, have been looked for and cleaned up.
  • If personal data was readable, you have checked what the privacy law that applies to you requires.
  • Policies are reviewed again whenever a new prompt adds a table or a feature. Lovable's own guidance calls security an ongoing process.

CVE-2025-48757 has no family of patched versions in the npm sense. Its relatives are the same mistake in other apps: open tables, policies that check nothing, functions that skip the caller. The Lovable security guide covers the rest of the platform, and vibe coding security risks covers the same bugs in other AI builders.

Searches for a "Lovable security breach" also turn up a separate story. In April 2026, a researcher claimed a flaw in Lovable's own platform API let any free account read other users' source code, chats and database credentials. Lovable said it had accidentally re-enabled access to chats on public projects in February while unifying backend permissions, then reverted it. That issue is about Lovable's platform, not about the policies in your database, and it is not this CVE.

Timeline

DateEvent
20 March 2025Matt Palmer finds missing RLS on a site built with Lovable.
21 March 2025His scan of 1,645 Lovable Launched sites finishes: 170 projects, 303 endpoints. Lovable is notified.
24 March 2025Lovable acknowledges the report.
14 April 2025A second researcher posts the same flaw publicly. Palmer notifies Lovable again and starts a 45-day disclosure window.
15 April 2025Date of Lovable's response in the researcher's timeline, and the end of the affected range in the CVE record.
24 April 2025Lovable 2.0 ships with a security scan. The researcher says it checks that an RLS policy exists, not that it is correct.
24 May 2025The site where the flaw was first found still accepts unauthenticated writes.
30 May 2025CVE-2025-48757 is published, after the researcher's public disclosure on 29 May.
25 June 2025CISA's enrichment rates it a public proof of concept, automatable.
27 February 2026The Register reports a researcher's claim that one Lovable-hosted app with inverted access checks exposed 18,697 user records.
November 2026Lovable's Quick scan runs on every publish and flags tables without RLS. The CVE is still not in CISA KEV.

The fastest way to know where your own app stands is to look at it from the outside, the way the 2025 scan did.

Questions

What is CVE-2025-48757?

It is the CVE for missing or weak row level security in apps built with Lovable. Tables in the app's Supabase database could be read or written by anyone holding the public key from the app's JavaScript. It was published on 30 May 2025 with a CVSS score of 9.3, and Lovable disputes it.

Is CVE-2025-48757 a Supabase vulnerability?

No. Supabase behaves as designed: the public key is meant to be public, and RLS policies decide what it reaches. The CVE names Lovable, and the fix is in each project's policies. The same misconfiguration in a Supabase app built another way has the same fix.

Was this a Lovable security breach?

Not of Lovable's own systems. CVE-2025-48757 is about the database policies of apps built on Lovable. A separate issue in April 2026 concerned Lovable's platform API and the visibility of chats on public projects, which Lovable said it reverted.

Is my Lovable app vulnerable if I built it after April 2025?

It can be. The CVE record covers Lovable through 15 April 2025, but the researcher warns later projects may be affected too, because any table with RLS off or a policy that is too wide has the same problem. Run the checks on this page on every table.

Is there a patch for CVE-2025-48757?

No version fixes it, because Lovable is a hosted service and the flaw lives in each project's database. Lovable added a security scan in April 2025 that flags tables without RLS. You still have to fix the policies yourself, table by table.

Does Lovable's security scan catch this?

Partly. The Quick scan flags tables without row level security and rules that let everyone through, and the Deep scan reviews access control in the code. A scan does not know every rule your app intends, and Lovable's docs say the tools cannot guarantee complete security, so read the policies yourself.

Should I rotate my Supabase key after fixing RLS?

Not the public anon or publishable key: it is meant to be visible, and a new one is just as visible. Rotate any secret that sat in a readable table or came back from an open function, such as third-party API keys. If the service role key was ever exposed, treat that as an emergency.

Sources

  1. 1.CVE-2025-48757 Detail, NIST National Vulnerability Database
  2. 2.CVE-2025-48757 record, CVE Program
  3. 3.GHSA-773x-pxjg-gxgx, GitHub Advisory Database
  4. 4.CVE-2025-48757, Matt Palmer
  5. 5.Statement on CVE-2025-48757, Matt Palmer
  6. 6.Known Exploited Vulnerabilities Catalog, CISA
  7. 7.Security, Lovable Docs
  8. 8.Security best practices, Lovable Docs
  9. 9.Built-in backend (Cloud), Lovable Docs
  10. 10.Advisors, Supabase Docs
  11. 11.Lovable-hosted app littered with basic flaws exposed 18K users, researcher claims, The Register
  12. 12.Vibe coding upstart Lovable denies data leak, cites 'intentional behavior,' then throws HackerOne under the bus, The Register

Your app is public. So are its mistakes.

Check what any attacker can already see in it, free, in ten seconds. The full attack, with proof and fixes: €49 once, or €29 a month on a plan.

or continue with Google or GitHub