Class SimpleAuthorizingInterceptor
- java.lang.Object
-
- org.apache.cxf.phase.AbstractPhaseInterceptor<Message>
-
- org.apache.cxf.interceptor.security.AbstractAuthorizingInInterceptor
-
- org.apache.cxf.interceptor.security.SimpleAuthorizingInterceptor
-
- All Implemented Interfaces:
Interceptor<Message>,PhaseInterceptor<Message>
- Direct Known Subclasses:
OperationInfoAuthorizingInterceptor,SecureAnnotationsInterceptor
public class SimpleAuthorizingInterceptor extends AbstractAuthorizingInInterceptor
-
-
Field Summary
Fields Modifier and Type Field Description protected List<String>globalRolesprotected Map<String,List<String>>methodRolesMapprotected Map<String,List<String>>userRolesMap
-
Constructor Summary
Constructors Constructor Description SimpleAuthorizingInterceptor()SimpleAuthorizingInterceptor(boolean uniqueId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected StringcreateMethodSig(Method method)protected List<String>getExpectedRoles(Method method)Returns a list of expected roles for a given method.protected booleanisUserInRole(SecurityContext sc, List<String> roles, boolean deny)voidsetCheckConfiguredRolesOnly(boolean checkConfiguredRolesOnly)voidsetGlobalRoles(String roles)voidsetMethodRolesMap(Map<String,String> rolesMap)voidsetUserRolesMap(Map<String,String> rolesMap)-
Methods inherited from class org.apache.cxf.interceptor.security.AbstractAuthorizingInInterceptor
authorize, getDenyRoles, handleMessage, isAllowAnonymousUsers, isMethodProtected, setAllowAnonymousUsers
-
Methods inherited from class org.apache.cxf.phase.AbstractPhaseInterceptor
addAfter, addAfter, addBefore, addBefore, getAdditionalInterceptors, getAfter, getBefore, getId, getPhase, handleFault, isGET, isRequestor, setAfter, setBefore
-
-
-
-
Method Detail
-
isUserInRole
protected boolean isUserInRole(SecurityContext sc, List<String> roles, boolean deny)
- Overrides:
isUserInRolein classAbstractAuthorizingInInterceptor
-
getExpectedRoles
protected List<String> getExpectedRoles(Method method)
Description copied from class:AbstractAuthorizingInInterceptorReturns a list of expected roles for a given method.- Specified by:
getExpectedRolesin classAbstractAuthorizingInInterceptor- Parameters:
method- Method- Returns:
- list, empty if no roles are available
-
setGlobalRoles
public void setGlobalRoles(String roles)
-
setCheckConfiguredRolesOnly
public void setCheckConfiguredRolesOnly(boolean checkConfiguredRolesOnly)
-
-