my $mech = WWW::Mechanize->new( keep_alive => 1, ); $mech->credentials( 'theserver.com:80', '', $username, $password ); #### LWP::UserAgent::new: () LWP::UserAgent::proxy: ftp http://**url sanitized*** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 811 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 504 bytes LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In first phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVNTUA**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 566 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 351 bytes LWP::Protocol::http::request: Keep the http connection to **url sanitized***:80 LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In second phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABg**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 811 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 106 bytes LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In first phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVNTUAA**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 566 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 351 bytes LWP::Protocol::http::request: Keep the http connection to **url sanitized***:80 LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In second phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVNTUAADAAAAGA**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 811 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1486 bytes LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In first phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVN**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized*** for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 566 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 351 bytes LWP::Protocol::http::request: Keep the http connection to **url sanitized***:80 LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In second phase of NTLM authentication LWP::Authen::Ntlm::authenticate: Returning response object with auth header: Authorization NTLM TlRMTVNTUA**chop** LWP::UserAgent::request: () HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking **url sanitized***for cookies HTTP::Cookies::add_cookie_header: Checking .net for cookies LWP::UserAgent::send_request: GET http://**url sanitized*** LWP::UserAgent::_need_proxy: Not proxied LWP::Protocol::http::request: () LWP::Protocol::collect: read 811 bytes LWP::Protocol::collect: read 1736 bytes LWP::Protocol::collect: read 1380 bytes LWP::Protocol::collect: read 106 bytes LWP::UserAgent::request: Simple response: Unauthorized LWP::Authen::Ntlm::authenticate: authenticate() has been called LWP::Authen::Ntlm::authenticate: In first phase of NTLM authentication