fix(supabase): no USAGE on schema private for anon; pin it and RPC EXECUTE in pgTAP

This commit is contained in:
bchanot committed 2026-10-08 22:47:20 +02:00
1 parent 1dd45a3109
commit 1e7d0327cc
2 files changed
+5 -2

No files matched your search

@@ -15,7 +15,8 @@ revoke all on schema private from public;
revoke all on schema audit from public;
-- Policies evaluated for API roles call private.* helpers by qualified name,
-- which needs USAGE on the schema. EXECUTE is granted per function below.
grant usage on schema private to anon, authenticated, service_role;
-- anon gets nothing: no policy for anon evaluates a helper yet.
grant usage on schema private to authenticated, service_role;
grant usage on schema audit to authenticated, service_role;
-- PostgreSQL grants EXECUTE on every new function to PUBLIC. Flip the default