Search in sources :

Example 71 with XXPortalUser

use of org.apache.ranger.entity.XXPortalUser in project ranger by apache.

the class TestXUserMgr method test94DeleteXUser.

@Test
public void test94DeleteXUser() {
    setup();
    boolean force = false;
    VXUser vXUser = vxUser();
    XXUser xXUser = new XXUser();
    XXUserDao xXUserDao = Mockito.mock(XXUserDao.class);
    Mockito.when(daoManager.getXXUser()).thenReturn(xXUserDao);
    Mockito.when(xXUserDao.getById(vXUser.getId())).thenReturn(xXUser);
    Mockito.when(xUserService.populateViewBean(xXUser)).thenReturn(vXUser);
    VXGroupUserList vxGroupUserList = new VXGroupUserList();
    Mockito.when(xGroupUserService.searchXGroupUsers((SearchCriteria) Mockito.any())).thenReturn(vxGroupUserList);
    VXAuditMapList vXAuditMapList = new VXAuditMapList();
    Mockito.when(xAuditMapService.searchXAuditMaps((SearchCriteria) Mockito.any())).thenReturn(vXAuditMapList);
    VXPortalUser vXPortalUser = userProfile();
    XXPortalUser xXPortalUser = xxPortalUser(vXPortalUser);
    XXPortalUserDao xXPortalUserDao = Mockito.mock(XXPortalUserDao.class);
    Mockito.when(daoManager.getXXPortalUser()).thenReturn(xXPortalUserDao);
    Mockito.when(xXPortalUserDao.findByLoginId(vXUser.getName().trim())).thenReturn(xXPortalUser);
    Mockito.when(xPortalUserService.populateViewBean(xXPortalUser)).thenReturn(vXPortalUser);
    XXPortalUserRole XXPortalUserRole = new XXPortalUserRole();
    XXPortalUserRole.setId(userId);
    XXPortalUserRole.setUserId(userId);
    XXPortalUserRole.setUserRole("ROLE_USER");
    XXAuthSessionDao xXAuthSessionDao = Mockito.mock(XXAuthSessionDao.class);
    XXUserPermissionDao xXUserPermissionDao = Mockito.mock(XXUserPermissionDao.class);
    XXPortalUserRoleDao xXPortalUserRoleDao = Mockito.mock(XXPortalUserRoleDao.class);
    Mockito.when(daoManager.getXXAuthSession()).thenReturn(xXAuthSessionDao);
    Mockito.when(daoManager.getXXUserPermission()).thenReturn(xXUserPermissionDao);
    Mockito.when(daoManager.getXXPortalUserRole()).thenReturn(xXPortalUserRoleDao);
    List<XXAuthSession> xXAuthSessions = new ArrayList<XXAuthSession>();
    XXAuthSession xXAuthSession = new XXAuthSession();
    xXAuthSession.setId(userId);
    xXAuthSession.setLoginId(vXPortalUser.getLoginId());
    List<XXUserPermission> xXUserPermissions = new ArrayList<XXUserPermission>();
    List<XXPortalUserRole> xXPortalUserRoles = new ArrayList<XXPortalUserRole>();
    Mockito.when(xXAuthSessionDao.getAuthSessionByUserId(vXPortalUser.getId())).thenReturn(xXAuthSessions);
    Mockito.when(xXUserPermissionDao.findByUserPermissionId(vXPortalUser.getId())).thenReturn(xXUserPermissions);
    Mockito.when(xXPortalUserRoleDao.findByUserId(vXPortalUser.getId())).thenReturn(xXPortalUserRoles);
    XXPolicyDao xXPolicyDao = Mockito.mock(XXPolicyDao.class);
    List<XXPolicy> xXPolicyList = new ArrayList<XXPolicy>();
    Mockito.when(daoManager.getXXPolicy()).thenReturn(xXPolicyDao);
    Mockito.when(xXPolicyDao.findByUserId(vXUser.getId())).thenReturn(xXPolicyList);
    List<XXSecurityZoneRefUser> zoneSecRefUser = new ArrayList<XXSecurityZoneRefUser>();
    XXSecurityZoneRefUserDao zoneSecRefUserDao = Mockito.mock(XXSecurityZoneRefUserDao.class);
    Mockito.when(daoManager.getXXSecurityZoneRefUser()).thenReturn(zoneSecRefUserDao);
    Mockito.when(zoneSecRefUserDao.findByUserId(userId)).thenReturn(zoneSecRefUser);
    List<XXRoleRefUser> roleRefUser = new ArrayList<XXRoleRefUser>();
    XXRoleRefUserDao roleRefUserDao = Mockito.mock(XXRoleRefUserDao.class);
    Mockito.when(daoManager.getXXRoleRefUser()).thenReturn(roleRefUserDao);
    Mockito.when(roleRefUserDao.findByUserId(userId)).thenReturn(roleRefUser);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xGroupUserService.searchXGroupUsers((SearchCriteria) Mockito.any())).thenReturn(new VXGroupUserList());
    XXPolicy xXPolicy = getXXPolicy();
    xXPolicyList.add(xXPolicy);
    Mockito.when(xXPolicyDao.findByUserId(userId)).thenReturn(xXPolicyList);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xXPolicyDao.findByUserId(userId)).thenReturn(new ArrayList<XXPolicy>());
    VXPermMapList vXPermMapList = new VXPermMapList();
    VXPermMap vXPermMap1 = getVXPermMap();
    List<VXPermMap> vXPermMaps = new ArrayList<VXPermMap>();
    vXPermMaps.add(vXPermMap1);
    vXPermMapList.setVXPermMaps(vXPermMaps);
    Mockito.when(xPermMapService.searchXPermMaps((SearchCriteria) Mockito.any())).thenReturn(vXPermMapList);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xPermMapService.searchXPermMaps((SearchCriteria) Mockito.any())).thenReturn(new VXPermMapList());
    List<VXAuditMap> vXAuditMaps = new ArrayList<VXAuditMap>();
    VXAuditMap vXAuditMap = getVXAuditMap();
    vXAuditMaps.add(vXAuditMap);
    vXAuditMapList.setVXAuditMaps(vXAuditMaps);
    Mockito.when(xAuditMapService.searchXAuditMaps((SearchCriteria) Mockito.any())).thenReturn(vXAuditMapList);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xAuditMapService.searchXAuditMaps((SearchCriteria) Mockito.any())).thenReturn(new VXAuditMapList());
    xXAuthSessions.add(xXAuthSession);
    Mockito.when(xXAuthSessionDao.getAuthSessionByUserId(vXPortalUser.getId())).thenReturn(xXAuthSessions);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xXAuthSessionDao.getAuthSessionByUserId(vXPortalUser.getId())).thenReturn(new ArrayList<XXAuthSession>());
    XXUserPermission xUserPermissionObj = xxUserPermission();
    xXUserPermissions.add(xUserPermissionObj);
    Mockito.when(xXUserPermissionDao.findByUserPermissionId(vXPortalUser.getId())).thenReturn(xXUserPermissions);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xXUserPermissionDao.findByUserPermissionId(vXPortalUser.getId())).thenReturn(new ArrayList<XXUserPermission>());
    xXPortalUserRoles.add(XXPortalUserRole);
    Mockito.when(xXPortalUserRoleDao.findByUserId(vXPortalUser.getId())).thenReturn(xXPortalUserRoles);
    xUserMgr.deleteXUser(vXUser.getId(), force);
    Mockito.when(xXPortalUserRoleDao.findByUserId(vXPortalUser.getId())).thenReturn(new ArrayList<XXPortalUserRole>());
    xUserMgr.deleteXUser(vXUser.getId(), force);
    vXUser.setName("");
    Mockito.when(xXUserDao.getById(vXUser.getId())).thenReturn(xXUser);
    Mockito.when(xUserService.populateViewBean(xXUser)).thenReturn(vXUser);
    thrown.expect(NullPointerException.class);
    xUserMgr.deleteXUser(vXUser.getId(), force);
}
Also used : XXRoleRefUser(org.apache.ranger.entity.XXRoleRefUser) XXUser(org.apache.ranger.entity.XXUser) VXGroupUserList(org.apache.ranger.view.VXGroupUserList) VXPermMap(org.apache.ranger.view.VXPermMap) XXUserDao(org.apache.ranger.db.XXUserDao) ArrayList(java.util.ArrayList) XXSecurityZoneRefUser(org.apache.ranger.entity.XXSecurityZoneRefUser) XXPolicy(org.apache.ranger.entity.XXPolicy) XXAuthSessionDao(org.apache.ranger.db.XXAuthSessionDao) XXPortalUserRoleDao(org.apache.ranger.db.XXPortalUserRoleDao) VXPortalUser(org.apache.ranger.view.VXPortalUser) VXAuditMap(org.apache.ranger.view.VXAuditMap) XXPortalUserRole(org.apache.ranger.entity.XXPortalUserRole) VXPermMapList(org.apache.ranger.view.VXPermMapList) XXRoleRefUserDao(org.apache.ranger.db.XXRoleRefUserDao) XXUserPermissionDao(org.apache.ranger.db.XXUserPermissionDao) VXAuditMapList(org.apache.ranger.view.VXAuditMapList) VXUser(org.apache.ranger.view.VXUser) XXAuthSession(org.apache.ranger.entity.XXAuthSession) XXUserPermission(org.apache.ranger.entity.XXUserPermission) XXPortalUser(org.apache.ranger.entity.XXPortalUser) XXSecurityZoneRefUserDao(org.apache.ranger.db.XXSecurityZoneRefUserDao) XXPortalUserDao(org.apache.ranger.db.XXPortalUserDao) XXPolicyDao(org.apache.ranger.db.XXPolicyDao) Test(org.junit.Test)

