A JWT role of none bypassed row-level security in Supabase Storage
Short answer
On November 6, 2026, Supabase published GHSA-fgvp-cqg6-q8h2. Storage 1.89.8 and earlier accepted a valid signed JWT whose role claim was the string none, then ran the database work as the Storage connection user. When that user owns the tables and row-level security is not forced on the owner, policies are skipped. The advisory says that could allow reads from private buckets, uploads, and bucket creation. Exploitation needs a trusted token issuer, such as a custom access-token hook, to mint that claim. The hosted platform is already patched. Self-hosted installs need 1.89.9 or later.
Last updated · Sekrd Research
- Advisory: GHSA-fgvp-cqg6-q8h2, published November 6, 2026. Critical. No CVE id is shown.
- Affected: Storage versions 1.89.8 and earlier. Patched version in the advisory table: 1.89.9. The summary text still contains the placeholder FIRST_FIXED_VERSION.
- Hosted Supabase: the advisory says the hosted platform is already patched.
- Requirement: a trusted issuer must sign a token with role none. Editing the claim without a valid signature does not work.
- CVSS: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H. CWE-270 and CWE-863. Reported by SeanSdahl-mercura.
What happened
Supabase Storage takes the role claim from a verified JWT and passes it to Postgres with set_config('role', $1, true). Postgres treats the exact value none as a special case: it resets the effective role to the session user. Storage connects as supabase_storage_admin. That user owns the Storage tables. In Postgres, a table owner is exempt from row-level security unless FORCE ROW LEVEL SECURITY is on. Superuser rights and the BYPASSRLS attribute are not required for that exemption.
The November 6 advisory says a request with a valid signature and role: "none" could therefore read from private buckets, upload objects, and create buckets. Request logs can still show role: none and the caller’s user id, because those fields come from the JWT, not from the role Postgres actually used.
Timeline
- November 6, 2026. Advisory published. Affected: 1.89.8 and earlier. Patched table entry: 1.89.9.
- Hosted platform. Stated as already patched. Self-hosted operators are told to upgrade, and are given interim steps if they cannot.
- The fix: reject
nonebefore the database authorization context is applied, and return AccessDenied. Legitimateservice_roleaccess and custom database roles are preserved. Regression tests cover private reads, uploads, bucket creation, TUS authorization, and S3 session-token authorization.
Who can actually trigger it
This is not “change the role field in a token you found in the browser.” The advisory says modifying the role in an existing token without a valid signature does not enable the bypass. Someone the project trusts to sign tokens has to issue role: "none". The example Supabase gives is a custom access-token hook. An arbitrary role name that does not exist is rejected by Postgres. An empty or missing role falls back to anon. Only the reserved value none resets the role to the session user.
That makes the bug narrower than a missing RLS policy, and still serious where the hook exists. A hook written to mean “no elevated role” used a string Postgres already reserved. The Storage service trusted the claim and forwarded it. CWE-270 is the privilege-context mistake. CWE-863 is the authorization check that did not mean what the caller thought.
If you cannot upgrade immediately, the advisory says to stop the hook, or any other trusted issuer, from emitting role: "none", and to use a real database role that has the permissions you intend. Changing issuance does not invalidate tokens already signed. Until 1.89.9 is running, reject none at every exposed Storage entry point, or restrict access until those tokens expire. A gateway rule is not enough if clients can reach the Storage origin directly.
How to check if your app is exposed
- Search the project for a custom access token hook. In the Supabase dashboard this is an Auth hook. In a self-hosted repo it is whatever function mints the JWT. If it can set
roleto the stringnone, that is the condition the advisory names. - If you self-host, compare the storage-api version to 1.89.9. At or below 1.89.8 is affected. Upgrade. The advisory’s prose still says upgrade to FIRST_FIXED_VERSION; the version table says 1.89.9.
- If you are on Supabase Cloud, the advisory says the hosted platform is already patched. You still need to stop issuing
role: "none"if a hook does that, because old tokens remain valid until they expire even after the code that minted them changes. The patched service rejects the claim. Confirm the hook anyway so you are not depending on a string you did not mean to send. - Do not test the bypass against a project you do not own, and do not paste a forged token into a production project to “see if it works.” The check is the version and the hook source.
- Keep ordinary RLS in place. This bug skipped policies by becoming the table owner. A policy of
USING (true)is a different, much more common failure, covered in why enabled is not closed and the RLS checklist.
How Sekrd helps
Sekrd does not mint JWTs and does not send a role: none token at your Storage API. A deep scan can show whether the publishable key already reads tables, which is the misconfiguration this bug is easy to confuse with. The rule is supabase-rls-bypass. Policy text is read only when you attach a database password. Without that, Sekrd does not claim to have seen pg_policies.
The October 14 upload bypass is a separate patch, 1.80.2, and it is not implied by being on 1.89.9. Read both advisories if you self-host. Then scan the app that uses the project: Supabase RLS checker, or a free scan if you only have the public URL.
Related reading
Frequently asked questions
What is the patched version for the Supabase Storage role none bug?
The advisory’s version table lists 1.89.9 as patched and 1.89.8 and earlier as affected. The summary paragraph still contains the placeholder FIRST_FIXED_VERSION.
Does a self-signed or edited JWT work?
No. The advisory says the token has to be validly signed, and that changing the role claim without a valid signature does not enable the bypass. A trusted issuer, such as a custom access-token hook, has to mint role none.
Is Supabase Cloud affected now?
The November 6, 2026 advisory says the hosted platform is already patched. Self-hosted Storage at 1.89.8 or earlier still needs an upgrade.
Why does Postgres treat none as special?
The advisory says set_config of the role to the exact value none resets the effective role to the session user. For Storage that user is supabase_storage_admin, which owns the tables and skips RLS unless FORCE ROW LEVEL SECURITY is set.
Does FORCE ROW LEVEL SECURITY fix it without an upgrade?
The advisory explains that owner exemption is what makes the bug work when FORCE ROW LEVEL SECURITY is off. Its recommended fix is still to upgrade to 1.89.9, which rejects the claim before setting the role. It does not present FORCE ROW LEVEL SECURITY as a complete substitute.
Sources
Don't ship until you're sekrd
Run a free scan to find the vulnerabilities your AI missed.
Scan Your App Free