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

Add API Scopes support #57

Merged
merged 4 commits into from
May 23, 2024
Merged

Add API Scopes support #57

merged 4 commits into from
May 23, 2024

Conversation

jmaupetit
Copy link
Member

@jmaupetit jmaupetit commented May 22, 2024

Purpose

We need to implement scopes to fine tune API access authorizations.

Proposal

  • add User.scopes field
  • check required scopes for each API request (using the get_user security dependency)
  • add scopes to API endpoints

jmaupetit added 3 commits May 21, 2024 09:52
When a realm or any request to the OIDC provider returns a 404, we now
raise an OIDCProviderException instead of failing with an internal
server error.
Draft base user scopes handled at a user level in database.
@jmaupetit jmaupetit self-assigned this May 22, 2024
@jmaupetit jmaupetit marked this pull request as draft May 22, 2024 14:35
All API endpoints now check request user scope to authorize them access
to the queried ressource.
@jmaupetit jmaupetit marked this pull request as ready for review May 22, 2024 17:54
@jmaupetit jmaupetit merged commit 7e44700 into main May 23, 2024
9 checks passed
@jmaupetit jmaupetit deleted the add-api-scopes branch May 23, 2024 07:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant