Sample audit: a Lovable + Supabase app, reviewed before launch

Anonymized real audit · identifying details removed

Sample audit: a Lovable + Supabase app, reviewed before launch

This is a real ShipVibed Full audit, anonymized. The app is a small creator-tools SaaS built with Lovable and Supabase, where signed-in users publish public pages. It was already live and taking real sign-ups. We removed the name, domain, project details, table and route names, numbers that could identify it, and any feature specific enough to find it. The findings, severities and fixes are unchanged.

Built with Lovable (server-rendered), a CDN/proxy in front, Supabase backend
Access given Live URL only, no test account
Type Full audit, public surface only, read-only
Review Point in time

Summary

Overall score: 68 / 100. A solid base with one thing to fix first.

The things that go wrong most often in Lovable and Supabase apps were fine here. There were no secret keys in the JavaScript and no leaked .env files or source maps. Row Level Security was on and correctly hid unpublished content, and the database schema couldn’t be browsed with the public key.

The main finding was narrow and quick to fix: the public profiles table still included each user’s sign-up email, and the public key could read it. The app never showed those emails on any page, but anyone could copy the public key out of the browser and list them.

Severity Count
Critical 0
High 1
Medium 2
Low 4
Info / to verify 4

How the score works: we start at 100 and subtract 25 per Critical, 12 per High, 6 per Medium and 2 per Low. Info items cost nothing, so here it’s 100 − 12 − 12 − 8 = 68. It’s our own simple rubric, not an industry standard. Fixing the High and the two Mediums puts this app above 90.

What we checked

  • Shipped JavaScript: every file the app loads, scanned for secret keys, key patterns and JWTs (with the role claim decoded), env variable names, table and storage names, routes, redirects and webhook paths.
  • Leaked files: /.env variants, /.git/config and source maps.
  • Supabase data access with the public key only, for every table named in the code. We made one limit=1 read to see the status and column names, then ran count-only queries. Nothing was written, and no personal data was copied.
  • Storage bucket listing, the API schema root and the public auth settings.
  • Auth settings, auth redirects and possible open redirects.
  • Security headers, cookies, CORS, the http → https redirect, www, deep links, the 404 page, robots.txt, the sitemap and metadata.
  • Webhook and scheduled-job routes visible in the code. We sent no payloads.
  • Performance basics: page and bundle sizes, caching, compression and images.

We spaced our requests out and used a User-Agent that names ShipVibed.

Findings at a glance

# Severity Finding
1 High The public API returns the sign-up email (and user id) of every published profile
2 Medium Email sign-ups are auto-confirmed, with no email verification
3 Medium The plain http:// version of the domain returns a 500 error instead of redirecting to https
4 Low No Content-Security-Policy, clickjacking protection or Permissions-Policy
5 Low Public form actions show no visible abuse protection (unconfirmed)
6 Low A “gated” link is stored in publicly readable data
7 Low SEO basics: no canonical tags or structured data, and auth pages are indexable
8 Info Very long-lived signed image URLs
9 Info Payment webhook, scheduled-job and auth-email routes couldn’t be verified from outside
10 Info Auth redirects: what the app uses, and what to double-check in Supabase
11 Info Performance notes

High

1. The public API returns the sign-up email of every published profile

What we found. RLS was on for the profiles table, and the row-level part worked: unpublished profiles weren’t returned. But every published row came back with all of its columns, including email and user_id. Here’s a read that works with only the publishable key that ships in the browser:

curl "$SUPABASE_URL/rest/v1/profiles?select=*&limit=1" \
  -H "apikey: $PUBLISHABLE_KEY"   # both ship in the browser
# 200 OK. Columns include: id, user_id, username, display_name, bio, ..., email, ...

Every published profile had a real email in that column. The app code copied the account email into the profile when the page was created, so this was the sign-in address, not an optional public contact. The public pages never displayed it, which means it was only reachable through the API.

Why it matters. Anyone could download the email list of every user who’d published a page. That’s a privacy problem for the app’s users and exposes them to spam and phishing. Depending on where those users live, it can also bring GDPR-style obligations. The public key is meant to ship, so the real question is what each table lets it read. RLS controls which rows a visitor sees, not which columns.

Fix. Keep emails in a table only the owner can read, and leave the profiles table for public data only.

create table public.profile_private (
  profile_id uuid primary key references public.profiles(id) on delete cascade,
  email text
);
alter table public.profile_private enable row level security;

create policy "Owner can read own private data"
on public.profile_private for select to authenticated
using (exists (select 1 from public.profiles p
               where p.id = profile_id and p.user_id = (select auth.uid())));
-- plus matching insert and update policies

insert into public.profile_private (profile_id, email)
select id, email from public.profiles where email is not null;

Then point the app at the new table, or just read session.user.email. Only after nothing reads the old column, drop it with alter table public.profiles drop column email;. As an optional extra step, serve public pages through a view or server function that selects only the public columns.

We also gave the client a prompt they could paste straight into Lovable to make the change.

Check it worked. Run the same curl again. email should be gone, and the profile editor should still show and save your own email.

Related guide: RLS is on but columns are still exposed

Medium

2. Email sign-ups are auto-confirmed

What we found. The public auth settings reported that email auto-confirm was on. Email and password accounts became active without clicking a confirmation link.

Why it matters. Anyone can sign up using someone else’s address, and typos go unnoticed. Fake accounts get easier to create, a profile’s email may not belong to the person who made it, and sender reputation can suffer when you email those addresses.

