mirror of
https://github.com/fatedier/frp.git
synced 2026-05-15 16:15:49 -06:00
[GH-ISSUE #3177] [Feature Request] Allow for OIDC "scope" to be defined #2550
Labels
No labels
In Progress
WIP
WaitingForInfo
bug
doc
duplicate
easy
enhancement
future
help wanted
invalid
lifecycle/stale
need-issue-template
need-usage-help
no plan
proposal
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/frp#2550
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @mattfeury on GitHub (Nov 17, 2022).
Original GitHub issue: https://github.com/fatedier/frp/issues/3177
Originally assigned to: @blizard863 on GitHub.
Hello,
Currently trying to use FRP with oidc and auth0. Things work well, but it appears that the oidc calls hardcode the "Scopes" to the "audience" parameter.
da51adc276/pkg/auth/oidc.go (L105)In auth0, we have defined scopes, e.g.
users:readetc that are substantially different from the audience. Attempting to use it with the sensible defaults fails because it's trying to validate a scope that doesn't exist.Client has not been granted scopes {audience_value}. It seems that conflating audience with scope is problematic, at least for auth0, so i'd rather be able to define those values separately. does anyone see issue with this? seems like it's really that one offending line.Describe alternatives you've considered
i've tried to use
oidc_additional_*fields, but it appears thatoidc_additional_scopecan not be overwritten:Affected area
@fatedier commented on GitHub (Nov 18, 2022):
cc @blizard863
@blizard863 commented on GitHub (Nov 20, 2022):
When I test by auth0 service, the client OidcAudience field must be set empty. You can have a try.
I test by auth0 and authing service. The following configs can all pass.
auth0
authing
I also think use audience value to scopes is confused. In oidc spec, scopes is an open field to be set and no audience field.
https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims.
https://www.rfc-editor.org/rfc/rfc6749
I think the proper config is:
oidc_audience -> oidc_scopes
@blizard863 commented on GitHub (Nov 20, 2022):
And in oidc official website, the scopes and audience is seperated, not equal.

https://openidconnect.net/
So it is need to define a scopes args, not just use audience.
@mattfeury commented on GitHub (Nov 21, 2022):
when i attempt this, i get:
but regardless, it sounds like, based on your second comment, that we are agreed that we need to allow a scopes argument.
@blizard863 commented on GitHub (Nov 23, 2022):
Yes, I will test it again and refine the arguments.
@mattfeury commented on GitHub (Nov 29, 2022):
made a PR here! https://github.com/fatedier/frp/pull/3192
feel free to let me know what you think or tweak as desired