I have a spring boot application with a couple rest endpoints. I am trying to user oaut2 together with okta to limit access to these endpoints depending on roles. So far I have done this:
I have been able to get a BEARER token by calling :
oauth2/default/v1/token
Then I can use the token to hit my endpoints in localhost.
I tried to use some of this https://developer.okta.com/blog/2017/10/13/okta-groups-spring-security
to implement the access based on user group. Now The problem is that when calling oauth2/default/v1/token I am using the user and password provided as client id and client credentials in my application.
Is there any way to generate tokens by calling the /token endpoint that contain user specific information?