Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Authentication #13

Open
kostajh opened this issue Sep 28, 2017 · 4 comments
Open

Authentication #13

kostajh opened this issue Sep 28, 2017 · 4 comments

Comments

@kostajh
Copy link

kostajh commented Sep 28, 2017

Thanks for this nice library. I'd like to use it for a service which requires NTLM authentication. I've looked through the code but I'm not sure I see a way to set the necessary authentication in the config.yml. Could you please provide some documentation for this?

@goetas
Copy link
Member

goetas commented Sep 28, 2017

sorry for being ignorant, but what is NTLM authentication?

@kostajh
Copy link
Author

kostajh commented Sep 28, 2017

@goetas good question :) It's a Microsoft authentication protocol.

Here's a related discussion and an older post on the topic.

If I am using Guzzle, I can communicate with the service using NTLM like so:

$response = $client->request('POST', $url, [
  'auth' => [$user, $password, 'ntlm'],
  'body' => $request,
  'headers' => [
      'Method' => 'POST',
      'Connection' => 'Keep-Alive',
      'User-Agent' => 'PHP-SOAP-CURL',
      'Content-Type' => 'text/xml; charset=utf-8',
      'SOAPAction' => '"urn:microsoft-urn:microsoft-dynamics-schemas/codeunit/GuestInfo:GetMember"',
  ],
]);
}

Hope this helps.

@goetas
Copy link
Member

goetas commented Sep 28, 2017

hmmm. currently is not supported...
pull requests are welcome.
i think something can be done using http://php.net/manual/en/function.stream-context-create.php

@kostajh
Copy link
Author

kostajh commented Sep 28, 2017

Ok, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants