-
Notifications
You must be signed in to change notification settings - Fork 34
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
NTLM authentication to a proxy/web server using Nsspi Client ?? #4
Comments
I think yes, i was able to resolve it, i shall post a sample code on monday ! |
Thanks so much! That'd be so helpful, looking forward to checking it out :) |
Hey @k2ibegin, figured it out! The problem was that a different socket was being used for each step of the NTLM authentication process, which was causing it to reset unexpectedly. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
To continue our discussion from the post at
http://stackoverflow.com/questions/17241365/client-server-authentication-using-sspi/24312883?noredirect=1#
As I said I want to achieve the NTLM authentication from my client program to the web server (IIS/Proxy server). I am wondering if it is possible via the nssp library. At the moment the nsspi has both client side and server side code which uses the SSPI to achieve the authentication.
How can I proceed to may be just use the client side api to somehow replicate what browser does in case of NTLM authentication, which would be to just replicate and fill in the required request response headers for the initial and 2 way handshakes?
I was planning to do it on my own, but not sure if I could utilize a standard mechanism to hash the password and achieve the same without using SSPI ? OR it would be better to use the SSPI api.
I have to write this solution in c#.
Update:
As you suggested I decided to use the client side of NSSPI and try to generate tokens and stuff into the request headers. However, the Server sends back the response as WWW-Authenticate again as NTLM. If i do not Base 64 encode the token before putting in authoraization header then i get back
400 (bad request) error.
I am expecting IIS server to return me the challenge based on the token that i send to it in type 2 message.
Thank you
Kuldeep
The text was updated successfully, but these errors were encountered: