code: public boolean validLogin(String identifier, String password, String hash) {
          Objects.requireNonNull(identifier, Required.USERNAME.toString());
          Objects.requireNonNull(password, Required.PASSWORD.toString());
          Objects.requireNonNull(hash, Required.HASH.toString());
  
          Cache cache = Application.getInstance(CacheProvider.class).getCache(CacheName.AUTH);
          boolean authenticated = false;
          if (!userHasLock(identifier) && CodecUtils.checkJBCrypt(password, hash)) {
              authenticated = true;
          } else {
              cache.increment(identifier);
          }
  
          return authenticated;
      }
docs: Creates a hashed value of a given clear text password and checks if the
  value matches a given, already hashed password
  
  @param identifier The identifier to authenticate
  @param password The clear text password
  @param hash The previously hashed password to check
  @return True if the new hashed password matches the hash, false otherwise