Example 72 with XXPortalUser

use of org.apache.ranger.entity.XXPortalUser in project ranger by apache.

the class TestXUserMgr method test104getKeyAdminAuditorUserDetailsWithUserHavingUSER_ROLE.

@Test
public void test104getKeyAdminAuditorUserDetailsWithUserHavingUSER_ROLE() {
    destroySession();
    RangerSecurityContext context = new RangerSecurityContext();
    context.setUserSession(new UserSessionBase());
    RangerContextHolder.setSecurityContext(context);
    UserSessionBase currentUserSession = ContextUtil.getCurrentUserSession();
    currentUserSession.setUserAdmin(false);
    XXPortalUser xXPortalUser = new XXPortalUser();
    xXPortalUser.setLoginId(userLoginID);
    xXPortalUser.setId(userId);
    currentUserSession.setXXPortalUser(xXPortalUser);
    VXUser loggedInUser = vxUser();
    List<String> loggedInUserRole = new ArrayList<String>();
    loggedInUserRole.add(RangerConstants.ROLE_USER);
    loggedInUser.setId(8L);
    loggedInUser.setName("testuser");
    loggedInUser.setUserRoleList(loggedInUserRole);
    VXUser vxUser = vxUser();
    List<String> userRole = new ArrayList<String>();
    userRole.add(RangerConstants.ROLE_KEY_ADMIN_AUDITOR);
    vxUser.setId(5L);
    vxUser.setName("test3");
    vxUser.setUserRoleList(userRole);
    vxUser.setUserSource(RangerCommonEnums.USER_UNIX);
    Mockito.when(xUserService.readResourceWithOutLogin(5L)).thenReturn(vxUser);
    Mockito.when(xUserService.getXUserByUserName("testuser")).thenReturn(loggedInUser);
    Mockito.when(restErrorUtil.create403RESTException("Logged-In user is not allowed to access requested user data.")).thenThrow(new WebApplicationException());
    thrown.expect(WebApplicationException.class);
    xUserMgr.getXUser(5L);
}
Also used : XXPortalUser(org.apache.ranger.entity.XXPortalUser) RangerSecurityContext(org.apache.ranger.security.context.RangerSecurityContext) WebApplicationException(javax.ws.rs.WebApplicationException) ArrayList(java.util.ArrayList) VXString(org.apache.ranger.view.VXString) VXUser(org.apache.ranger.view.VXUser) UserSessionBase(org.apache.ranger.common.UserSessionBase) Test(org.junit.Test)

