Package org.dspace.app.rest.security
Interface RestPermissionEvaluatorPlugin
-
- All Known Implementing Classes:
AdminRestPermissionEvaluatorPlugin,AuthorizeServicePermissionEvaluatorPlugin,BitstreamMetadataReadPermissionEvaluatorPlugin,ClaimedTaskRestPermissionEvaluatorPlugin,DSpaceObjectAdminPermissionEvaluatorPlugin,EPersonRestPermissionEvaluatorPlugin,GroupRestPermissionEvaluatorPlugin,PoolTaskRestPermissionEvaluatorPlugin,ProcessRestPermissionEvaluatorPlugin,ReadAuthorizationPermissionEvaluatorPlugin,ResourcePolicyAdminPermissionEvalutatorPlugin,ResourcePolicyRestPermissionEvaluatorPlugin,RestObjectPermissionEvaluatorPlugin,SubmissionCCLicenseRestEvaluatorPlugin,SubmissionCCLicenseUrlRestPermissionEvaluatorPlugin,UsageReportRestPermissionEvaluatorPlugin,VersionHistoryRestPermissionEvaluatorPlugin,VersionRestPermissionEvaluatorPlugin,WorkflowRestPermissionEvaluatorPlugin,WorkspaceItemRestPermissionEvaluatorPlugin
public interface RestPermissionEvaluatorPluginInterface to define a permission evaluator plugin. These plugins are used in the DSpacePermissionEvaluatorimplementationDSpacePermissionEvaluatorto check if an authenticated user has permission to perform a certain action on a certain object. If you implement a this interface in a Spring bean, it will be automatically taken into account when evaluating permissions.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanhasPermission(org.springframework.security.core.Authentication authentication, Serializable targetId, String targetType, Object permission)Check in the authenticated user (provided by theAuthenticationobject) has the specified permission on the target object with the provided identifier.booleanhasPermission(org.springframework.security.core.Authentication authentication, Object targetDomainObject, Object permission)Check in the authenticated user (provided by theAuthenticationobject) has the specified permission on the provided target object.
-
-
-
Method Detail
-
hasPermission
boolean hasPermission(org.springframework.security.core.Authentication authentication, Object targetDomainObject, Object permission)Check in the authenticated user (provided by theAuthenticationobject) has the specified permission on the provided target object.- Parameters:
authentication- Authentication object providing user details of the authenticated usertargetDomainObject- The target object that the authenticated user wants to see or manipulatepermission- 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.
-
hasPermission
boolean hasPermission(org.springframework.security.core.Authentication authentication, Serializable targetId, String targetType, Object permission)Check in the authenticated user (provided by theAuthenticationobject) has the specified permission on the target object with the provided identifier.- Parameters:
authentication- Authentication object providing user details of the authenticated usertargetId- Unique identifier of the target object the user wants to view or manipulatetargetType- Type of the target object the users wants to view or manipulatepermission- 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.
-
-