Class AclRule

java.lang.Object
io.inversion.Rule<AclRule>
io.inversion.action.security.AclRule
All Implemented Interfaces:
Comparable<AclRule>

public class AclRule extends Rule<AclRule>
  • Field Details

    • permissions

      protected final ArrayList<String> permissions
    • roles

      protected final ArrayList<String> roles
    • scopes

      protected final ArrayList<String> scopes
    • allow

      protected boolean allow
    • info

      protected boolean info
    • allRolesMustMatch

      protected boolean allRolesMustMatch
    • allPermissionsMustMatch

      protected boolean allPermissionsMustMatch
    • allScopesMustMatch

      protected boolean allScopesMustMatch
  • Constructor Details

    • AclRule

      public AclRule()
  • Method Details

    • allowAll

      public static AclRule allowAll(String includedOn)
    • requireAllPerms

      public static AclRule requireAllPerms(String permissions, String... includedOn)
    • requireOnePerm

      public static AclRule requireOnePerm(String permissions, String... includedOn)
    • requireAllRoles

      public static AclRule requireAllRoles(String roles, String... includedOn)
    • requireOneRole

      public static AclRule requireOneRole(String roles, String... includedOn)
    • requireAllScopes

      public static AclRule requireAllScopes(String scopes, String... includedOn)
    • requireOneScope

      public static AclRule requireOneScope(String scopes, String... includedOn)
    • ruleMatches

      public boolean ruleMatches(Request req)
    • getRoles

      public ArrayList<String> getRoles()
    • withRoles

      public AclRule withRoles(String... roles)
    • getPermissions

      public ArrayList<String> getPermissions()
    • withPermissions

      public AclRule withPermissions(String... permissions)
    • getScopes

      public ArrayList<String> getScopes()
    • withScopes

      public AclRule withScopes(String... scopes)
    • isAllow

      public boolean isAllow()
    • withAllow

      public AclRule withAllow(boolean allow)
    • isInfo

      public boolean isInfo()
    • withInfo

      public AclRule withInfo(boolean info)
    • isAllRolesMustMatch

      public boolean isAllRolesMustMatch()
    • withAllRolesMustMatch

      public AclRule withAllRolesMustMatch(boolean allRolesMustMatch)
    • isAllPermissionsMustMatch

      public boolean isAllPermissionsMustMatch()
    • withAllPermissionsMustMatch

      public AclRule withAllPermissionsMustMatch(boolean allPermissionsMustMatch)
    • isAllScopesMustMatch

      public boolean isAllScopesMustMatch()
    • withAllScopesMustMatch

      public AclRule withAllScopesMustMatch(boolean allScopesMustMatch)