Uploaded image for project: 'HttpComponents HttpClient'
  1. HttpComponents HttpClient
  2. HTTPCLIENT-1129

Redirect and Kerberos authentication in conflict

    XMLWordPrintableJSON

Details

    • Wish
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.1.2
    • 4.2 Alpha1
    • HttpClient (classic)
    • None

    Description

      We are using the HttpClient to connect to a Website that uses Kerberos-Authentication.

      Beware this trigger word: Kerberos! I think this is not the problem, but please read on.

      Here is the sequence of events:

      Client: GET /
      Server: Unauthorized.
      Client: GET / and includes authentication.
      Server: 302 to /something on the same host (this shows that in principle authentication works)
      Client: GET /something, does not include authentication
      Server: Unauthorized

      Client quits with 401-Unauthorized.

      I would have expected one of the following instead:

      1) Client immediately sends authorization information with the redirected GET /something
      2) Client re-requests the /something with authorization after 401-Unauthorized.

      We could get around the problem by setting the ConnectionReuseStrategy to a constant false.

      It would be great if someone could tell me if HttpClient works as expected or whether there is a bug or misconfiguration lurking.

      Thanks,
      Harald.

      Attachments

        1. wiresharkFrom401.txt
          40 kB
          Harald Kirsch
        2. this_works.log
          62 kB
          Harald Kirsch
        3. this_also_works.log
          61 kB
          Harald Kirsch
        4. log-with-fix-take1.txt
          32 kB
          Harald Kirsch
        5. log-r1178262.txt
          33 kB
          Harald Kirsch
        6. logFrom401Example.txt
          33 kB
          Harald Kirsch
        7. HTTPCLIENT-1129-fix-take1.patch
          2 kB
          Oleg Kalnichevski
        8. examples.txt
          2 kB
          Harald Kirsch
        9. customAuthScheme.log
          27 kB
          Harald Kirsch

        Activity

          People

            Unassigned Unassigned
            haraldk Harald Kirsch
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: