lua-resty-openidc
lua-resty-openidc copied to clipboard
added support for registrations endpoint
Some OAuth providers provide an endpoint for a registration page instead of a login page. By configuring the registrations_path and registrations_endpoint, the openidc_authorize function will redirect to the configured endpoint including the same parameters as the authorization endpoint and prepare the session.
Can be used e.g. for providing direct Links to Keycloak's registration page.
@zandbelt Could you please take a look at this?
I don't see why this should be part of lua-resty-openidc. One could just as well provide the registration link of the provider directly to the user instead of redirecting through the path on the RP, isn't it?
@zandbelt To have a working link (and backlink), the session must be created and the state/redirect URL etc. must be appended to the registrations URL. At least in my use-case for Keycloak. If I want to do it outside of the library I have to duplicate a lot of code from the library as all the helper methods are private. Thought this could also help others.
We don't use it anymore, as it is not OpenID conform