在Firefox Developer Edition中进行调试会产生WSFederationMessageException:ID3204

问题描述:

我非常喜欢Firefox开发者版,但在过去,我发现有很多问题只是试图去实现,往往需要管理员干预我在其他地方工作。我遇到的最新问题是,当试图登录到某个Web应用程序时,我在新的客户端网站上进行调试(名为XXX.YYY)时,出现以下服务器错误。当我使用Internet Explorer作为我的浏览器时,我不明白这一点。我能做些什么来纠正它?在Firefox Developer Edition中进行调试会产生WSFederationMessageException:ID3204

Server Error in '/XXX.YYY' Application. ID3204: WS-Federation SignIn request must specify a 'wtrealm' or 'wreply' parameter. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: Microsoft.IdentityModel.Protocols.WSFederation.WSFederationMessageException: ID3204: WS-Federation SignIn request must specify a 'wtrealm' or 'wreply' parameter.

Source Error:

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.

Stack Trace:

[WSFederationMessageException: ID3204: WS-Federation SignIn request must specify a 'wtrealm' or 'wreply' parameter.]
Microsoft.IdentityModel.Protocols.WSFederation.SignInRequestMessage..ctor(Uri baseUrl, String realm, String reply) +271
Microsoft.IdentityModel.Protocols.WSFederation.WSFederationMessage.CreateFromNameValueCollection(Uri baseUrl, NameValueCollection collection) +753
Microsoft.IdentityModel.Protocols.WSFederation.WSFederationMessage.TryCreateFromUri(Uri requestUri, WSFederationMessage& fedMsg) +57
Microsoft.IdentityModel.Web.WSFederationAuthenticationModule.GetSignOutCleanupMessage(HttpRequest request) +34
Microsoft.IdentityModel.Web.WSFederationAuthenticationModule.CanReadSignInResponse(HttpRequest request, Boolean onPage) +188
Microsoft.IdentityModel.Web.WSFederationAuthenticationModule.OnAuthenticateRequest(Object sender, EventArgs args) +85
System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +142 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +92

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.6.1590.0

我找到了解决方案!事实证明,问题在于Firefox开发者版默认情况下不会像IE开箱即用Windows NT LAN Manager(NTLM)协议进行身份验证。所以,你必须配置它这样做:

  1. 打开Firefox开发版和类型有关:在地址栏配置。您将会在 的提示下发出警告。点击“我接受风险!”按钮。
  2. 使用地址栏正下方浏览器顶部的“搜索”字段来查找network.automatic-ntlm-auth.trusted-uris配置参数。
  3. 双击配置参数的名称,或右键单击它并选择“修改”。
  4. 输入您无法验证身份的网站的网址。 https://localhost

无需指定端口号,也不是一个路径,以任何特定的页面,因为认证工作由网站基础站点:使用格式。您可以通过逗号分隔列出多个网站。现在,我试图在本地进行调试的XXX.YYY网络应用程序运行并进行身份验证就好了!

+0

很高兴知道您已解决此问题,如果可能,您可以将解决方案标记为答案。感谢您的分享。 –