0

我正在尝试将 Windows 身份验证用于一项服务,并且已经阅读了几篇文章,只是说我需要添加

httpTransport = authenticationScheme="Negotiate"

但是我只收到消息“未声明 authenicationScheme 属性”

任何人都可以解释我是如何找到这个的,或者是否有另一种方法可以将 Windows 身份验证提供给自定义服务。

<customBinding>
            <binding name="CustomBinding_AFDiscoveryService">
                <binaryMessageEncoding />
                <httpTransport  authenticationScheme="Negotiate" maxReceivedMessageSize="2147483647" maxBufferSize="2147483647" />
              </binding>
        </customBinding>

非常感谢

克里斯

4

1 回答 1

0

那应该工作得很好。你从哪里得到这个消息?

<system.serviceModel>
    <bindings>
        <customBinding>
            <binding name="CustomBinding_AFDiscoveryService">
                <binaryMessageEncoding />
                <httpTransport  authenticationScheme="Negotiate" maxReceivedMessageSize="2147483647" maxBufferSize="2147483647" />
            </binding>
        </customBinding>
    </bindings>
    <services>
        <service name="Host.Service1">
            <endpoint address="" binding="customBinding" bindingConfiguration="CustomBinding_AFDiscoveryService" contract="Host.IService1">
                <identity>
                    <dns value="localhost" />
                </identity>
            </endpoint>
            <host>
                <baseAddresses>
                    <add baseAddress="http://localhost:8732/Design_Time_Addresses/Host/Service1/" />
                </baseAddresses>
            </host>
        </service>
    </services>
</system.serviceModel>
于 2012-06-22T18:17:31.843 回答