Hello All,
I'm having trouble fetching password-protected web pages that use .asp
files. When I try to use authorization_basic, I get a return code of "401:
access denied". I know I'm passing the correct user id and password,
because I can get in through the browser. However, this is the first time
I've tried to fetch a page from a site that uses .asp files. Hence, I
suspect there is some trouble with my interaction with the .asp script. I
am copying my code below. Am I missing something?
$user_agent=new LWP::UserAgent;
$user_agent->timeout([$secs]);
$cookie_jar = HTTP::Cookies->new;
$user_agent->cookie_jar($cookie_jar);
$request=new HTTP::Request(GET => ${url});
$request->authorization_basic("${username}","${password}");
$response=$user_agent->request($request);
Thanks,
Greg