Program: 101805
Project: 101805
Buggy source:
@EventHandler(ignoreCancelled=true) public void onEntityDamage(EntityDamageEvent event){
  boolean noHack=true;
  if (event instanceof EntityDamageByEntityEvent) {
    EntityDamageByEntityEvent e=(EntityDamageByEntityEvent)event;
    if (event.getEntity() instanceof Player) {
      Player player=(Player)event.getEntity();
      if (e.getDamager() instanceof Arrow) {
        Arrow arrow=(Arrow)e.getDamager();
        if (arrow.getShooter() instanceof Player && event.getEntity() == arrow.getShooter()) {
          event.setCancelled(true);
        }
      }
      if (e.getDamager() instanceof Player) {
        Player p=(Player)e.getDamager();
        backend.logDamage(p,1);
        int value=p.getInventory().getItemInHand().containsEnchantment(Enchantment.KNOCKBACK) ? 2 : 1;
        backend.logDamage(player,value);
        if (checkManager.willCheck(p,CheckType.LONG_REACH)) {
          Distance distance=new Distance(player.getLocation(),p.getLocation());
          if (backend.checkLongReachDamage(distance.getXDifference(),distance.getYDifference(),distance.getZDifference())) {
            event.setCancelled(!config.silentMode());
            log("String_Node_Str",p,CheckType.LONG_REACH);
            noHack=false;
          }
        }
      }
 else {
        if (e.getDamager() instanceof TNTPrimed || e.getDamager() instanceof Creeper) {
          backend.logDamage(player,3);
        }
 else {
          backend.logDamage(player,1);
        }
      }
    }
    if (e.getDamager() instanceof Player) {
      Player player=(Player)e.getDamager();
      backend.logDamage(player,1);
      if (checkManager.willCheck(player,CheckType.AUTOTOOL) && backend.justSwitchedTool(player)) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.AUTOTOOL);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.FORCEFIELD) && backend.justSprinted(player)) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.FORCEFIELD);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.NO_SWING) && !backend.justAnimated(player)) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.NO_SWING);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.FORCEFIELD) && !backend.checkSight(player,e.getEntity())) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.FORCEFIELD);
        noHack=false;
      }
      if (noHack) {
        decrease(player);
      }
    }
  }
  Anticheat.getManager().addEvent(event.getEventName(),event.getHandlers().getRegisteredListeners());
}

Fixed version (ground truth):
@EventHandler(ignoreCancelled=true) public void onEntityDamage(EntityDamageEvent event){
  boolean noHack=true;
  if (event instanceof EntityDamageByEntityEvent) {
    EntityDamageByEntityEvent e=(EntityDamageByEntityEvent)event;
    if (event.getEntity() instanceof Player) {
      Player player=(Player)event.getEntity();
      if (e.getDamager() instanceof Arrow) {
        Arrow arrow=(Arrow)e.getDamager();
        if (arrow.getShooter() instanceof Player && event.getEntity() == arrow.getShooter()) {
          event.setCancelled(true);
        }
      }
      if (e.getDamager() instanceof Player) {
        Player p=(Player)e.getDamager();
        backend.logDamage(p,1);
        int value=p.getInventory().getItemInHand().containsEnchantment(Enchantment.KNOCKBACK) ? 2 : 1;
        backend.logDamage(player,value);
        if (checkManager.willCheck(p,CheckType.LONG_REACH)) {
          Distance distance=new Distance(player.getLocation(),p.getLocation());
          if (backend.checkLongReachDamage(distance.getXDifference(),distance.getYDifference(),distance.getZDifference())) {
            event.setCancelled(!config.silentMode());
            log("String_Node_Str",p,CheckType.LONG_REACH);
            noHack=false;
          }
        }
      }
 else {
        if (e.getDamager() instanceof TNTPrimed || e.getDamager() instanceof Creeper) {
          backend.logDamage(player,3);
        }
 else {
          backend.logDamage(player,1);
        }
      }
    }
    if (e.getDamager() instanceof Player) {
      Player player=(Player)e.getDamager();
      backend.logDamage(player,1);
      if (checkManager.willCheck(player,CheckType.AUTOTOOL) && backend.justSwitchedTool(player)) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.AUTOTOOL);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.FORCEFIELD) && backend.justSprinted(player)) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.FORCEFIELD);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.NO_SWING) && !backend.justAnimated(player,event.getEntity())) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.NO_SWING);
        noHack=false;
      }
      if (checkManager.willCheck(player,CheckType.FORCEFIELD) && !backend.checkSight(player,e.getEntity())) {
        event.setCancelled(!config.silentMode());
        log("String_Node_Str",player,CheckType.FORCEFIELD);
        noHack=false;
      }
      if (noHack) {
        decrease(player);
      }
    }
  }
  Anticheat.getManager().addEvent(event.getEventName(),event.getHandlers().getRegisteredListeners());
}