Class ProcessRestPermissionEvaluatorPlugin

java.lang.Object
org.dspace.app.rest.security.RestObjectPermissionEvaluatorPlugin
org.dspace.app.rest.security.ProcessRestPermissionEvaluatorPlugin
All Implemented Interfaces:
RestPermissionEvaluatorPlugin

@Component public class ProcessRestPermissionEvaluatorPlugin extends RestObjectPermissionEvaluatorPlugin
This class will handle calls made to Process endpoints. It will return false if the current user is null or if the current user is not the eperson that's attached to the process and that user isn't an admin. This class is an implementation for RestObjectPermissionEvaluatorPlugin for Process endpoints.
  • Constructor Details

    • ProcessRestPermissionEvaluatorPlugin

      public ProcessRestPermissionEvaluatorPlugin()
  • Method Details

    • hasDSpacePermission

      public boolean hasDSpacePermission(Authentication authentication, Serializable targetId, String targetType, DSpaceRestPermission restPermission)
      Description copied from class: RestObjectPermissionEvaluatorPlugin
      Plugins must implement this method to receive RestPermissionEvaluatorPlugin hasPermission requests.
      Specified by:
      hasDSpacePermission in class RestObjectPermissionEvaluatorPlugin
      Parameters:
      authentication - Authentication object providing user details of the authenticated user
      targetId - Unique identifier of the target object the user wants to view or manipulate
      targetType - Type of the target object the users wants to view or manipulate
      restPermission - Permission object that describes the action the user wants to perform on the target object
      Returns:
      true if the user is allowed to perform the action described by the permission. False otherwise.