travisghansen / external-auth-server

easy auth for reverse proxies
MIT License
330 stars 44 forks source link

Userinfo and Oauth2 flow #120

Closed nonefaken closed 3 years ago

nonefaken commented 3 years ago

Hello,

is "userinfo" functionality available in Oauth2 plugin?

I know the difference of use cases for oauth2 flows and getting openid flow, but wonder if it is possible, because you can include openid scope in Oauth2 flow/plugin:

scopes: ["user offline_access email profile openid"]

Also oauth2 plugin example contain userinfo configuration for github: https://github.com/travisghansen/external-auth-server/blob/e4646e151ca9062e0ace68b748fcd8d7c9c7471c/PLUGINS.md#oauth2

Thank you!

travisghansen commented 3 years ago

Userinfo is part of the oidc spec and so is natively supported there. With oauth2 it’s implemented on a provider by provider basis with currently only support for github. Others could be added to the code base however.

nonefaken commented 3 years ago

Clear. Thank you!