Example 73 with XXPortalUser

use of org.apache.ranger.entity.XXPortalUser in project ranger by apache.

the class TestXUserMgr method test72UpdateXUser.

@Test
public void test72UpdateXUser() {
    destroySession();
    setup();
    Collection<String> existingRoleList = new ArrayList<String>();
    existingRoleList.add(RangerConstants.ROLE_USER);
    Collection<String> reqRoleList = new ArrayList<String>();
    reqRoleList.add(RangerConstants.ROLE_SYS_ADMIN);
    Collection<Long> groupIdList = new ArrayList<Long>();
    groupIdList.add(userId);
    VXUser vxUser = vxUser();
    vxUser.setUserRoleList(reqRoleList);
    vxUser.setUserSource(RangerCommonEnums.USER_EXTERNAL);
    vxUser.setGroupIdList(groupIdList);
    vxUser.setFirstName("null");
    vxUser.setLastName("null");
    vxUser.setPassword("*****");
    Mockito.when(xUserService.updateResource(vxUser)).thenReturn(vxUser);
    VXPortalUser oldUserProfile = userProfile();
    oldUserProfile.setUserSource(RangerCommonEnums.USER_APP);
    oldUserProfile.setPassword(vxUser.getPassword());
    VXPortalUser vXPortalUser = userProfile();
    vXPortalUser.setUserRoleList(existingRoleList);
    Mockito.when(userMgr.getUserProfileByLoginId(vxUser.getName())).thenReturn(oldUserProfile);
    XXPortalUser xXPortalUser = xxPortalUser(vXPortalUser);
    Mockito.when(userMgr.updateUserWithPass((VXPortalUser) Mockito.any())).thenReturn(xXPortalUser);
    List<XXUserPermission> xUserPermissionsList = new ArrayList<XXUserPermission>();
    XXUserPermission xUserPermissionObj = new XXUserPermission();
    xUserPermissionObj.setAddedByUserId(userId);
    xUserPermissionObj.setCreateTime(new Date());
    xUserPermissionObj.setId(userId);
    xUserPermissionObj.setIsAllowed(1);
    xUserPermissionObj.setModuleId(1L);
    xUserPermissionObj.setUpdatedByUserId(userId);
    xUserPermissionObj.setUpdateTime(new Date());
    xUserPermissionObj.setUserId(userId);
    xUserPermissionsList.add(xUserPermissionObj);
    VXGroupUserList vxGroupUserList = vxGroupUserList();
    Mockito.when(xGroupUserService.searchXGroupUsers((SearchCriteria) Mockito.any())).thenReturn(vxGroupUserList);
    UserSessionBase userSession = Mockito.mock(UserSessionBase.class);
    Set<UserSessionBase> userSessions = new HashSet<UserSessionBase>();
    userSessions.add(userSession);
    VXUser dbvxUser = xUserMgr.updateXUser(vxUser);
    Assert.assertNotNull(dbvxUser);
    Assert.assertEquals(dbvxUser.getId(), vxUser.getId());
    Assert.assertEquals(dbvxUser.getDescription(), vxUser.getDescription());
    Assert.assertEquals(dbvxUser.getName(), vxUser.getName());
    Mockito.verify(xUserService).updateResource(vxUser);
    groupIdList.clear();
    groupIdList.add(9L);
    vxUser.setGroupIdList(groupIdList);
    List<XXTrxLog> trxLogList = new ArrayList<XXTrxLog>();
    Mockito.when(xGroupUserService.getTransactionLog((VXGroupUser) Mockito.any(), Mockito.anyString())).thenReturn(trxLogList);
    vxUser.setPassword("TestUser@1234");
    oldUserProfile.setPassword(vxUser.getPassword());
    vxGroupUserList.setVXGroupUsers(null);
    Mockito.when(xGroupUserService.searchXGroupUsers((SearchCriteria) Mockito.any())).thenReturn(vxGroupUserList);
    VXGroup vXGroup = vxGroup();
    Mockito.when(xGroupService.readResource(Mockito.anyLong())).thenReturn(vXGroup);
    VXGroupUser vXGroupUser = vxGroupUser();
    Mockito.when(xGroupUserService.createResource((VXGroupUser) Mockito.any())).thenReturn(vXGroupUser);
    dbvxUser = xUserMgr.updateXUser(vxUser);
    Assert.assertNotNull(dbvxUser);
    Mockito.when(userMgr.getUserProfileByLoginId(Mockito.anyString())).thenReturn(null);
    Mockito.when(restErrorUtil.createRESTException("user " + vxUser.getName() + " does not exist.", MessageEnums.INVALID_INPUT_DATA)).thenThrow(new WebApplicationException());
    thrown.expect(WebApplicationException.class);
    vxUser = xUserMgr.updateXUser(vxUser);
    Assert.assertNull(vxUser);
}
Also used : VXGroupUserList(org.apache.ranger.view.VXGroupUserList) WebApplicationException(javax.ws.rs.WebApplicationException) ArrayList(java.util.ArrayList) VXGroupUser(org.apache.ranger.view.VXGroupUser) VXString(org.apache.ranger.view.VXString) XXTrxLog(org.apache.ranger.entity.XXTrxLog) VXUser(org.apache.ranger.view.VXUser) XXUserPermission(org.apache.ranger.entity.XXUserPermission) Date(java.util.Date) UserSessionBase(org.apache.ranger.common.UserSessionBase) XXPortalUser(org.apache.ranger.entity.XXPortalUser) VXLong(org.apache.ranger.view.VXLong) VXPortalUser(org.apache.ranger.view.VXPortalUser) VXGroup(org.apache.ranger.view.VXGroup) HashSet(java.util.HashSet) Test(org.junit.Test)

