jpf / okta-oidc-beta

Instructions and sample code for Okta's OpenID Connect Beta
Other
22 stars 11 forks source link

Key doesn't contain x5c #4

Open petergillardmoss opened 8 years ago

petergillardmoss commented 8 years ago

The following line fails as there is no x5c in the dictionary: https://github.com/jpf/okta-oidc-beta/blob/master/app.py#L139

The Okta docs do not mention an x5c key either: http://developer.okta.com/docs/api/resources/oidc.html#get-keys

lucaslago commented 8 years ago

Has anyone figured this out? The docs now mention x5c key but there's still none in the dictionary.

lucaslago commented 8 years ago

It turns out they don't expose a x5c key anymore and Okta documentation is outdated. http://stackoverflow.com/questions/38727528/is-okta-oidc-documentation-outdated/38947218#38947218

cmollis commented 7 years ago

yes. this documentation is outdated. I struggled with this for a while but, after reviewing the JWKS that gets returned from oauth2/v1/keys

I was able to get the login working by:

modifying the client: app.py comment out line 114:

this isn't needed cleaned_key_id = re.sub(not_alpha_numeric, '', dirty_key_id)

add line 115: cleaned_key_id = dirty_key_id

Also, set up your application's (i.e. the one that you have manually set in the okta admin ui when you create the OAuth2 application) redirect URL to //sso/oidc

The last part wasn't in the directions. I saw this by running the browser debugger.

Hope this helps.