Help with NTLM Credentials and HttpState

View: New views
3 Messages — Rating Filter:   Alert me  

Help with NTLM Credentials and HttpState

by Paul Krinsky :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I'm getting "No credentials available for NTLM <any realm>@ffeusplmsap94q:80" and assume it's because I'm not setting the credentials correctly. There is a bug that provides the below code to set the credentials but that method is not static.

        CommonsHttpMessageSender.getHttpState().setCredentials(...);

Another post uses something like the following but that doesn't seem to work either.

       client.setProperty(CommonsHttpMessageSender.HTTP_STATE, httpState);

Does someone have a complete example of how to get NTLM to work or at least tell me how to correctly set the nt credentials?

Thanks


Re: Help with NTLM Credentials and HttpState

by Tomek Sztelak :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi
We have ( already fixed in svn ) bug which cases that that domain
name was swaped with  user name for NTLM, so if you specify
"MYDOMAIN\\userName" then wrong values are given to NTLM credentials.
As a temporary workaround ( till next release ) you can just swap
domain name with user name : "userName\\MYDOMAIN".

On 2/22/07, Paul Krinsky <paul.krinsky@...> wrote:

>
> I'm getting "No credentials available for NTLM <any realm>@ffeusplmsap94q:80"
> and assume it's because I'm not setting the credentials correctly. There is
> a bug that provides the below code to set the credentials but that method is
> not static.
>
>         CommonsHttpMessageSender.getHttpState().setCredentials(...);
>
> Another post uses something like the following but that doesn't seem to work
> either.
>
>        client.setProperty(CommonsHttpMessageSender.HTTP_STATE, httpState);
>
> Does someone have a complete example of how to get NTLM to work or at least
> tell me how to correctly set the nt credentials?
>
> Thanks
>
>
> --
> View this message in context: http://www.nabble.com/Help-with-NTLM-Credentials-and-HttpState-tf3275242.html#a9108222
> Sent from the XFire - Dev mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list please visit:
>
>     http://xircles.codehaus.org/manage_email
>
>


--
-----
When one of our products stops working, we'll blame another vendor
within 24 hours.

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email


Re: Help with NTLM Credentials and HttpState

by pcable :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Where you ever able to get this to work?  

I am trying to do this same thing for Digest Authentication and I am hitting the exact same things you are mentioning in the below message:

Paul Krinsky wrote:
I'm getting "No credentials available for NTLM <any realm>@ffeusplmsap94q:80" and assume it's because I'm not setting the credentials correctly. There is a bug that provides the below code to set the credentials but that method is not static.

        CommonsHttpMessageSender.getHttpState().setCredentials(...);

Another post uses something like the following but that doesn't seem to work either.

       client.setProperty(CommonsHttpMessageSender.HTTP_STATE, httpState);

Does someone have a complete example of how to get NTLM to work or at least tell me how to correctly set the nt credentials?

Thanks