package com.l7tech.policy.assertion;

import com.l7tech.common.io.ClassLoaderObjectInputStream;
import com.l7tech.objectmodel.ExternalEntityHeader;
import com.l7tech.objectmodel.migration.Migration;
import com.l7tech.objectmodel.migration.MigrationMappingSelection;
import com.l7tech.objectmodel.migration.PropertyResolver;
import com.l7tech.policy.assertion.ext.Category;
import com.l7tech.policy.assertion.ext.CustomAssertion;
import com.l7tech.policy.assertion.ext.targetable.CustomMessageTargetable;
import com.l7tech.policy.assertion.ext.validator.CustomPolicyValidator;
import com.l7tech.policy.variable.VariableMetadata;
import com.l7tech.util.DeserializeSafe;
import com.l7tech.util.ExceptionUtils;
import com.l7tech.util.ResourceUtils;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.util.HashSet;
import java.util.Set;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

@DeserializeSafe
public class CustomAssertionHolder extends Assertion implements UsesVariables, SetsVariables, MessageTargetable {
   private static final long serialVersionUID = 7410439507802944818L;
   private static final Logger logger;
   private static final String META_INITIALIZED;
   public static final String CUSTOM_ASSERTION;
   public static final String EXTERNAL_NAME;
   public static final String EXTERNAL_NAME_PREFIX;
   private CustomAssertion customAssertion;
   private Category category;
   private String descriptionText;
   private String paletteNodeName;
   private String policyNodeName;
   private boolean isUiAutoOpen;
   private String customModuleFileName;
   private String registeredCustomFeatureSetName;
   private Set<Category> categories;
   private static final String[] b;

   public CustomAssertionHolder() {
      this.parent = null;
   }

   private void readObject(ObjectInputStream param1) throws ClassNotFoundException, IOException {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 1
      // 01: invokevirtual java/io/ObjectInputStream.defaultReadObject ()V
      // 04: aload 0
      // 05: getfield com/l7tech/policy/assertion/CustomAssertionHolder.categories Ljava/util/Set;
      // 08: ifnonnull 32
      // 0b: aload 0
      // 0c: bipush 1
      // 0d: anewarray 483
      // 10: dup
      // 11: bipush 0
      // 12: aload 0
      // 13: getfield com/l7tech/policy/assertion/CustomAssertionHolder.category Lcom/l7tech/policy/assertion/ext/Category;
      // 16: ifnull 2b
      // 19: goto 20
      // 1c: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 1f: athrow
      // 20: aload 0
      // 21: getfield com/l7tech/policy/assertion/CustomAssertionHolder.category Lcom/l7tech/policy/assertion/ext/Category;
      // 24: goto 2e
      // 27: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 2a: athrow
      // 2b: getstatic com/l7tech/policy/assertion/ext/Category.UNFILLED Lcom/l7tech/policy/assertion/ext/Category;
      // 2e: aastore
      // 2f: invokevirtual com/l7tech/policy/assertion/CustomAssertionHolder.setCategories ([Lcom/l7tech/policy/assertion/ext/Category;)V
      // 32: return
      // try (0 -> 13): 14 java/lang/ClassNotFoundException
      // try (5 -> 19): 19 java/lang/ClassNotFoundException
   }

   public CustomAssertion getCustomAssertion() {
      return this.customAssertion;
   }

   public Set<Category> getCategories() {
      return this.categories;
   }

