Add support for OneLogin - #200
Conversation
91465fa to
33656db
Compare
33656db to
242063f
Compare
| SkipPrompt bool | ||
| SkipVerify bool | ||
| Profile string | ||
| Subdomain string |
There was a problem hiding this comment.
Ideally, I don't want to put these 4 new fields there. They are only needed for OneLogin. Any ideas where to put them? I wanted to refactor the library and allow each provider to have custom config and secrets. Such change would make this PR huge so I would split changes and refactoring in different PRs.
|
This PR solves #121 |
|
So as it turns out I am going to add those attributes for another provider soon to support openid based login. Although this is a big change and you have touched a bunch of things I do love getting new providers so happy to take it as is. Cheers for the work you have done! |
|
Is there an example of what need to go in each field. For Subdomain am i adding just the host part or the full url? Where do i get the client_id, secret, and app id |
|
Subdomain is your organisation unique name. It is usually the subdomain part of the One Login dashboard URL. Please, follow this tutorial to generate client credentials https://developers.onelogin.com/api-docs/1/getting-started/working-with-api-credentials |
This PR adds OneLogin provider support. There are few things that would like to discuss. OneLogin is a bit different than other providers. In order to access their API, each application needs to have
app_id,client_id,client_secret. Without these I cannot generate access_token, which is in turn used to generate SAML assertion and to verify MFA options.This PR is very naive and adds the
app_idinto the common configuration and the when prompting for credentials I check if the provider isOneLoginand I validate ifclient_idandclient_secretare provided. Ideally, I would like to refactor the library (i.e. change the signature of the providers) to allow each provider to request/prompt for additional configuration options and keep the common clean. Any feedback and comments would be highly appreciated.Unit tests will be ready very soon.