Mapping user roles to oauth2 scopes/authorities
We have a entitlements database which has application id, roles and users mapped to roles per application. Following the advice on thread how do I map user roles to oauth2 scopes/authorities based on resourceId? Ignoring the entitlements database I mentioned above do I map roles "USER", "READER", "WRITER" to oauth2 scopes/authorities based on user and resourceId in below code? User Authentication/Authorization Config @Configuration @Order(-10) protected static class LoginConfig extends WebSecurityConfigurerAdapter { .... @Override protected void configure(AuthenticationManagerBuilder auth)