ory / hydra

The most scalable and customizable OpenID Certified™ OpenID Connect and OAuth Provider on the market. Become an OpenID Connect and OAuth2 Provider over night. Broad support for related RFCs. Written in Go, cloud native, headless, API-first. Available as a service on Ory Network and for self-hosters.
https://www.ory.sh/?utm_source=github&utm_medium=banner&utm_campaign=hydra
Apache License 2.0
15.5k stars 1.49k forks source link

Add scope strategy allowing different separator for prefixes, resources and verbs #3751

Open zoop-btc opened 6 months ago

zoop-btc commented 6 months ago

Preflight checklist

Ory Network Project

No response

Describe your problem

I want to implement a scope strategy in my Application which allows for different separators between dynamic scopes, resources & verbs. Right now this is the closest we can get.

Describe your ideal solution

The ideal solution would be to follow this recommendation. For summary we'd have these things to check for:

Workarounds or alternatives

I would have to use . as separator exclusively, making it hard to differentiate between prefix, resource and verb in my application. Or I'd need to compile my own fosite & hydra with my custom scope strategy which adds significant complexity to my deployment pipeline & maintenance.

Version

latest

Additional Context

I'd also be happy if I could just use the prefix scopes and continue to use . as resource as well as verb separator.

zoop-btc commented 6 months ago

it looks like you were amenable to such an implementation here, I will create a fosite PR for this then

opened draft PR here - feedback welcome