-
-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add jwks support #407
Conversation
4d11f54
to
c77fe93
Compare
78a6aa7
to
f4895a6
Compare
You will need to add a migration under |
Oh yeah, forgot about that! |
fe3c5a9
to
565f617
Compare
@fenos Can you check why the tests are failing -- I can't seem to figure out what the error is. |
565f617
to
b7d73a8
Compare
🎉 This PR is included in version 0.47.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Adds JWKS support, similar to what PostgREST supports.
Why is this necessary?
This opens up avenues where foreign JWTs like those issued by Firebase Auth, Cognito, Clerk, Auth0 can be used directly with Storage, bypassing Supabase Auth or other symmetric use cases.
It also helps with secret rotation.
How it works?
Set the
JWT_JWKS
env var to a JWKS value. In a multi-tenant setup thejwt_jwks
column should encode the JWKS as a string, which is then parsed.Security Information
This only affects storage calls that are made "in the name of the user." Signed URLs still continue to use the secret and ignore the existence of the JWKS.
JWK support is built-in to Node.js, so no third-party libraries are used.