1
當我嘗試訪問調用WCF函數的窗體時,我不斷收到此錯誤。 其實它的工作原理我的本地機器上,但是當它在服務器上,這種事情發生:(錯誤:遠程服務器返回錯誤:(401)未授權
源錯誤:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
堆棧跟蹤:
[WebException: The remote server returned an error: (401) Unauthorized.]
System.Net.HttpWebRequest.GetResponse() +6115603
System.ServiceModel.Channels.HttpChannelRequest.WaitForReply(TimeSpan timeout) +48
[MessageSecurityException: The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'Negotiate,NTLM'.]
System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) +9439503
System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) +345
Project.WCFUser.Users.HaveAccess(String userid, String filename) +0
Project.WCFUser.Users.HaveAccess(String userid, String filename) in C:\Documents and Settings\MyPC\My Documents\Visual Studio 2010\Project\Project\Project\Service References\Users\Reference.cs:71
Project.View.User.Details.Page_Load(Object sender, EventArgs e) in C:\Documents and Settings\MyPC\My Documents\Visual Studio 2010\Project\Project\Project\View\User\Details.aspx.cs:50
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +91
System.Web.UI.Control.LoadRecursive() +74
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2207
你正在使用哪種綁定?您發佈WCF服務的安全配置? – danish 2012-07-23 03:43:33