code: @Route(method = HttpMethod.POST, uri = "/monitor/login")
      public Result authenticate(@FormParameter("username") String username, @FormParameter("password") String password) {
          if (!configuration.getBooleanWithDefault("monitor.auth.enabled", true)) {
              // If the authentication is disabled, just jump to the dashboard page.
              return dashboard();
          }
  
          final String name = configuration.getOrDie("monitor.auth.username");
          final String pwd = configuration.getOrDie("monitor.auth.password");
  
          if (name.equals(username) && pwd.equals(password)) {
              session().put("wisdom.monitor.username", username);
              logger().info("Authentication successful - {}", username);
              return dashboard();
          } else {
              logger().info("Authentication failed - {}", username);
              context().flash().error("Authentication failed - check your credentials");
              return login();
          }
      }
docs: Authenticates the user.
  
  @param username the username
  @param password the password
  @return the default page if the authentication succeed, the login page otherwise.