Class PermissionSecurityChecks.PermissionSecurityChecksBuilder

java.lang.Object
io.quarkus.security.deployment.PermissionSecurityChecks.PermissionSecurityChecksBuilder
Enclosing interface:
PermissionSecurityChecks

public static final class PermissionSecurityChecks.PermissionSecurityChecksBuilder extends Object
  • Constructor Details

    • PermissionSecurityChecksBuilder

      public PermissionSecurityChecksBuilder(SecurityCheckRecorder recorder, io.quarkus.deployment.annotations.BuildProducer<io.quarkus.deployment.builditem.GeneratedClassBuildItem> generatedClassesProducer, io.quarkus.deployment.annotations.BuildProducer<io.quarkus.deployment.builditem.nativeimage.ReflectiveClassBuildItem> reflectiveClassesProducer, org.jboss.jandex.IndexView index)
  • Method Details

    • build

    • createPermissionPredicates

      Creates predicate for each secured method. Predicates are cached if possible. What we call predicate here is combination of (possibly computed) Permissions joined with logical operators 'AND' or 'OR'. For example, combination of following 2 annotation instances:
       @PermissionsAllowed({"createResource", "createAll"})
       @PermissionsAllowed({"updateResource", "updateAll"})
       public void createOrUpdate() {
            ...
       }
       
      leads to (pseudocode): (createResource OR createAll) AND (updateResource OR updateAll)
      Returns:
      PermissionSecurityChecksBuilder
    • validatePermissionClasses

      PermissionSecurityChecks.PermissionSecurityChecksBuilder validatePermissionClasses(org.jboss.jandex.IndexView index)
    • gatherPermissionsAllowedAnnotations

      PermissionSecurityChecks.PermissionSecurityChecksBuilder gatherPermissionsAllowedAnnotations(List<org.jboss.jandex.AnnotationInstance> instances, Map<org.jboss.jandex.MethodInfo,org.jboss.jandex.AnnotationInstance> alreadyCheckedMethods, Map<org.jboss.jandex.ClassInfo,org.jboss.jandex.AnnotationInstance> alreadyCheckedClasses, List<org.jboss.jandex.AnnotationInstance> additionalClassInstances, Predicate<org.jboss.jandex.MethodInfo> hasAdditionalSecurityAnnotations)
    • isPermissionsAllowedInterceptor

      static boolean isPermissionsAllowedInterceptor(org.jboss.jandex.ClassInfo clazz)
    • getPermissionsAllowedInstances

      static ArrayList<org.jboss.jandex.AnnotationInstance> getPermissionsAllowedInstances(org.jboss.jandex.IndexView index, PermissionsAllowedMetaAnnotationBuildItem item)
    • getPermissionsAllowedInstances

      static ArrayList<org.jboss.jandex.AnnotationInstance> getPermissionsAllowedInstances(org.jboss.jandex.IndexView index)
    • movePermFromMetaAnnToMetaTarget

      static PermissionsAllowedMetaAnnotationBuildItem movePermFromMetaAnnToMetaTarget(org.jboss.jandex.IndexView index)