在 Windows Server 2003 上托管 WCF Web 服务

发布于 2024-10-23 22:14:36 字数 2308 浏览 3 评论 0原文

出现以下错误...

“/”应用程序中的服务器错误。信息系统 指定的认证方案 '集成Windows身份验证, 匿名,但仅具有约束力 支持恰好一个的规范 认证方案。有效的 身份验证方案是 Digest, 协商、NTLM、基本或匿名。 更改 IIS 设置,以便仅 使用单一认证方案。 描述:未处理的异常 执行期间发生的 当前的网络请求。请查看 堆栈跟踪以获取有关的更多信息 错误及其起源 代码。

异常详细信息: 系统InvalidOperationException:IIS 指定的认证方案 '集成Windows身份验证, 匿名,但仅具有约束力 支持恰好一个的规范 认证方案。有效的 身份验证方案是摘要, 协商、NTLM、基本或匿名。 更改 IIS 设置,以便仅 采用单一认证方案。

来源错误:

生成了未处理的异常 当前执行期间 网络请求。有关信息 异常的起源和地点 可以使用异常来识别 下面的堆栈跟踪。

堆栈跟踪:

[InvalidOperationException:IIS 指定的认证方案 '集成Windows身份验证, 匿名,但仅具有约束力 支持恰好一个的规范 认证方案。有效的 身份验证方案是 Digest, 协商、NTLM、基本或匿名。 更改 IIS 设置,以便仅 使用单一认证方案。] System.ServiceModel.Web.WebServiceHost.SetBindingCredentialBasedOnHostedEnvironment(ServiceEndpoint 服务端点、身份验证方案 支持的方案)+446264
System.ServiceModel.Web.WebServiceHost.AddAutomaticWebHttpBindingEndpoints(ServiceHost 主机,IDictionary`2 已实施的合同,字符串 多个合同错误消息)+709
System.ServiceModel.Web.WebServiceHost.OnOpening() +203 Microsoft.ServiceModel.Web.WebServiceHost2.OnOpening() 在 e:\bt\3781\Microsoft.ServiceModel.Web\Microsoft.ServiceModel.Web\WebServiceHost2.cs:69 System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan 超时)+229
System.ServiceModel.HostingManager.ActivateService(字符串 规范化虚拟路径)+121
System.ServiceModel.HostingManager.EnsureServiceAvailable(字符串 规范化虚拟路径)+479

[ServiceActivationException: 服务“/Service.svc”不能 由于期间异常而激活 汇编。异常消息 is: IIS指定的身份验证 计划 '集成Windows身份验证, 匿名,但仅具有约束力 支持恰好一个的规范 认证方案。有效的 身份验证方案是 Digest, 协商、NTLM、基本或匿名。 更改 IIS 设置,以便仅 单一认证方案是 用过..]
System.ServiceModel.AsyncResult.End(IAsyncResult 结果)+11599786
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult 结果)+194
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.ExecuteSynchronous(HttpApplication 上下文,布尔流上下文)+176
System.ServiceModel.Activation.HttpModule.ProcessRequest(对象 发送者,EventArgs e) +278
System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +68 System.Web.HttpApplication.ExecuteStep(IExecutionStep) 步骤,布尔值&同步完成) +75

版本信息:Microsoft .NET 框架版本:2.0.50727.3615; ASP.NET版本:2.0.50727.3618

Getting the following err...

Server Error in '/' Application. IIS
specified authentication schemes
'IntegratedWindowsAuthentication,
Anonymous', but the binding only
supports specification of exactly one
authentication scheme. Valid
authentication schemes are Digest,
Negotiate, NTLM, Basic, or Anonymous.
Change the IIS settings so that only a
single authentication scheme is used.
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:
System.InvalidOperationException: IIS
specified authentication schemes
'IntegratedWindowsAuthentication,
Anonymous', but the binding only
supports specification of exactly one
authentication scheme. Valid
authentication schemes are Digest,
Negotiate, NTLM, Basic, or Anonymous.
Change the IIS settings so that only a
single authentication scheme is used.

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:

[InvalidOperationException: IIS
specified authentication schemes
'IntegratedWindowsAuthentication,
Anonymous', but the binding only
supports specification of exactly one
authentication scheme. Valid
authentication schemes are Digest,
Negotiate, NTLM, Basic, or Anonymous.
Change the IIS settings so that only a
single authentication scheme is used.]
System.ServiceModel.Web.WebServiceHost.SetBindingCredentialBasedOnHostedEnvironment(ServiceEndpoint
serviceEndpoint, AuthenticationSchemes
supportedSchemes) +446264
System.ServiceModel.Web.WebServiceHost.AddAutomaticWebHttpBindingEndpoints(ServiceHost
host, IDictionary`2
implementedContracts, String
multipleContractsErrorMessage) +709
System.ServiceModel.Web.WebServiceHost.OnOpening()
+203 Microsoft.ServiceModel.Web.WebServiceHost2.OnOpening()
in
e:\bt\3781\Microsoft.ServiceModel.Web\Microsoft.ServiceModel.Web\WebServiceHost2.cs:69
System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan
timeout) +229
System.ServiceModel.HostingManager.ActivateService(String
normalizedVirtualPath) +121
System.ServiceModel.HostingManager.EnsureServiceAvailable(String
normalizedVirtualPath) +479

[ServiceActivationException: The
service '/Service.svc' cannot be
activated due to an exception during
compilation. The exception message
is: IIS specified authentication
schemes
'IntegratedWindowsAuthentication,
Anonymous', but the binding only
supports specification of exactly one
authentication scheme. Valid
authentication schemes are Digest,
Negotiate, NTLM, Basic, or Anonymous.
Change the IIS settings so that only a
single authentication scheme is
used..]
System.ServiceModel.AsyncResult.End(IAsyncResult
result) +11599786
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult
result) +194
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.ExecuteSynchronous(HttpApplication
context, Boolean flowContext) +176
System.ServiceModel.Activation.HttpModule.ProcessRequest(Object
sender, EventArgs e) +278
System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
+68 System.Web.HttpApplication.ExecuteStep(IExecutionStep
step, Boolean& completedSynchronously)
+75

Version Information: Microsoft .NET
Framework Version:2.0.50727.3615;
ASP.NET Version:2.0.50727.3618

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

极致的悲 2024-10-30 22:14:36

根据上面的错误,您有 在 Windows 2003 计算机上配置 IIS 身份验证,以允许两种不同类型的身份验证(集成和匿名)。将其更改为一种身份验证类型 - 与您的 WCF 配置相匹配的身份验证类型。我猜您只想在 IIS 配置中启用匿名(而不是集成),但这是您的设计选择。

According to your error above, you have IIS authentication configured on your Windows 2003 machine to allow two different types of authentication (integrated & anonymous). Change it to one type of authentication - the one that matches your WCF configuration. I'm guessing you only want anonymous (and not integrated) enabled in the IIS configuration, but that's your design choice..

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文