Class WidgetPolicyProcessor

All Implemented Interfaces:

@Component public class WidgetPolicyProcessor extends Object implements PolicyProcessor
Adds access permissions for widget entities: - read permission for all (including anonymous) - create, write and delete permissions for role "redactor" The rules are added at login phase.
  • Field Details


      public static final Subject REDACTOR_ROLE
  • Constructor Details

    • WidgetPolicyProcessor

      public WidgetPolicyProcessor(WidgetModelService widgetModelService)
  • Method Details

    • processPolicy

      public void processPolicy(PolicyBuilder policy, Object target) throws Exception
      Description copied from interface: PolicyProcessor
      Post-process the given policy. On phase `LOGIN`, the `target` is the principal being logged in, on phase `GUARD`, it's the object being guarded. On phase `LOGIN` the `policy` is the entire policy containing all rules that affect the current user, on phase `GUARD` the policy only contains the rules that are relevant to the guarded objects (the entire policy, if needed, can be retrieved from the SecurityContext).
      Specified by:
      processPolicy in interface PolicyProcessor