   public void setCategories(@NotNull Set<Category> var1) {
      try {
         if (var1 == null) {
            $$$reportNull$$$0(0);
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }

      this.categories = new HashSet<>(var1);
   }

   public void setCategories(@NotNull Category... var1) {
      try {
         if (var1 == null) {
            $$$reportNull$$$0(1);
         }
      } catch (SecurityException var8) {
         throw a(var8);
      }

      this.categories = new HashSet<>();

      for (Category var5 : var1) {
         try {
            if (var5 != null) {
               this.categories.add(var5);
            }
         } catch (SecurityException var7) {
            throw a(var7);
         }
      }

      try {
         if (this.categories.isEmpty()) {
            this.categories.add(Category.UNFILLED);
         }
      } catch (SecurityException var6) {
         throw a(var6);
      }
   }

   public boolean isCustomCredentialSource() {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 0
      // 01: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 04: ifnull 2e
      // 07: aload 0
      // 08: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 0b: instanceof com/l7tech/policy/assertion/ext/CustomCredentialSource
      // 0e: ifeq 2e
      // 11: goto 18
      // 14: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 17: athrow
      // 18: aload 0
      // 19: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 1c: checkcast com/l7tech/policy/assertion/ext/CustomCredentialSource
      // 1f: invokeinterface com/l7tech/policy/assertion/ext/CustomCredentialSource.isCredentialSource ()Z 1
      // 24: ifne 52
      // 27: goto 2e
      // 2a: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 2d: athrow
      // 2e: aload 0
      // 2f: getfield com/l7tech/policy/assertion/CustomAssertionHolder.categories Ljava/util/Set;
      // 32: ifnull 5a
      // 35: goto 3c
      // 38: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 3b: athrow
      // 3c: aload 0
      // 3d: getfield com/l7tech/policy/assertion/CustomAssertionHolder.categories Ljava/util/Set;
      // 40: getstatic com/l7tech/policy/assertion/ext/Category.ACCESS_CONTROL Lcom/l7tech/policy/assertion/ext/Category;
      // 43: invokeinterface java/util/Set.contains (Ljava/lang/Object;)Z 2
      // 48: ifeq 5a
      // 4b: goto 52
      // 4e: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 51: athrow
      // 52: bipush 1
      // 53: goto 5b
      // 56: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 59: athrow
      // 5a: bipush 0
      // 5b: ireturn
      // try (0 -> 7): 8 java/lang/SecurityException
      // try (3 -> 15): 16 java/lang/SecurityException
      // try (10 -> 21): 22 java/lang/SecurityException
      // try (18 -> 29): 30 java/lang/SecurityException
      // try (24 -> 34): 34 java/lang/SecurityException
   }

   public void setCustomAssertion(CustomAssertion var1) {
      this.customAssertion = var1;
   }

   @Override
   public String toString() {
      try {
         if (this.customAssertion == null) {
            return b[11];
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }

      String var10000 = this.customAssertion.toString();
      String var10001 = friendlyPrintCategories(this.categories);
      String[] var1 = b;
      return var1[38] + var10000 + var1[34] + var10001 + var1[26];
   }

   public static boolean isCustomAssertionExternalName(String var0) {
      return var0.startsWith(b[15]);
   }

   public static String getLocalExternalName(String var0) {
      try {
         if (var0.startsWith(b[23])) {
            return var0.substring(b[15].length());
         }
      } catch (SecurityException var1) {
         throw a(var1);
      }

      return var0;
   }

   public static String getExternalNameFrom(String var0) {
      return b[15] + var0;
   }

   public static String friendlyPrintCategories(Set<Category> var0) {
      try {
         if (var0 == null) {
            return b[21];
         }
      } catch (SecurityException var8) {
         throw a(var8);
      }

      int var1 = var0.size() - 1;

      try {
         if (var1 < 0) {
            return b[35];
         }
      } catch (SecurityException var7) {
         throw a(var7);
      }

      int var2 = 0;
      StringBuilder var3 = new StringBuilder();
      var3.append('[');

      for (Category var5 : var0) {
         try {
            var3.append(String.valueOf(var5));
            if (var1 > var2++) {
               var3.append(b[36]);
            }
         } catch (SecurityException var6) {
            throw a(var6);
         }
      }

      return var3.append(']').toString();
   }

   @Nullable
   public String getModuleFileName() {
      return this.customModuleFileName;
   }

   public void setModuleFileName(@Nullable String var1) {
      this.customModuleFileName = var1;
   }

   public String getDescriptionText() {
      return this.descriptionText;
   }

   public void setDescriptionText(String var1) {
      this.descriptionText = var1;
   }

   public String getPaletteNodeName() {
      return this.paletteNodeName;
   }

   public void setPaletteNodeName(String var1) {
      this.paletteNodeName = var1;
   }

   public String getPolicyNodeName() {
      return this.policyNodeName;
   }

   public void setPolicyNodeName(String var1) {
      this.policyNodeName = var1;
   }

   public boolean getIsUiAutoOpen() {
      return this.isUiAutoOpen;
   }

   public void setIsUiAutoOpen(boolean var1) {
      this.isUiAutoOpen = var1;
   }

   @Nullable
   public String getRegisteredCustomFeatureSetName() {
      return this.registeredCustomFeatureSetName;
   }

   public void setRegisteredCustomFeatureSetName(@Nullable String var1) {
      this.registeredCustomFeatureSetName = var1;
   }

   @Migration(
      mapName = MigrationMappingSelection.NONE,
      mapValue = MigrationMappingSelection.REQUIRED,
      export = false,
      valueType = ExternalEntityHeader.ValueType.TEXT_ARRAY,
      resolver = PropertyResolver.Type.SERVER_VARIABLE
   )
   @Override
   public String[] getVariablesUsed() {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 0
      // 01: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 04: ifnull 18
      // 07: aload 0
      // 08: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 0b: instanceof com/l7tech/policy/assertion/UsesVariables
      // 0e: ifne 21
      // 11: goto 18
      // 14: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 17: athrow
      // 18: bipush 0
      // 19: anewarray 451
      // 1c: areturn
      // 1d: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 20: athrow
      // 21: aload 0
      // 22: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 25: checkcast com/l7tech/policy/assertion/UsesVariables
      // 28: astore 1
      // 29: aload 1
      // 2a: invokeinterface com/l7tech/policy/assertion/UsesVariables.getVariablesUsed ()[Ljava/lang/String; 1
      // 2f: areturn
      // try (0 -> 7): 8 java/lang/SecurityException
      // try (3 -> 13): 13 java/lang/SecurityException
   }

   @Override
   public VariableMetadata[] getVariablesSet() {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 0
      // 01: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 04: ifnull 18
      // 07: aload 0
      // 08: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 0b: instanceof com/l7tech/policy/assertion/SetsVariables
      // 0e: ifne 21
      // 11: goto 18
      // 14: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 17: athrow
      // 18: bipush 0
      // 19: anewarray 416
      // 1c: areturn
      // 1d: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 20: athrow
      // 21: aload 0
      // 22: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 25: checkcast com/l7tech/policy/assertion/SetsVariables
      // 28: astore 1
      // 29: aload 1
      // 2a: invokeinterface com/l7tech/policy/assertion/SetsVariables.getVariablesSet ()[Lcom/l7tech/policy/variable/VariableMetadata; 1
      // 2f: areturn
      // try (0 -> 7): 8 java/lang/SecurityException
      // try (3 -> 13): 13 java/lang/SecurityException
   }

   @Override
   public Object clone() {
      CustomAssertionHolder var1 = (CustomAssertionHolder)super.clone();

      CustomAssertionHolder var10000;
      HashSet var10001;
      label68: {
         try {
            var1.category = this.category;
            var1.descriptionText = this.descriptionText;
            var1.customAssertion = this.customAssertion;
            var1.paletteNodeName = this.paletteNodeName;
            var1.policyNodeName = this.policyNodeName;
            var1.isUiAutoOpen = this.isUiAutoOpen;
            var1.customModuleFileName = this.customModuleFileName;
            var10000 = var1;
            if (this.categories != null) {
               var10001 = new HashSet<>(this.categories);
               break label68;
            }
         } catch (IOException var16) {
            throw a(var16);
         }

         var10001 = null;
      }

      var10000.categories = var10001;
      if (this.customAssertion != null) {
         ClassLoaderObjectInputStream var2 = null;
         ObjectOutputStream var3 = null;

         try {
            ByteArrayOutputStream var4 = new ByteArrayOutputStream();
            var3 = new ObjectOutputStream(var4);
            var3.writeObject(this.customAssertion);
            var3.flush();
            var2 = new ClassLoaderObjectInputStream(new ByteArrayInputStream(var4.toByteArray()), this.customAssertion.getClass().getClassLoader());
            var1.customAssertion = (CustomAssertion)var2.readObject();
         } catch (IOException | ClassNotFoundException var12) {
            String[] var17 = b;
            logger.log(Level.FINE, var17[37], var12);
         } catch (SecurityException var13) {
            String[] var6 = b;
            logger.log(Level.FINE, var6[14]);
         } catch (RuntimeException var14) {
            logger.log(Level.FINE, b[22], var14);
         } finally {
            ResourceUtils.closeQuietly(var2);
            ResourceUtils.closeQuietly(var3);
         }
      }

      return var1;
   }

   @Override
   public AssertionMetadata meta() {
      DefaultAssertionMetadata var1 = this.defaultCustomMeta();

      try {
         if (Boolean.TRUE.equals(var1.get(META_INITIALIZED))) {
            return var1;
         }
      } catch (SecurityException var4) {
         throw a(var4);
      }

      DefaultAssertionMetadata var10000;
      String var10001;
      String var10002;
      label68: {
         try {
            var1.put(b[28], b[8]);
            var10000 = var1;
            var10001 = b[1];
            if (this.customAssertion == null) {
               var10002 = b[9];
               break label68;
            }
         } catch (SecurityException var8) {
            throw a(var8);
         }

         var10002 = this.customAssertion.getName();
      }

      label61: {
         try {
            var10000.put(var10001, var10002);
            var10000 = var1;
            var10001 = b[29];
            if (this.descriptionText == null) {
               var10002 = b[2];
               break label61;
            }
         } catch (SecurityException var7) {
            throw a(var7);
         }

         var10002 = this.descriptionText;
      }

      label54: {
         try {
            var10000.put(var10001, var10002);
            var1.put(b[13], new k(this));
            var1.put(b[39], b[0]);
            if (this.customAssertion instanceof CustomPolicyValidator) {
               var1.put(b[4], b[7]);
               break label54;
            }
         } catch (SecurityException var6) {
            throw a(var6);
         }

         String[] var2 = b;
         var1.put(var2[6], null);
      }

      label47: {
         try {
            if (this.getIsUiAutoOpen()) {
               var1.put(b[16], b[17]);
               break label47;
            }
         } catch (SecurityException var5) {
            throw a(var5);
         }

         String[] var9 = b;
         var1.put(var9[20], null);
         var1.put(var9[25], null);
      }

      try {
         if (this.customAssertion != null) {
            var1.put(META_INITIALIZED, Boolean.TRUE);
         }

         return var1;
      } catch (SecurityException var3) {
         throw a(var3);
      }
   }

   private DefaultAssertionMetadata defaultCustomMeta() {
      try {
         if (this.customAssertion == null) {
            return this.defaultMeta();
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }

      Class var1 = this.customAssertion.getClass();
      return this.getOrCreateMetaIfRequired(getExternalNameFrom(var1.getName()), var1x -> {
         CustomAssertionHolder var2x = new CustomAssertionHolder();

         try {
            var2x.setCustomAssertion((CustomAssertion)var1.newInstance());
         } catch (InstantiationException | IllegalAccessException var4) {
            logger.log(Level.INFO, b[31], new Object[]{var1x, ExceptionUtils.getMessageWithCause(var4)});
         }

         return new DefaultAssertionMetadata(var2x);
      });
   }

   private TargetMessageType convertToTargetMessageType(String var1) {
      try {
         if (var1 == null) {
            return TargetMessageType.OTHER;
         }
      } catch (SecurityException var4) {
         throw a(var4);
      }

      try {
         if (var1.compareToIgnoreCase(b[27]) == 0) {
            return TargetMessageType.REQUEST;
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }

      try {
         if (var1.compareToIgnoreCase(b[24]) == 0) {
            return TargetMessageType.RESPONSE;
         }
      } catch (SecurityException var3) {
         throw a(var3);
      }

      return TargetMessageType.OTHER;
   }

   private String convertToMessageVariableName(TargetMessageType var1) {
      try {
         if (var1 == TargetMessageType.REQUEST) {
            return b[19];
         }
      } catch (SecurityException var3) {
         throw a(var3);
      }

      try {
         return var1 == TargetMessageType.RESPONSE ? b[33] : "";
      } catch (SecurityException var2) {
         throw a(var2);
      }
   }

   @Override
   public TargetMessageType getTarget() {
      try {
         if (this.customAssertion instanceof CustomMessageTargetable) {
            return this.convertToTargetMessageType(((CustomMessageTargetable)this.customAssertion).getTargetMessageVariable());
         }
      } catch (SecurityException var1) {
         throw a(var1);
      }

      return TargetMessageType.REQUEST;
   }

   @Override
   public void setTarget(TargetMessageType var1) {
      try {
         if (this.customAssertion instanceof CustomMessageTargetable) {
            ((CustomMessageTargetable)this.customAssertion).setTargetMessageVariable(this.convertToMessageVariableName(var1));
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }
   }

   @Override
   public String getOtherTargetMessageVariable() {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 0
      // 01: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 04: instanceof com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable
      // 07: ifeq 4b
      // 0a: aload 0
      // 0b: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 0e: checkcast com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable
      // 11: invokeinterface com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable.getTargetMessageVariable ()Ljava/lang/String; 1
      // 16: astore 1
      // 17: aload 1
      // 18: ifnull 43
      // 1b: aload 1
      // 1c: getstatic com/l7tech/policy/assertion/CustomAssertionHolder.b [Ljava/lang/String;
      // 1f: bipush 19
      // 21: aaload
      // 22: invokevirtual java/lang/String.compareToIgnoreCase (Ljava/lang/String;)I
      // 25: ifeq 43
      // 28: goto 2f
      // 2b: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 2e: athrow
      // 2f: aload 1
      // 30: getstatic com/l7tech/policy/assertion/CustomAssertionHolder.b [Ljava/lang/String;
      // 33: bipush 33
      // 35: aaload
      // 36: invokevirtual java/lang/String.compareToIgnoreCase (Ljava/lang/String;)I
      // 39: ifne 49
      // 3c: goto 43
      // 3f: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 42: athrow
      // 43: aconst_null
      // 44: areturn
      // 45: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 48: athrow
      // 49: aload 1
      // 4a: areturn
      // 4b: aconst_null
      // 4c: areturn
      // try (9 -> 17): 18 java/lang/SecurityException
      // try (11 -> 26): 27 java/lang/SecurityException
      // try (20 -> 31): 31 java/lang/SecurityException
   }

   @Override
   public void setOtherTargetMessageVariable(String var1) {
      try {
         if (this.customAssertion instanceof CustomMessageTargetable) {
            ((CustomMessageTargetable)this.customAssertion).setTargetMessageVariable(var1);
         }
      } catch (SecurityException var2) {
         throw a(var2);
      }
   }

   @Override
   public String getTargetName() {
      try {
         return this.customAssertion instanceof CustomMessageTargetable ? ((CustomMessageTargetable)this.customAssertion).getTargetName() : null;
      } catch (SecurityException var1) {
         throw a(var1);
      }
   }

   @Override
   public boolean isTargetModifiedByGateway() {
      // $VF: Couldn't be decompiled
      // Please report this to the Vineflower issue tracker, at https://github.com/Vineflower/vineflower/issues with a copy of the class file (if you have the rights to distribute it!)
      // java.lang.RuntimeException: parsing failure!
      //   at org.jetbrains.java.decompiler.modules.decompiler.decompose.DomHelper.parseGraph(DomHelper.java:211)
      //   at org.jetbrains.java.decompiler.main.rels.MethodProcessor.codeToJava(MethodProcessor.java:174)
      //
      // Bytecode:
      // 00: aload 0
      // 01: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 04: instanceof com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable
      // 07: ifeq 28
      // 0a: aload 0
      // 0b: getfield com/l7tech/policy/assertion/CustomAssertionHolder.customAssertion Lcom/l7tech/policy/assertion/ext/CustomAssertion;
      // 0e: checkcast com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable
      // 11: invokeinterface com/l7tech/policy/assertion/ext/targetable/CustomMessageTargetable.isTargetModifiedByGateway ()Z 1
      // 16: ifeq 28
      // 19: goto 20
      // 1c: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 1f: athrow
      // 20: bipush 1
      // 21: goto 29
      // 24: invokestatic com/l7tech/policy/assertion/CustomAssertionHolder.a (Ljava/lang/Exception;)Ljava/lang/Exception;
      // 27: athrow
      // 28: bipush 0
      // 29: ireturn
      // try (0 -> 9): 10 java/lang/SecurityException
      // try (4 -> 14): 14 java/lang/SecurityException
   }

   static {
      String[] var5 = new String[40];
      int var3 = 0;
      String var2 = "\u001aIxw=\u0007Q\u001cE}w2_K\nIy=~B@\nI`*2UVVE`+%_HWA|>\t\nNz*%~D\u0014C\u0010:Sf,>]\u00058Uf=#DL\u0016H>8Tr-<UK\r\u0006s7#\u0010e7Ia\u0016$\\IYVt*0]@\rCgxv\u0015V^\u0006z>q\u0015VW\u0003fx<EV\r\u0006{7%\u0010G\u001c\u0006{-=\\\u0018\tIy12Is\u0018J|<0DJ\u000bey9\"CK\u0018Kp\n\u001aGa=6_W\u0010Cf\u0018\tIy12Is\u0018J|<0DJ\u000bey9\"CK\u0018Kp6\u001aIxv=\u0007Q\u001cE}v2_K\nIy=\u007fEQ\u0010J;\u001b$CQ\u0016KT+\"UW\rOz6\u0019_I\u001dCg\u000e0\\L\u001dGa7#\u000f:Sf,>]d\nUp*%YJ\u0017\u0010:Sf,>]\u00058Uf=#DL\u0016H\f\u0010HV9%UB\u0016T|=\"\u001a\"\u0006V-\"DJ\u0014gf+4BQ\u0010I{xl\u0010K\fJyx\f\r\nCa\u001b0D@\u001eIg14C\u0015\tIy12Ik\u0016Bp\u00160]@?Gv,>B\\-)Cg58CV\u0010I{x5UK\u0010Cqx&X@\u0017\u0006f=#YD\u0015Oo1?W\u0005\u0018Uf=#DL\u0016H;\u0010:Sf,>]d\nUp*%YJ\u0017\u001c\u0015\tIy12Id\u001dP|;4sI\u0018Uf60]@A\u001aIxv=\u0007Q\u001cE}v2_K\nIy=\u007fDW\u001cC;(>\\L\u001a_;95FL\u001aC;\u001b$CQ\u0016KT+\"UW\rOz6\u0019_I\u001dCg\u00195FL\u001aC\u000f:Sf,>]d\nUp*%YJ\u0017\u0007\u000bCd-4CQ\u0015\tIy12Id\u001dP|;4sI\u0018Uf60]@\u0004\u0017Sy4,,Hp !UF\rCqx4BW\u0016T5/9UKYUp*8QI\u0010\\|66\u0010D\nUp*%YJ\u0017\b\u0010:Sf,>]d\nUp*%YJ\u0017\u001c\b\u000bCf(>^V\u001c\u0014\tIy12Id\u001dP|;4yK\nRt62U\u0002Y{\u0007\u000bCd-4CQ\u000f\u000eUe\u001d)D@\u000bHt4\u001fQH\u001c\u000b\u001dCf;#YU\rOz6\u0014WKp,0TD\rG\\68DL\u0018J|\"4T<<Tg7#\u0010U\u000bIa7%IU\u0010Hrx%X@YE`+%_HYGf+4BQ\u0010I{x3UD\u0017\u0006=#aM\fU\u0006v9$C@D]$%1\u001aIxw=\u0007Q\u001cE}w!_I\u0010Elw0CV\u001cTa1>^\n:Sf,>]d\nUp*%YJ\u0017nz45UW\b\u000bCf(>^V\u001c\u000fU\u0006V9%UB\u0016T|=\"\u0010\u0018Y\u0002\"{\u0002U\u0006\u001c<Tg7#\u0010V\u001cT|9=Y_\u0010Hrx0CV\u001cTa1>^\u000b";
      int var4 = "\u001aIxw=\u0007Q\u001cE}w2_K\nIy=~B@\nI`*2UVVE`+%_HWA|>\t\nNz*%~D\u0014C\u0010:Sf,>]\u00058Uf=#DL\u0016H>8Tr-<UK\r\u0006s7#\u0010e7Ia\u0016$\\IYVt*0]@\rCgxv\u0015V^\u0006z>q\u0015VW\u0003fx<EV\r\u0006{7%\u0010G\u001c\u0006{-=\\\u0018\tIy12Is\u0018J|<0DJ\u000bey9\"CK\u0018Kp\n\u001aGa=6_W\u0010Cf\u0018\tIy12Is\u0018J|<0DJ\u000bey9\"CK\u0018Kp6\u001aIxv=\u0007Q\u001cE}v2_K\nIy=\u007fEQ\u0010J;\u001b$CQ\u0016KT+\"UW\rOz6\u0019_I\u001dCg\u000e0\\L\u001dGa7#\u000f:Sf,>]d\nUp*%YJ\u0017\u0010:Sf,>]\u00058Uf=#DL\u0016H\f\u0010HV9%UB\u0016T|=\"\u001a\"\u0006V-\"DJ\u0014gf+4BQ\u0010I{xl\u0010K\fJyx\f\r\nCa\u001b0D@\u001eIg14C\u0015\tIy12Ik\u0016Bp\u00160]@?Gv,>B\\-)Cg58CV\u0010I{x5UK\u0010Cqx&X@\u0017\u0006f=#YD\u0015Oo1?W\u0005\u0018Uf=#DL\u0016H;\u0010:Sf,>]d\nUp*%YJ\u0017\u001c\u0015\tIy12Id\u001dP|;4sI\u0018Uf60]@A\u001aIxv=\u0007Q\u001cE}v2_K\nIy=\u007fDW\u001cC;(>\\L\u001a_;95FL\u001aC;\u001b$CQ\u0016KT+\"UW\rOz6\u0019_I\u001dCg\u00195FL\u001aC\u000f:Sf,>]d\nUp*%YJ\u0017\u0007\u000bCd-4CQ\u0015\tIy12Id\u001dP|;4sI\u0018Uf60]@\u0004\u0017Sy4,,Hp !UF\rCqx4BW\u0016T5/9UKYUp*8QI\u0010\\|66\u0010D\nUp*%YJ\u0017\b\u0010:Sf,>]d\nUp*%YJ\u0017\u001c\b\u000bCf(>^V\u001c\u0014\tIy12Id\u001dP|;4yK\nRt62U\u0002Y{\u0007\u000bCd-4CQ\u000f\u000eUe\u001d)D@\u000bHt4\u001fQH\u001c\u000b\u001dCf;#YU\rOz6\u0014WKp,0TD\rG\\68DL\u0018J|\"4T<<Tg7#\u0010U\u000bIa7%IU\u0010Hrx%X@YE`+%_HYGf+4BQ\u0010I{x3UD\u0017\u0006=#aM\fU\u0006v9$C@D]$%1\u001aIxw=\u0007Q\u001cE}w!_I\u0010Elw0CV\u001cTa1>^\n:Sf,>]d\nUp*%YJ\u0017nz45UW\b\u000bCf(>^V\u001c\u000fU\u0006V9%UB\u0016T|=\"\u0010\u0018Y\u0002\"{\u0002U\u0006\u001c<Tg7#\u0010V\u001cT|9=Y_\u0010Hrx0CV\u001cTa1>^\u000b"
         .length();
      char var1 = '\'';
      int var7 = -1;

      label24:
      while (true) {
         byte var10000 = 69;
         String var10001 = var2.substring(++var7, var7 + var1);
         byte var10002 = -1;

         while (true) {
            String var8 = b(var10000, b(var10001));
            switch (var10002) {
               case 0:
                  var5[var3++] = var8;
                  if ((var7 += var1) >= var4) {
                     b = var5;
                     String[] var9 = b;
                     CUSTOM_ASSERTION = b[2];
                     EXTERNAL_NAME = var9[18];
                     EXTERNAL_NAME_PREFIX = var9[15];
                     logger = Logger.getLogger(CustomAssertionHolder.class.getName());
                     META_INITIALIZED = CustomAssertionHolder.class.getName() + b[30];
                     return;
                  }

                  var1 = var2.charAt(var7);
                  break;
               default:
                  var5[var3++] = var8;
                  if ((var7 += var1) < var4) {
                     var1 = var2.charAt(var7);
                     continue label24;
                  }

                  var2 = "-\tY\"-KE\u001bhi$;M^\u001fFtwc\u001f\u000f\u0006Hv2*KO8F~2\u0017\\E\u0018";
                  var4 = "-\tY\"-KE\u001bhi$;M^\u001fFtwc\u001f\u000f\u0006Hv2*KO8F~2\u0017\\E\u0018".length();
                  var1 = 20;
                  var7 = -1;
            }

            var10000 = 74;
            var10001 = var2.substring(++var7, var7 + var1);
            var10002 = 0;
         }
      }
   }

   private static Exception a(Exception var0) {
      return var0;
   }

   private static char[] b(String var0) {
      char[] var10000 = var0.toCharArray();
      if (var10000.length < 2) {
         var10000[0] = (char)(var10000[0] ^ 96);
      }

      return var10000;
   }

   private static String b(int var0, char[] var1) {
      int var10003 = var1.length;
      int var10002 = var0;
      char[] var10001 = var1;
      int var10000 = var10003;

      for (int var2 = 0; var10000 > var2; var2++) {
         var10001[var2] = (char)(var10001[var2] ^ var10002 ^ switch (var2 % 7) {
            case 0 -> 60;
            case 1 -> 99;
            case 2 -> 80;
            case 3 -> 29;
            case 4 -> 20;
            case 5 -> 117;
            default -> 96;
         });
      }

      return new String(var10001).intern();
   }
}