Example 74 with XXPortalUser

use of org.apache.ranger.entity.XXPortalUser in project ranger by apache.

the class TestXUserMgr method test113CreateOrUpdateXUsers.

@Test
public void test113CreateOrUpdateXUsers() {
    destroySession();
    setup();
    VXUser vXUser = vxUser();
    vXUser.setFirstName("null");
    vXUser.setLastName("null");
    List<VXUser> vXUserList = new ArrayList<VXUser>();
    vXUserList.add(vXUser);
    VXUserList users = new VXUserList(vXUserList);
    XXUserDao xxUserDao = Mockito.mock(XXUserDao.class);
    XXModuleDefDao xXModuleDefDao = Mockito.mock(XXModuleDefDao.class);
    XXGlobalStateDao xxGlobalStateDao = Mockito.mock(XXGlobalStateDao.class);
    XXUser xXUser = xxUser(vXUser);
    VXPortalUser vXPortalUser = userProfile();
    vXPortalUser.setFirstName("null");
    vXPortalUser.setLastName("null");
    XXPortalUser xXPortalUser = xxPortalUser(vXPortalUser);
    xXPortalUser.setUserSource(RangerCommonEnums.USER_EXTERNAL);
    List<String> lstRole = new ArrayList<String>();
    lstRole.add(RangerConstants.ROLE_SYS_ADMIN);
    List<XXModuleDef> xXModuleDefs = new ArrayList<XXModuleDef>();
    vXPortalUser.setUserRoleList(lstRole);
    Mockito.when(userMgr.getUserProfileByLoginId(vXUser.getName())).thenReturn(vXPortalUser);
    Mockito.when(daoManager.getXXUser()).thenReturn(xxUserDao);
    Mockito.when(xxUserDao.findByUserName(vXUser.getName())).thenReturn(xXUser);
    Mockito.when(daoManager.getXXModuleDef()).thenReturn(xXModuleDefDao);
    Mockito.when(daoManager.getXXGlobalState()).thenReturn(xxGlobalStateDao);
    Mockito.when(xXModuleDefDao.getAll()).thenReturn(xXModuleDefs);
    Mockito.when(xUserService.updateResource(vXUser)).thenReturn(vXUser);
    XXUserPermissionDao xUserPermissionDao = Mockito.mock(XXUserPermissionDao.class);
    Mockito.when(daoManager.getXXUserPermission()).thenReturn(xUserPermissionDao);
    List<XXUserPermission> xUserPermissionsList = new ArrayList<XXUserPermission>();
    XXUserPermission xUserPermissionObj = new XXUserPermission();
    xUserPermissionObj.setAddedByUserId(userId);
    xUserPermissionObj.setCreateTime(new Date());
    xUserPermissionObj.setId(userId);
    xUserPermissionObj.setIsAllowed(1);
    xUserPermissionObj.setModuleId(1L);
    xUserPermissionObj.setUpdatedByUserId(userId);
    xUserPermissionObj.setUpdateTime(new Date());
    xUserPermissionObj.setUserId(userId);
    xUserPermissionsList.add(xUserPermissionObj);
    Mockito.when(xUserPermissionDao.findByUserPermissionId(vXPortalUser.getId())).thenReturn(xUserPermissionsList);
    xUserMgr.createOrUpdateXUsers(users);
    vXUserList.clear();
    vXUser.setUserSource(RangerCommonEnums.USER_APP);
    vXUser.setFirstName("testuser");
    vXUser.setLastName("testuser");
    vXUser.setPassword("TestPassword@123");
    vXUserList.add(vXUser);
    users = new VXUserList(vXUserList);
    vXPortalUser = userProfile();
    vXPortalUser.setUserSource(RangerCommonEnums.USER_APP);
    vXPortalUser.setFirstName("testuser");
    vXPortalUser.setLastName("testuser");
    vXPortalUser.setPassword("TestPassword@123");
    vXPortalUser.setUserRoleList(lstRole);
    Mockito.when(userMgr.getUserProfileByLoginId(vXUser.getName())).thenReturn(vXPortalUser);
    Mockito.when(userMgr.updateUserWithPass((VXPortalUser) Mockito.any())).thenReturn(xXPortalUser);
    xUserMgr.createOrUpdateXUsers(users);
    vXUser.setPassword("*****");
    xUserMgr.createOrUpdateXUsers(users);
}
Also used : XXUser(org.apache.ranger.entity.XXUser) XXUserDao(org.apache.ranger.db.XXUserDao) XXUserPermissionDao(org.apache.ranger.db.XXUserPermissionDao) ArrayList(java.util.ArrayList) XXGlobalStateDao(org.apache.ranger.db.XXGlobalStateDao) XXModuleDefDao(org.apache.ranger.db.XXModuleDefDao) VXString(org.apache.ranger.view.VXString) VXUser(org.apache.ranger.view.VXUser) XXUserPermission(org.apache.ranger.entity.XXUserPermission) VXUserList(org.apache.ranger.view.VXUserList) Date(java.util.Date) XXPortalUser(org.apache.ranger.entity.XXPortalUser) XXModuleDef(org.apache.ranger.entity.XXModuleDef) VXPortalUser(org.apache.ranger.view.VXPortalUser) Test(org.junit.Test)

