in reply to LWP::UserAgent vs. NTLM Challenge/Response

In many cases, the site with SSO sets session cookies to keep track of authenticated sessios. Please try enabling cookie jars for LWP::Useragent, to store cookies either by adding

$ua->cookie_jar({ file => "$ENV{HOME}/.cookies.txt" });
or
require HTTP::Cookies; $ua->cookie_jar(HTTP::Cookies->new(file => "$ENV{HOME}/.cookies.txt" +));
or even
$ua->cookie_jar({}); #this will store cookie in memory. Not in file
to your code. Enable cookie jar before you send the request.

Hope this helps.

--VC

Replies are listed 'Best First'.
Re^2: LWP::UserAgent vs. NTLM Challenge/Response
by jpk236 (Monk) on Oct 04, 2007 at 15:18 UTC
    VC:

    Thanks for the reply. I tried all three of your examples and none of them seemed to help.

    This is all that was written to cookies.txt after I ran the script a few times with the first two examples:
    #LWP-Cookies-1.0
    - Justin