Menu

Post image 1
Post image 2
1 / 2
0

Supabase RLS in production: four traps that silence your queries

DEV Community·Michel Faure·about 1 month ago
#RBMcDUjY
#trap#supabase#postgres#security#policy#anon
Reading 0:00
15s threshold

« Your enrollments — how many? Because I see zero » One Tuesday morning, I had just enabled RLS on eighteen tables of Rembrandt , L'Atelier Palissy's ERP. Policies written, tested in direct SQL , everything passing. Prod deploy, coffee. Françoise calls from the next office — she doesn't come over, she shouts from her chair. « Bon. Tes inscriptions sur le site de Maisons-Laffitte, il y en a combien, dis-moi ? Moi j'en vois zéro. » — Right. Your enrollments on the Maisons-Laffitte site, how many are there? Because I see zero. I open the same page on my machine. Zero too. No exception, no 500, no Sentry error log. Just zero rows, which is precisely what makes the bug dangerous: Françoise sees nothing to fix, she sees an empty school. Row Level Security is one of the rare Postgres/Supabase features that can break your application silently . A misconfiguration doesn't return an error. It returns an empty set, or worse, a partial set that passes through code without alerting it.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More