fix(supabase): V1-2.1 close the second verifier and security findings
Save and submit lock the sheet before the version; change_note length and a blank FR name answer closed codes; pgTAP for a capability refused to a factorless account and the five remaining historical-sheet RPC refusals.
This commit is contained in:
1 parent
4a829416c6
commit
961995804a
4 files changed
+47
-10
No files matched your search
@@ -5,7 +5,7 @@
|
||||
-- proven in packages/supabase/tests/sandbox/sheets.sandbox.ts, the seed owner's
|
||||
-- factors on an upgraded stack in seed-owner-mfa.sandbox.ts.
|
||||
begin;
|
||||
select plan(36);
|
||||
select plan(37);
|
||||
|
||||
insert into auth.users (id, email, email_confirmed_at) values
|
||||
('d0000000-0000-0000-0000-000000000001', 'own@t.local', now()), -- owner
|
||||
@@ -158,6 +158,10 @@ select lives_ok(
|
||||
select lives_ok(
|
||||
$$ select public.grant_catalog_right('d0000000-0000-0000-0000-00000000000c','catalog_reader','beta') $$,
|
||||
'catalog_reader needs no note or factor');
|
||||
-- a capability never goes to an account without a verified factor (§5.2)
|
||||
select throws_ok(
|
||||
$$ select public.grant_catalog_right('d0000000-0000-0000-0000-00000000000c','sheet_reviewer','partner','DVM verified') $$,
|
||||
'P0001', 'grant.ineligible', 'a capability is refused to an account without a verified factor');
|
||||
-- the owner cannot grant itself sheet_reviewer
|
||||
select throws_ok(
|
||||
$$ select public.grant_catalog_right('d0000000-0000-0000-0000-000000000001','sheet_reviewer','self','x') $$,
|
||||
|
||||
Reference in new issue
Block a user