WCF Service calling Windows Authentication protected URL
I have a WCF service hosted in IIS7.5 running as a specific domain account. Call it app1. This service must call a windows integrated authentication protected service hosted within another IIS application. Call it app2
app2 IIS authentic开发者_运维知识库ation settings are "windows authorisation" enabled everything else disabled.
I have granted app1's identity access to the NTFS resource where app2 is deployed.
I am using the HttpWebRequest class to make the call from app1 to app2 and I am setting the request.credentials = CredentialCache.DefaultNetworkCredentials
I keep getting a 401 unauthorised response.
Any ideas? It must be something simple :(
var _httpWebRequest = (HttpWebRequest)WebRequest.Create(serviceUrl); _httpWebRequest.UseDefaultCredentials = true; _httpWebRequest.Method = "POST"; _httpWebRequest.ContentType = "application/xml";
精彩评论