Forum Discussion

Mathew's avatar
Mathew
Icon for Cirrus rankCirrus
May 22, 2019

HTTP Monitor with authentication

Hi

How can we configure a http monitor with username and password.
  • Hamish's avatar
    Hamish
    Icon for Cirrocumulus rankCirrocumulus

    You could type in the username & password on the 'new HTTP monitor' form (By new, I mean creating a new one, not that the form is new)

     

     

    Or make an external monitor via curl and include whatever you want in the headers...

    • Mathew's avatar
      Mathew
      Icon for Cirrus rankCirrus

      I have tried this already and even if i given the wrong password its still in enabled state.

      • Hamish's avatar
        Hamish
        Icon for Cirrocumulus rankCirrocumulus

        Don't forget to tell it what the expected response is for a successful query...

  • What authentication method is supported on the web server you are trying to monitor?

     

    Basic Authentication and NTLM/NTLMv2 are supported methods under the HTTP and HTTPS Monitors.

     

    For NTLM to work the web server needs to respond with a 401 response status with a WWW-Authenticate header set to NTLM when it tries to authenticate with Basic Authentication, which it will do first.

     

    https://support.f5.com/csp/article/K2167

      • Hamish's avatar
        Hamish
        Icon for Cirrocumulus rankCirrocumulus

        Then it's likely that you forgot to tell the monitor what constitutes a valid response. Otherwise it takes the fact that the login failed to be evidence that the site is up.