.net WCF服务通过https进行基本身份验证400错误请求/409冲突?
整天都在做这件事,就是想不出我的web.config文件在https上的WCF服务有什么问题。跟踪日志仅说明以下内容: 查找接收传入消息的频道失败。未找到终结点或SOAP操作。.net WCF服务通过https进行基本身份验证400错误请求/409冲突?,.net,wcf,ssl,.net,Wcf,Ssl,整天都在做这件事,就是想不出我的web.config文件在https上的WCF服务有什么问题。跟踪日志仅说明以下内容: 查找接收传入消息的频道失败。未找到终结点或SOAP操作。 <system.serviceModel> <!--SERVICES--> <diagnostics> <messageLogging logMalformedMessages="true" logMessagesAtTransportLevel="t
<system.serviceModel>
<!--SERVICES-->
<diagnostics>
<messageLogging logMalformedMessages="true" logMessagesAtTransportLevel="true" />
<endToEndTracing activityTracing="true" />
</diagnostics>
<services>
<service behaviorConfiguration="MyServiceTypeBehaviors" name="WCF.MyOwnMed.com.iosService1">
<endpoint address="ios" binding="basicHttpBinding" bindingConfiguration="thisBasicHTTPBinding"
name="endpointService1" contract="WCF.MyOwnMed.com.iosIService1" />
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>
</services>
<!--BINDINGS-->
<bindings>
<basicHttpBinding>
<binding name="thisBasicHTTPBinding" maxReceivedMessageSize="5000000" maxBufferPoolSize="5000000">
<readerQuotas maxArrayLength="5000000" />
<security mode="Transport">
<transport clientCredentialType="None" proxyCredentialType="None" realm="" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<!--BEHAVIORS -->
<behaviors>
<serviceBehaviors>
<behavior name="MyServiceTypeBehaviors">
<serviceMetadata httpsGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>
<protocolMapping>
<add binding="basicHttpsBinding" scheme="https" />
</protocolMapping>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
</system.serviceModel>
在所有的“soapAction”属性中使用“http”,这可能是影响它的原因吗?这些是如何生成的?http URI不能与此服务一起使用…此服务是否托管在IIS中?设置表明您有一个证书来验证客户端到服务的身份,这是真的吗?您正在测试的URL是什么?是的,托管在具有IIS的服务器上,并且安装了真实的证书。该证书仅在服务器上?尝试从
元素中删除
元素。按照您的设置方式,web服务器希望客户端使用客户端证书标识自己。您有用于向客户端标识服务器的ssl证书。IIS是否配置为允许基本身份验证?
-<GetAllDiseases>
-<MethodParameters>
-<WebException>
<Status>ProtocolError</Status>
<Response>System.Net.HttpWebResponse</Response>
<Message>The remote server returned an error: (409) Conflict.</Message>
-<Data>
<KeysAndValues attr0="KeyValuePairArray"isNull="false"/>
</Data>
<InnerException isNull="true"/>
<TargetSite>System.Net.WebResponse GetResponse()</TargetSite>
<StackTrace>at System.Net.HttpWebRequest.GetResponse() at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)</StackTrace>
<HelpLink isNull="true"/>
<Source>System</Source>
<HResult>-2146233079</HResult>
</WebException>
</MethodParameters>
</GetAllDiseases>
<E2ETraceEvent xmlns="http://schemas.microsoft.com/2004/06/E2ETraceEvent">
<System xmlns="http://schemas.microsoft.com/2004/06/windows/eventlog/system">
<EventID>262155</EventID>
<Type>3</Type>
<SubType Name="Error">0</SubType>
<Level>2</Level>
<TimeCreated SystemTime="2013-11-05T23:15:05.6916772Z"/>
<Source Name="System.ServiceModel"/>
<Correlation ActivityID="{2c51b91c-3b2b-4fc4-a189-d1e7b72f4034}"/>
<Execution ProcessName="w3wp" ProcessID="3020" ThreadID="7"/>
<Channel/>
<Computer>WEB1</Computer>
</System>
<ApplicationData>
<TraceData>
<DataItem>
<TraceRecord xmlns="http://schemas.microsoft.com/2004/10/E2ETraceEvent/TraceRecord" Severity="Error">
<TraceIdentifier>http://msdn.microsoft.com/en-US/library/System.ServiceModel.Channels.HttpChannelMessageReceiveFailed.aspx</TraceIdentifier>
<Description>Failed to lookup a channel to receive an incoming message. Either the endpoint or the SOAP action was not found.</Description>
<AppDomain>/LM/W3SVC/2/ROOT-9-130281664299064415</AppDomain>
<Source>System.ServiceModel.Activation.HostedHttpTransportManager/33099709</Source>
<ExtendedData xmlns="http://schemas.microsoft.com/2006/08/ServiceModel/StringTraceRecord">
<IsRecycling>False</IsRecycling>
</ExtendedData>
</TraceRecord>
</DataItem>
</TraceData>
</ApplicationData>
</E2ETraceEvent>