I'm attempting to make a request to a REST based service that is protected by NTLM authentication. Does Network.CreateHTTPClient() support NTLM authentication?
I looked at the kitchen sink code and it has an example for Basic Auth (using setRequestHeader() to pass in an Authorization header) but this won't work for NTLM authentication.
I believe that Titanium is using ASIHTTPRequest under the hood, and it supports NTLM authentication, but I didn't see any way to hook into the setUsername, setPassword and setDomain parameters.
Any tips greatly appreciated. Thanks!
Hmm, by reading TiNetworkHTTPClientProxy.m it looks like Titanium does not support NTLM authentication.
However, I can hack it in by hardcoding a username, password and domain into the file by adding the following to the "open" method:
[request setUsername:@"username"]; [request setPassword:@"password"]; [request setDomain:@"domain"];
I've confirmed that this works.
- How bad of an idea is it to hack the generated file? I'm guessing its pretty bad.
- How often/what triggers the generation of these files?
- It looks like adding proper support for NTLM to Titanium shouldn't be that hard. Assuming I code it in correctly, whats the odds of getting the code checked into the release?
Has anyone else found a way to perform NTLM authentication?
I want to connect to website that uses NTLM Authentication
Can you please help me by a snap shot of your code