Enforce RLS when user opted in to MFA. (#188)
* Allow Super Admin to view tables using RLS * Replace previous usages of the Admin client using the authed client using the new RLS * Enforce MFA for Super Admin users * Enforce RLS when user opted in to MFA. * Add Super Admin Access Policies and Update Database Types * Consolidate super admin logic into a single function that uses the RPC is_super_admin * Added Super Admin E2E tests * Fixes and improvements * Bump version to 2.5.0
This commit is contained in:
committed by
GitHub
parent
9cf7bf0aac
commit
131b1061e6
@@ -11,7 +11,7 @@ select tests.create_supabase_user('test2');
|
||||
|
||||
-- Create an team account
|
||||
|
||||
select tests.authenticate_as('test1');
|
||||
select makerkit.authenticate_as('test1');
|
||||
|
||||
select public.create_team_account('Test');
|
||||
|
||||
@@ -33,7 +33,7 @@ select row_eq(
|
||||
|
||||
-- Foreigner should not have permissions to manage members
|
||||
|
||||
select tests.authenticate_as('test2');
|
||||
select makerkit.authenticate_as('test2');
|
||||
|
||||
select row_eq(
|
||||
$$ select public.has_permission(
|
||||
@@ -81,7 +81,7 @@ set local role postgres;
|
||||
-- insert permissions for the custom role
|
||||
insert into public.role_permissions (role, permission) values ('custom-role', 'members.manage');
|
||||
|
||||
select tests.authenticate_as('test1');
|
||||
select makerkit.authenticate_as('test1');
|
||||
|
||||
-- the custom role does not have permissions to manage billing
|
||||
select row_eq(
|
||||
|
||||
Reference in New Issue
Block a user