Example 75 with XXPortalUser

use of org.apache.ranger.entity.XXPortalUser in project ranger by apache.

the class TestXUserMgr method test98modifyUserActiveStatus.

@Test
public void test98modifyUserActiveStatus() {
    VXUser vxUser = vxUser();
    XXUser xXUser = xxUser(vxUser);
    HashMap<Long, Integer> statusMap = new HashMap<Long, Integer>();
    statusMap.put(xXUser.getId(), 1);
    RangerSecurityContext context = new RangerSecurityContext();
    context.setUserSession(new UserSessionBase());
    RangerContextHolder.setSecurityContext(context);
    UserSessionBase currentUserSession = ContextUtil.getCurrentUserSession();
    currentUserSession.setUserAdmin(true);
    XXPortalUser xXPortalUser = new XXPortalUser();
    xXPortalUser.setLoginId(null);
    xXPortalUser.setId(userId);
    currentUserSession.setXXPortalUser(xXPortalUser);
    xUserMgr.modifyUserActiveStatus(statusMap);
}
Also used : XXUser(org.apache.ranger.entity.XXUser) XXPortalUser(org.apache.ranger.entity.XXPortalUser) RangerSecurityContext(org.apache.ranger.security.context.RangerSecurityContext) HashMap(java.util.HashMap) VXLong(org.apache.ranger.view.VXLong) VXUser(org.apache.ranger.view.VXUser) UserSessionBase(org.apache.ranger.common.UserSessionBase) Test(org.junit.Test)

