Skip to content
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

Use role from user JWT #307

Open
calj opened this issue Jul 26, 2022 · 0 comments
Open

Use role from user JWT #307

calj opened this issue Jul 26, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@calj
Copy link

calj commented Jul 26, 2022

Feature request

Use the user role to apply a specific RLS policy to requests.

Problem

We would like to extend supabase-studio and give a finer access control to different users based on their role using PostgreSQL RLS feature.

For the moment supabase-studio is using a single API key to access meta with a full access to the database.

Describe the solution you'd like

We would need to use the user role from his session JWT to apply the correct RLS policy.
This mechanism exists in PostREST service.

Describe alternatives you've considered

Our current alternative is to use PostgREST and RLS for non-admin roles and use supabase-studio core functionalities only to the platform admin, which is very limiting.

@calj calj added the enhancement New feature or request label Jul 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant