Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
Sichere ProgrammierungBuilding In-Browser Private Tools: When the Server Is the Liability(23.09.2026 um 08:54 Uhr)
Sichere ProgrammierungYour Order Fulfillment Workflow Is One 24-Hour Wait Away From Chaos(23.09.2026 um 08:54 Uhr)
Sichere Programmierungflet media library(23.09.2026 um 08:54 Uhr)
Sichere ProgrammierungRunning Lightdash on Snowpark Container Services(23.09.2026 um 08:55 Uhr)
Sichere ProgrammierungThe Impossible Filter Gallery Transition in CSS Only(23.09.2026 um 08:59 Uhr)
Sichere ProgrammierungVerifiable Data > Claimed Data: What i'm Trying to do with Ori's List(23.09.2026 um 09:08 Uhr)
Sichere ProgrammierungWhat Really Happens When You Upload a Photo to Instagram?(23.09.2026 um 09:08 Uhr)
Sichere ProgrammierungBuilding In-Browser Private Tools: When the Server Is the Liability(23.09.2026 um 08:54 Uhr)
Sichere ProgrammierungYour Order Fulfillment Workflow Is One 24-Hour Wait Away From Chaos(23.09.2026 um 08:54 Uhr)
Sichere Programmierungflet media library(23.09.2026 um 08:54 Uhr)
Sichere ProgrammierungRunning Lightdash on Snowpark Container Services(23.09.2026 um 08:55 Uhr)
Sichere ProgrammierungThe Impossible Filter Gallery Transition in CSS Only(23.09.2026 um 08:59 Uhr)
Sichere ProgrammierungVerifiable Data > Claimed Data: What i'm Trying to do with Ori's List(23.09.2026 um 09:08 Uhr)
Sichere ProgrammierungWhat Really Happens When You Upload a Photo to Instagram?(23.09.2026 um 09:08 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

Supabase Security: The Hidden Dangers of RLS and How to Audit Your API 🛡️

Supabase has solidified itself as the developer's favorite Open Source alternative to Firebase. The promise is incredible: you build a relational PostgreSQL database and magically get an instant REST API (via PostgREST) ready to be…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

Supabase has solidified itself as the developer's favorite Open Source alternative to Firebase. The promise is incredible: you build a relational PostgreSQL database and magically get an instant REST API (via PostgREST) ready to be consumed by your frontend.



But exactly in this "magic" lies the danger.



The convenience of having an API that directly reflects your database schema brings a massive cyber risk if you ignore (or misconfigure) the heart of Supabase security: RLS (Row Level Security).



In this article, we'll break down how data leaks happen and how you can automate the pentesting of your application before going to production.






🛑 The Problem: The Default Trap



In traditional APIs (Node.js, Laravel, Spring), security lives in the backend. You write middlewares and controllers to block unauthorized access.



In Supabase, the logic is inverted: access control lives inside PostgreSQL. The database acts as the bouncer, evaluating RLS rules row by row.



The main issue? By default, when you create a new table, RLS is disabled. This means the table is 100% public. Anyone with access to "Inspect Element" on your site can grab your anon_key, send a simple GET request, and dump your entire database.






🐛 The 3 Most Common RLS Mistakes



Even when developers remember to enable RLS, logical flaws often leave the castle gates wide open:






1. The "Just Make It Work" Policy



Desperate to make the frontend render data, many devs create a SELECT policy with the expression true.

The result? You protected the edits, but reading is wide open. User data, emails, balances, and histories are exposed to any web scraper or bot.






2. The "Ghost Auth" Flaw



Does your API require the user to be authenticated (auth.role() = 'authenticated')? Great. But did you enable Email Confirmations in the Supabase dashboard?

If not, an attacker doesn't need to steal an account. They simply send a POST /auth/v1/signup forging a fake email and receive a valid JWT. To your RLS, they are now a "legitimate" user roaming freely through protected routes.






3. Mass Assignment (Privilege Escalation)



If your users table allows UPDATE (PATCH) requests for the profile owner, what prevents a malicious user from intercepting the request and injecting an extra column into the JSON payload?




{
"name": "Hacker",
"is_admin": true,
"role": "superuser"
}




If your policies don't restrict which columns can be modified, a standard user becomes an admin with a single HTTP request.






🛠️ How to audit your own API?



Testing this manually is painful. It requires capturing keys, forging JWTs, opening Postman, crafting payloads, and testing method by method. Not to mention the risk of running a DELETE test and accidentally wiping out production data.



This is where DAST (Dynamic Application Security Testing) tools come in. The most direct and specialized solution for this ecosystem today is SupaSec.






Meet SupaSec



SupaSec acts as a pentest framework strictly focused on PostgREST quirks. You just input your web app's URL, and it does the dirty work:





  • Automated Reconnaissance: It scans your frontend JavaScript bundles, extracts your Supabase URL and public anon_key, and discovers hidden tables.


  • Ghost Auth Exploitation: The tool automatically tests if your API allows the creation of unconfirmed users to bypass anonymous RLS rules.


  • Data Dumper: Tests the resilience of your SELECT policies by trying to extract records, bypassing pagination limits.


  • Safe Exploit Mode (Dry-Run): This is a killer feature. You can manually test malicious PATCH or DELETE requests directly from the UI safely. SupaSec injects a native Supabase HTTP header (Prefer: tx=rollback, return=representation). This instructs the API to receive your malicious payload, evaluate the RLS rules, return the success/failure result, and then rollback the database transaction in milliseconds—leaving 0 traces and altering exactly zero bytes of production data.






✅ Security Checklist (Do It Today)



Don't wait for a data breach to review your architecture. Open your Supabase dashboard right now:





  1. Enable RLS on absolutely all tables (Authentication > Policies).

  2. Go to Authentication > Providers > Email and toggle Confirm email.

  3. Always use auth.uid() = user_id in your rules; never trust IDs passed via the JSON body.

  4. Scan your application with SupaSec to ensure no sensitive data is leaking on your API's public layer.



Remember: In Serverless and BaaS architectures, frontend convenience dictates the pace, but proper database configuration ensures the developer sleeps soundly at night.

Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Supabase Security: The Hidden Dangers of RLS and How to Audit Your API 🛡️

Thematisch verwandte Begriffe: Supabase, Security, Hidden, Dangers · 6 Treffer

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-96258 | A vulnerability has been found in onSite internet GmbH Auktion NG Auktio…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick