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

FEAT: Per-user permissions when using OAuth #763

Open
michael-pattern opened this issue Apr 30, 2024 · 0 comments
Open

FEAT: Per-user permissions when using OAuth #763

michael-pattern opened this issue Apr 30, 2024 · 0 comments

Comments

@michael-pattern
Copy link
Contributor

Is your feature request related to a problem? Please describe.
My organization is using OAuth to authenticate users. I was under the impression that we could use the existing LOGIN_PERMISSIONS_[login] environment variable to handle this, however, diving into the code further shows that these permissions only function with password-based authentication.

Describe the solution you'd like
We would like to be able to set permissions per-user, based on the login value retrieved during the authentication process.

My vision is, when a user logs-in, and their username is determined, we can use their corresponding LOGIN_PERMISSIONS_[login] entry to determine their dbgate-level permissions. If there's no corresponding entry for the user, then they are given the default PERMISSIONS as a 'catch-all'. I'd envision setting the default value for this as PERMISSIONS=~*, at least in my use-case.

Describe alternatives you've considered
I am considering using password-based authentication, while gating access to dbgate entirely behind OAuth, so you have to login twice in order to use the system ultimately. While this would work, I'd much prefer being able to offer only one login screen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant