http://qs321.pair.com?node_id=720011


in reply to Re^2: NTLM Authentication with SOAP::Lite not working
in thread NTLM Authentication with SOAP::Lite not working

I'm not sure how overriding the get_basic_credentials method solves your problem, but it seems like a bad idea. You should read the LWP::Authen::Ntlm documentation, it includes a clear example of usage.

  • Comment on Re^3: NTLM Authentication with SOAP::Lite not working

Replies are listed 'Best First'.
Re^4: NTLM Authentication with SOAP::Lite not working
by mzehrer (Novice) on Dec 27, 2009 at 11:10 UTC
    Something like this should work
    use LWP::UserAgent; use LWP::Debug; use SOAP::Lite on_action => sub { "$_[0]$_[1]"; }; import SOAP::Data 'name', 'value'; our $sp_endpoint = 'http://sp.example.com/sites/mysite/_vti_bin/lists. +asmx'; our $sp_domain = 'sp.example.com:80'; our $sp_username = 'DOMAIN\username'; our $sp_password = 'xyz'; if ($debug) { LWP::Debug::level('+'); SOAP::Lite->import(+trace => 'all'); } my @ua_args = (keep_alive => 1); my @credentials = ($sp_domain, "", $sp_usernam, $sp_password); my $schema_ua = LWP::UserAgent->new(@ua_args); $schema_ua->credentials(@credentials); $soap = SOAP::Lite->proxy($sp_endpoint, @ua_args, credentials => \@cre +dentials); $soap->schema->useragent($schema_ua); $soap->uri("http://schemas.microsoft.com/sharepoint/soap/");