mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Merge pull request #811 from janakamarasena/bug-fixes-1
Added proper request handling when invalid token is received
This commit is contained in:
commit
d4b99e1f27
@ -99,6 +99,8 @@ public class AccessTokenGrantHandler extends AbstractAuthorizationGrantHandler {
|
||||
username = response.getUserName();
|
||||
userTenantDomain = MultitenantUtils.getTenantDomain(username);
|
||||
spTenantDomain = response.getTenantDomain();
|
||||
} else if (response != null && !response.isValid()) {
|
||||
throw new IdentityOAuth2Exception("Authentication failed for the provided access token");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user