Aggregations

XXPortalUser (org.apache.ranger.entity.XXPortalUser)192 Test (org.junit.Test)113 ArrayList (java.util.ArrayList)93 VXPortalUser (org.apache.ranger.view.VXPortalUser)86 VXString (org.apache.ranger.view.VXString)82 XXPortalUserDao (org.apache.ranger.db.XXPortalUserDao)74 XXPortalUserRole (org.apache.ranger.entity.XXPortalUserRole)46 XXPortalUserRoleDao (org.apache.ranger.db.XXPortalUserRoleDao)44 XXUserPermission (org.apache.ranger.entity.XXUserPermission)36 UserSessionBase (org.apache.ranger.common.UserSessionBase)34 VXUser (org.apache.ranger.view.VXUser)34 WebApplicationException (javax.ws.rs.WebApplicationException)33 Date (java.util.Date)30 RangerSecurityContext (org.apache.ranger.security.context.RangerSecurityContext)29 XXUser (org.apache.ranger.entity.XXUser)27 XXUserPermissionDao (org.apache.ranger.db.XXUserPermissionDao)25 XXModuleDef (org.apache.ranger.entity.XXModuleDef)25 XXModuleDefDao (org.apache.ranger.db.XXModuleDefDao)20 XXGroupPermission (org.apache.ranger.entity.XXGroupPermission)19 VXUserPermission (org.apache.ranger.view.VXUserPermission)19