コード例 #1
0
 @PUT
 @Path("/permission/group/{id}")
 @Produces({"application/xml", "application/json"})
 @PreAuthorize(
     "@rangerPreAuthSecurityHandler.isAPIAccessible(\""
         + RangerAPIList.UPDATE_X_GROUP_PERMISSION
         + "\")")
 public VXGroupPermission updateXGroupPermission(VXGroupPermission vXGroupPermission) {
   xUserMgr.checkAdminAccess();
   return xUserMgr.updateXGroupPermission(vXGroupPermission);
 }
コード例 #2
0
 // Handle user permissions
 @POST
 @Path("/permission/user")
 @Produces({"application/xml", "application/json"})
 @PreAuthorize(
     "@rangerPreAuthSecurityHandler.isAPIAccessible(\""
         + RangerAPIList.CREATE_X_USER_PERMISSION
         + "\")")
 public VXUserPermission createXUserPermission(VXUserPermission vXUserPermission) {
   xUserMgr.checkAdminAccess();
   return xUserMgr.createXUserPermission(vXUserPermission);
 }
コード例 #3
0
 @DELETE
 @Path("/permission/user/{id}")
 @PreAuthorize(
     "@rangerPreAuthSecurityHandler.isAPIAccessible(\""
         + RangerAPIList.DELETE_X_USER_PERMISSION
         + "\")")
 public void deleteXUserPermission(@PathParam("id") Long id, @Context HttpServletRequest request) {
   boolean force = true;
   xUserMgr.checkAdminAccess();
   xUserMgr.deleteXUserPermission(id, force);
 }
コード例 #4
0
 @PUT
 @Path("/permission/{id}")
 @Produces({"application/xml", "application/json"})
 @PreAuthorize(
     "@rangerPreAuthSecurityHandler.isAPIAccessible(\""
         + RangerAPIList.UPDATE_X_MODULE_DEF_PERMISSION
         + "\")")
 public VXModuleDef updateXModuleDefPermission(VXModuleDef vXModuleDef) {
   xUserMgr.checkAdminAccess();
   return xUserMgr.updateXModuleDefPermission(vXModuleDef);
 }