@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetAttribute attribute) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, attribute), runAsRoles, true); }
@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetResource resource) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, resource), runAsRoles, true); }
@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetResource resource) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, resource), runAsRoles, true); }
@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetResource resource) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, resource), runAsRoles, true); }
@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetAttribute attribute) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, attribute), runAsRoles, true); }
@Override public Set<String> mapRoles(Caller caller, Environment callEnvironment, Action action, TargetAttribute attribute) { Set<String> runAsRoles = getOperationHeaderRoles(action.getOperation()); return mapRoles(caller, realRoleMapper.mapRoles(caller, callEnvironment, action, attribute), runAsRoles, true); }
@Override public void execute(OperationContext context, ModelNode operation) throws OperationFailedException { String roleName = RoleMappingResourceDefinition.getRoleName(operation); if (context.getCurrentStage() == Stage.MODEL) { context.addStep(this, Stage.RUNTIME); } else { ModelNode result = context.getResult(); Set<String> operationHeaderRoles = RunAsRoleMapper.getOperationHeaderRoles(operation); result.set(isCallerInRole(roleName, context.getCaller(), context.getCallEnvironment(), operationHeaderRoles)); } }
@Override public void execute(OperationContext context, ModelNode operation) throws OperationFailedException { String roleName = RoleMappingResourceDefinition.getRoleName(operation); if (context.getCurrentStage() == Stage.MODEL) { context.addStep(this, Stage.RUNTIME); } else { ModelNode result = context.getResult(); Set<String> operationHeaderRoles = RunAsRoleMapper.getOperationHeaderRoles(operation); result.set(isCallerInRole(roleName, context.getCaller(), context.getCallEnvironment(), operationHeaderRoles)); } }
Set<String> mappedRoles = authorizer == null ? null : authorizer.getCallerRoles(context.getCaller(), context.getCallEnvironment(), RunAsRoleMapper.getOperationHeaderRoles(operation)); if (mappedRoles != null) { ModelNode rolesModel = result.get(MAPPED_ROLES);
Set<String> mappedRoles = authorizer == null ? null : authorizer.getCallerRoles(context.getCaller(), context.getCallEnvironment(), RunAsRoleMapper.getOperationHeaderRoles(operation)); if (mappedRoles != null) { ModelNode rolesModel = result.get(MAPPED_ROLES);