Hey Matt,

So just to confirm then if you have no existing sessions and then you start
the client, you do not receive any 200 OK responses? Can you confirm this
only seems to happen when there is an existing authenticated session?

When you say it doesn't make a difference using 4.3 or specifying
credentials, you mean it seems to work for about 30 seconds and then stops
still? I am also wondering if what you are trying would work using
URLConnection. It has no problem with transparent NTLM in my experience and
testing it would rule out some other potential issues.

Best of luck, discovering NTLM was one of my least favorite discoveries :P

Rob
Hi Rob,

> Are you using NTLM Authentication transparently?

Well, it certainly looked like it was authenticating transparently, I
assumed it was, but it now looks like it is -- somehow -- piggybacking on
authentications from browser sessions that were open at the same time I was
running my Java code.

I've tried 4.3, and specifying the credentials explicitly -- doesn't make a
difference, unfortunately.

Thanks,

-- Matt




On 30 March 2014 15:40, Rob Goodberry <[email protected]> wrote:

> Hey Matt,
>
> Are you using NTLM Authentication transparently? I emailed this group a
> while ago with problems using NTLM transparently in HC 4.2.3 and was told
> that support for that was going in for 4.3. Unfortunately my workplace is
> limited to JRE 1.5 so I was unable to test the new functionality which
> relied on (I believe) at least JRE 1.6. I was however able to use
> URLConnection with transparent NTLM authentication without an issue, which
> ended up being okay because I didn't really end up needing any advanced HC
> functionality.
>
> Do you have any limitations which prevent you from trying with HC 4.3+?
>
> Rob
> On 2014-03-30 10:12 AM, "Oleg Kalnichevski" <[email protected]> wrote:
>
> > On Fri, 2014-03-28 at 15:12 +0000, Matt Russell wrote:
> > > Hi,
> > >
> > > I'm hoping someone can help me diagnose an intermittent "407 Proxy
> > > Authentication Required" error when using HttpClient through an NTLM
> > proxy.
> > >
> > > I've found that I always get a 407 responses, unless I first go and
> fetch
> > > any web page in a browser. After I load a page, I get "200 OK"
> responses
> > > for 30 seconds via HttpClient, after which it reverts to 407s.
> > >
> > > (My guess is that this is because HttpClient is handing off the
> > > authentication to the OS, as is the web browser, and the browser
> request
> > > causes an authentication token to be cached for a while, which lets
> > > HttpClient work until it expires.)
> > >
> > > I'm using HttpClient 4.2.3 on Windows XP, proxy is squid/2.7.STABLE4.
> > I've
> > > tried both with and without a JCIFS NTLM engine, but it seems to make
> no
> > > difference. Java code and logs below.
> > >
> >
> > Matt,
> >
> > Both JCIFS and the internal NTLM engines are pure java, platform
> > independent implementations that make no use of Windows specific
> > functionality. This is all I can tell you.
> >
> > There is only one person on the project with in-depth understanding of
> > NTLM. You may want to try your luck posting this question to the dev
> > list along with Wireshark packet dumps of successful and unsuccessful
> > session (this is the first thing you most certainly will be asked to
> > produce).
> >
> > Oleg
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [email protected]
> > For additional commands, e-mail: [email protected]
> >
> >
>

Reply via email to