Class UserRestrictionTokenEnhancer
- java.lang.Object
-
- com.broadleafcommerce.auth.user.session.token.enhancer.AbstractUserTokenEnhancer
-
- com.broadleafcommerce.auth.user.session.token.enhancer.UserRestrictionTokenEnhancer
-
- All Implemented Interfaces:
org.springframework.security.oauth2.provider.token.TokenEnhancer
public class UserRestrictionTokenEnhancer extends AbstractUserTokenEnhancer
Token enhancer that includes user restrictions and restricted authorities within the token.- Author:
- Nick Crum (ncrum)
-
-
Constructor Summary
Constructors Constructor Description UserRestrictionTokenEnhancer(PermissionRepository permissionRepository)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.security.oauth2.common.OAuth2AccessToken
enhance(org.springframework.security.oauth2.common.OAuth2AccessToken accessToken, org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
protected PermissionRepository
getPermissionRepository()
protected OAuth2UserDetails
getUserDetails(org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
-
Methods inherited from class com.broadleafcommerce.auth.user.session.token.enhancer.AbstractUserTokenEnhancer
getUser, getUserService, isAnonymousCsrImpersonation, setUserContext, setUserService, shouldEnhance
-
-
-
-
Constructor Detail
-
UserRestrictionTokenEnhancer
public UserRestrictionTokenEnhancer(PermissionRepository permissionRepository)
-
-
Method Detail
-
enhance
public org.springframework.security.oauth2.common.OAuth2AccessToken enhance(org.springframework.security.oauth2.common.OAuth2AccessToken accessToken, org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
-
getUserDetails
@Nullable protected OAuth2UserDetails getUserDetails(org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
-
getPermissionRepository
protected PermissionRepository getPermissionRepository()
-
-