Fix. Turn on Confirm email in Supabase (Authentication → Sign In / Providers → Email). On Lovable Cloud, look for “Auto-confirm email signups” and switch it off. Show a clear “check your inbox” message, and make sure the confirmation link lands on the production domain. Before you switch it on, make sure auth emails send reliably, because Supabase’s built-in mailer has a low hourly cap.

Related guide: Supabase email rate limit exceeded

3. Plain http returns a 500 instead of redirecting

What we found. The https site worked and sent a good HSTS header. But the http:// version of the custom domain returned 500 Internal Server Error with an empty body, every time we tried. The error came from the edge proxy, not the app. The www address redirected correctly.

Why it matters. Old http:// links, such as printed QR codes, old posts or typed URLs, show an error page instead of the site. HSTS protects returning visitors, so first-time visitors and some bots are the ones who hit it.

Fix. Turn on “Always Use HTTPS” at the DNS/CDN provider, re-verify the custom domain in Lovable’s domain settings, and escalate to Lovable support if it persists. Then check that curl -I http://<domain>/ returns a 301 to https.

Low

4. Missing hardening headers

The app already sent HSTS, nosniff and a Referrer-Policy. It didn’t send a Content-Security-Policy, a frame rule (X-Frame-Options or frame-ancestors) or a Permissions-Policy. Without a frame rule, the login page can be embedded in an invisible frame to trick people into clicking (clickjacking).

Fix: add X-Frame-Options: DENY, a restrictive Permissions-Policy, and a CSP in report-only mode first. After a few days without violations, switch the CSP to enforcing.

Related guide: What Lovable’s security scan covers and what it doesn’t

5. Public form actions show no visible abuse protection (unconfirmed)

A few server actions behind public forms could be called without signing in. The shipped code had no CAPTCHA, honeypot field or bot check. Any rate limiting would live server-side, where we can’t see it. The app’s other data-changing actions did require auth, which is good.

Fix: validate input with a schema and cap field lengths, rate-limit per IP and per email, add a honeypot field or Cloudflare Turnstile, and use long random tokens for unsubscribe links.

A feature meant to reveal a link only after a visitor submits a form stored that link in config the public key could read. The sample we saw used a placeholder, so nothing real was exposed. But a real private link would be readable by anyone who queries the API.

Fix: return the link from the server only after the form is submitted, or tell users the link is effectively public.

7. SEO basics

Titles, descriptions, Open Graph tags, the sitemap and robots.txt were all in place. The site had no canonical tags or JSON-LD, and the login, register and admin pages were indexable, with some of them listed in the sitemap.

Fix: add self-referencing canonical tags and Organization/WebSite JSON-LD, add noindex to the auth and admin pages, and remove them from the sitemap.

Info and to verify

  1. Very long-lived signed image URLs. Images in a private bucket were shared with signed links valid for about a decade. This isn’t an exposure, since the images are meant to be public, but the links can’t be revoked and will eventually expire. Either use a public bucket with plain URLs, or keep the bucket private and issue short-lived links on demand.
  2. Webhooks and scheduled jobs. We found a payment webhook, a scheduled-job route and an auth-email hook. We sent no payloads, so the client should confirm three things. The payment webhook should verify its signature against the raw body and skip duplicate event IDs. The scheduled-job route should require a secret. The email hook should verify its signature. Guides: Stripe webhook signature verification failed, Stripe duplicate events and idempotency
  3. Auth redirects. We found no open-redirect parameter. In Supabase → URL Configuration, the Site URL should be the production domain, and the redirect allow-list should contain only real URLs, with no localhost and no wildcard on a domain you don’t own. Guide: Supabase auth redirects to localhost
  4. Performance. First-load JavaScript was reasonable for this kind of app. Static assets had long-lived caching and compression, and below-the-fold images were lazy-loaded. Converting large JPEG screenshots to WebP or AVIF would cut their size roughly in half. Uptime and error monitoring weren’t visible from outside, and setting them up takes about ten minutes: monitoring tools with free plans.

What was already good

  • No secrets in the JavaScript. We found no service_role key and no Stripe, OpenAI, Anthropic or email-provider keys. Only the public Supabase URL and publishable key shipped, as intended.
  • No leaked files. We found no .env, .git or source maps.
  • RLS worked on rows. Unpublished and draft content was hidden, and the private tables returned nothing to the public key.
  • The schema wasn’t browsable with the public key, and storage buckets couldn’t be listed.
  • Auth setup was sensible. Unused providers were off, and the reset and callback pages had noindex.
  • Transport basics were good. The site had HTTPS with HSTS, no open CORS, and a www → apex redirect.
  • Routing worked. Deep links and refreshes loaded, unknown URLs returned a real 404, and robots.txt and a sitemap were in place.

Limitations

This was a public-surface review with no test account. We didn’t test anything behind login, such as whether one user can read another user’s data, admin role checks or billing. Supabase dashboard settings weren’t visible to us. The audit reflects one point in time: it can show problems that exist, but it can’t prove there are none. It isn’t a penetration test or a certification.

Next steps we gave the client

  1. Fix finding 1, which takes about 30 minutes, then re-run the curl.
  2. Fix findings 2 and 3 this week.
  3. Work through 4 to 7, and verify 9 and 10, when convenient.
  4. We re-check 1 to 3 for free once they’re done.

Want this for your app?

  • Quick check, US$39: the most critical issues before you launch.
  • Full audit, US$129: a report like this one. Founder price: US$59 with code FOUNDER59, first 10 customers only.
  • Audit + fix, US$349: the full audit, and we fix what we find.

Get an audit