Add WCF Service reference fails. And VS2008 exits
I have a super-simple WCF Service. I host it on my local machine using IIS7.

When I add a service reference to my service, Visual Studio tells me there was an error. I can click a Details link, and that bring up a dialog box saying: Object reference not set to an instance of an object. 

I can build my WCF service with no problems, and my client app also builds successfully.

I can even use svcutil http://localhost/logservice/logservice.svc?wsdl to generate a client.

I've seen this error in my Windows Event Log/Viewer:

.NET Runtime version 2.0.50727.3053 - Fatal Execution Engine Error (706B7706) (80131506)

I found a hotfix online, but that won't install...

I think this has something to do with the client solution from where I add the service reference. I can add a service refenrece using the the "Discover services in solution" function. I just need to add a service reference in a solution elsewhere, so this is driving me nuts.

My WSDL looks as follows:

      <?xml version="1.0" encoding="utf-8" ?> 
- <wsdl:definitions name="LogService" targetNamespace="http://tempuri.org/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" xmlns:tns="http://tempuri.org/" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsap="http://schemas.xmlsoap.org/ws/2004/08/addressing/policy" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msc="http://schemas.microsoft.com/ws/2005/12/wsdl/contract" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:wsa10="http://www.w3.org/2005/08/addressing" xmlns:wsx="http://schemas.xmlsoap.org/ws/2004/09/mex">
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
- <sp:ProtectionToken>
- <wsp:Policy>
- <sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
- <wsp:Policy>
  <sp:RequireDerivedKeys /> 
- <sp:BootstrapPolicy>
- <wsp:Policy>
- <sp:SignedParts>
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts>
  <sp:Body /> 
  </sp:EncryptedParts>
- <sp:SymmetricBinding>
- <wsp:Policy>
- <sp:ProtectionToken>
- <wsp:Policy>
- <sp:SpnegoContextToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
- <wsp:Policy>
  <sp:RequireDerivedKeys /> 
  </wsp:Policy>
  </sp:SpnegoContextToken>
  </wsp:Policy>
  </sp:ProtectionToken>
- <sp:AlgorithmSuite>
- <wsp:Policy>
  <sp:Basic256 /> 
  </wsp:Policy>
  </sp:AlgorithmSuite>
- <sp:Layout>
- <wsp:Policy>
  <sp:Strict /> 
  </wsp:Policy>
  </sp:Layout>
  <sp:IncludeTimestamp /> 
  <sp:EncryptSignature /> 
  <sp:OnlySignEntireHeadersAndBody /> 
  </wsp:Policy>
  </sp:SymmetricBinding>
- <sp:Wss11>
- <wsp:Policy>
  <sp:MustSupportRefKeyIdentifier /> 
  <sp:MustSupportRefIssuerSerial /> 
  <sp:MustSupportRefThumbprint /> 
  <sp:MustSupportRefEncryptedKey /> 
  </wsp:Policy>
  </sp:Wss11>
- <sp:Trust10>
- <wsp:Policy>
  <sp:MustSupportIssuedTokens /> 
  <sp:RequireClientEntropy /> 
  <sp:RequireServerEntropy /> 
  </wsp:Policy>
  </sp:Trust10>
  </wsp:Policy>
  </sp:BootstrapPolicy>
  </wsp:Policy>
  </sp:SecureConversationToken>
  </wsp:Policy>
  </sp:ProtectionToken>
- <sp:AlgorithmSuite>
- <wsp:Policy>
  <sp:Basic256 /> 
  </wsp:Policy>
  </sp:AlgorithmSuite>
- <sp:Layout>
- <wsp:Policy>
  <sp:Strict /> 
  </wsp:Policy>
  </sp:Layout>
  <sp:IncludeTimestamp /> 
  <sp:EncryptSignature /> 
  <sp:OnlySignEntireHeadersAndBody /> 
  </wsp:Policy>
  </sp:SymmetricBinding>
- <sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
  <sp:MustSupportRefKeyIdentifier /> 
  <sp:MustSupportRefIssuerSerial /> 
  <sp:MustSupportRefThumbprint /> 
  <sp:MustSupportRefEncryptedKey /> 
  </wsp:Policy>
  </sp:Wss11>
- <sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
  <sp:MustSupportIssuedTokens /> 
  <sp:RequireClientEntropy /> 
  <sp:RequireServerEntropy /> 
  </wsp:Policy>
  </sp:Trust10>
  <wsaw:UsingAddressing /> 
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorSimple_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorSimple_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorAdvanced_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorAdvanced_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogBehavior_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogBehavior_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsdl:types>
- <xsd:schema targetNamespace="http://tempuri.org/Imports">
  <xsd:import schemaLocation="http://yakinix.admin/LogService.svc?xsd=xsd0" namespace="http://tempuri.org/" /> 
  <xsd:import schemaLocation="http://yakinix.admin/LogService.svc?xsd=xsd1" namespace="http://schemas.microsoft.com/2003/10/Serialization/" /> 
  </xsd:schema>
  </wsdl:types>
- <wsdl:message name="ILogService_LogErrorSimple_InputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorSimple" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorSimple_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorSimpleResponse" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorAdvanced_InputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorAdvanced" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorAdvanced_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorAdvancedResponse" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogBehavior_InputMessage">
  <wsdl:part name="parameters" element="tns:LogBehavior" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogBehavior_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogBehaviorResponse" /> 
  </wsdl:message>
- <wsdl:portType name="ILogService">
- <wsdl:operation name="LogErrorSimple">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogErrorSimple" message="tns:ILogService_LogErrorSimple_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogErrorSimpleResponse" message="tns:ILogService_LogErrorSimple_OutputMessage" /> 
  </wsdl:operation>
- <wsdl:operation name="LogErrorAdvanced">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogErrorAdvanced" message="tns:ILogService_LogErrorAdvanced_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogErrorAdvancedResponse" message="tns:ILogService_LogErrorAdvanced_OutputMessage" /> 
  </wsdl:operation>
- <wsdl:operation name="LogBehavior">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogBehavior" message="tns:ILogService_LogBehavior_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogBehaviorResponse" message="tns:ILogService_LogBehavior_OutputMessage" /> 
  </wsdl:operation>
  </wsdl:portType>
- <wsdl:binding name="WSHttpBinding_ILogService" type="tns:ILogService">
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_policy" /> 
  <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" /> 
- <wsdl:operation name="LogErrorSimple">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogErrorSimple" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorSimple_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorSimple_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
- <wsdl:operation name="LogErrorAdvanced">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogErrorAdvanced" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorAdvanced_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorAdvanced_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
- <wsdl:operation name="LogBehavior">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogBehavior" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogBehavior_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogBehavior_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
  </wsdl:binding>
- <wsdl:service name="LogService">
- <wsdl:port name="WSHttpBinding_ILogService" binding="tns:WSHttpBinding_ILogService">
  <soap12:address location="http://yakinix.admin/LogService.svc" /> 
- <wsa10:EndpointReference>
  <wsa10:Address>http://yakinix.admin/LogService.svc</wsa10:Address> 
- <Identity xmlns="http://schemas.xmlsoap.org/ws/2006/02/addressingidentity">
  <Dns>localhost</Dns> 
  </Identity>
  </wsa10:EndpointReference>
  </wsdl:port>
  </wsdl:service>
  </wsdl:definitions>

My system.serviceModel of web.config looks as follows:

      <system.serviceModel>
    <services>
      <service behaviorConfiguration="LogServiceBehavior" name="LogService">
        <endpoint address="" binding="wsHttpBinding" contract="ILogService">
          <identity>
						<dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="LogServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="true" />
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>
Add WCF Service reference fails. And VS2008 exits
===

I have a super-simple WCF Service. I host it on my local machine using IIS7.

When I add a service reference to my service, Visual Studio tells me there was an error. I can click a Details link, and that bring up a dialog box saying: Object reference not set to an instance of an object. 

I can build my WCF service with no problems, and my client app also builds successfully.

I can even use svcutil http://localhost/logservice/logservice.svc?wsdl to generate a client.

I've seen this error in my Windows Event Log/Viewer:

.NET Runtime version 2.0.50727.3053 - Fatal Execution Engine Error (706B7706) (80131506)

I found a hotfix online, but that won't install...

I think this has something to do with the client solution from where I add the service reference. I can add a service refenrece using the the "Discover services in solution" function. I just need to add a service reference in a solution elsewhere, so this is driving me nuts.

My WSDL looks as follows:

      <?xml version="1.0" encoding="utf-8" ?> 
- <wsdl:definitions name="LogService" targetNamespace="http://tempuri.org/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" xmlns:tns="http://tempuri.org/" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsap="http://schemas.xmlsoap.org/ws/2004/08/addressing/policy" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msc="http://schemas.microsoft.com/ws/2005/12/wsdl/contract" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:wsa10="http://www.w3.org/2005/08/addressing" xmlns:wsx="http://schemas.xmlsoap.org/ws/2004/09/mex">
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
- <sp:ProtectionToken>
- <wsp:Policy>
- <sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
- <wsp:Policy>
  <sp:RequireDerivedKeys /> 
- <sp:BootstrapPolicy>
- <wsp:Policy>
- <sp:SignedParts>
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts>
  <sp:Body /> 
  </sp:EncryptedParts>
- <sp:SymmetricBinding>
- <wsp:Policy>
- <sp:ProtectionToken>
- <wsp:Policy>
- <sp:SpnegoContextToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
- <wsp:Policy>
  <sp:RequireDerivedKeys /> 
  </wsp:Policy>
  </sp:SpnegoContextToken>
  </wsp:Policy>
  </sp:ProtectionToken>
- <sp:AlgorithmSuite>
- <wsp:Policy>
  <sp:Basic256 /> 
  </wsp:Policy>
  </sp:AlgorithmSuite>
- <sp:Layout>
- <wsp:Policy>
  <sp:Strict /> 
  </wsp:Policy>
  </sp:Layout>
  <sp:IncludeTimestamp /> 
  <sp:EncryptSignature /> 
  <sp:OnlySignEntireHeadersAndBody /> 
  </wsp:Policy>
  </sp:SymmetricBinding>
- <sp:Wss11>
- <wsp:Policy>
  <sp:MustSupportRefKeyIdentifier /> 
  <sp:MustSupportRefIssuerSerial /> 
  <sp:MustSupportRefThumbprint /> 
  <sp:MustSupportRefEncryptedKey /> 
  </wsp:Policy>
  </sp:Wss11>
- <sp:Trust10>
- <wsp:Policy>
  <sp:MustSupportIssuedTokens /> 
  <sp:RequireClientEntropy /> 
  <sp:RequireServerEntropy /> 
  </wsp:Policy>
  </sp:Trust10>
  </wsp:Policy>
  </sp:BootstrapPolicy>
  </wsp:Policy>
  </sp:SecureConversationToken>
  </wsp:Policy>
  </sp:ProtectionToken>
- <sp:AlgorithmSuite>
- <wsp:Policy>
  <sp:Basic256 /> 
  </wsp:Policy>
  </sp:AlgorithmSuite>
- <sp:Layout>
- <wsp:Policy>
  <sp:Strict /> 
  </wsp:Policy>
  </sp:Layout>
  <sp:IncludeTimestamp /> 
  <sp:EncryptSignature /> 
  <sp:OnlySignEntireHeadersAndBody /> 
  </wsp:Policy>
  </sp:SymmetricBinding>
- <sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
  <sp:MustSupportRefKeyIdentifier /> 
  <sp:MustSupportRefIssuerSerial /> 
  <sp:MustSupportRefThumbprint /> 
  <sp:MustSupportRefEncryptedKey /> 
  </wsp:Policy>
  </sp:Wss11>
- <sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
- <wsp:Policy>
  <sp:MustSupportIssuedTokens /> 
  <sp:RequireClientEntropy /> 
  <sp:RequireServerEntropy /> 
  </wsp:Policy>
  </sp:Trust10>
  <wsaw:UsingAddressing /> 
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorSimple_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorSimple_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorAdvanced_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogErrorAdvanced_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogBehavior_Input_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsp:Policy wsu:Id="WSHttpBinding_ILogService_LogBehavior_output_policy">
- <wsp:ExactlyOne>
- <wsp:All>
- <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing" /> 
  <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing" /> 
  </sp:SignedParts>
- <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
  <sp:Body /> 
  </sp:EncryptedParts>
  </wsp:All>
  </wsp:ExactlyOne>
  </wsp:Policy>
- <wsdl:types>
- <xsd:schema targetNamespace="http://tempuri.org/Imports">
  <xsd:import schemaLocation="http://yakinix.admin/LogService.svc?xsd=xsd0" namespace="http://tempuri.org/" /> 
  <xsd:import schemaLocation="http://yakinix.admin/LogService.svc?xsd=xsd1" namespace="http://schemas.microsoft.com/2003/10/Serialization/" /> 
  </xsd:schema>
  </wsdl:types>
- <wsdl:message name="ILogService_LogErrorSimple_InputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorSimple" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorSimple_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorSimpleResponse" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorAdvanced_InputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorAdvanced" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogErrorAdvanced_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogErrorAdvancedResponse" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogBehavior_InputMessage">
  <wsdl:part name="parameters" element="tns:LogBehavior" /> 
  </wsdl:message>
- <wsdl:message name="ILogService_LogBehavior_OutputMessage">
  <wsdl:part name="parameters" element="tns:LogBehaviorResponse" /> 
  </wsdl:message>
- <wsdl:portType name="ILogService">
- <wsdl:operation name="LogErrorSimple">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogErrorSimple" message="tns:ILogService_LogErrorSimple_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogErrorSimpleResponse" message="tns:ILogService_LogErrorSimple_OutputMessage" /> 
  </wsdl:operation>
- <wsdl:operation name="LogErrorAdvanced">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogErrorAdvanced" message="tns:ILogService_LogErrorAdvanced_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogErrorAdvancedResponse" message="tns:ILogService_LogErrorAdvanced_OutputMessage" /> 
  </wsdl:operation>
- <wsdl:operation name="LogBehavior">
  <wsdl:input wsaw:Action="http://tempuri.org/ILogService/LogBehavior" message="tns:ILogService_LogBehavior_InputMessage" /> 
  <wsdl:output wsaw:Action="http://tempuri.org/ILogService/LogBehaviorResponse" message="tns:ILogService_LogBehavior_OutputMessage" /> 
  </wsdl:operation>
  </wsdl:portType>
- <wsdl:binding name="WSHttpBinding_ILogService" type="tns:ILogService">
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_policy" /> 
  <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" /> 
- <wsdl:operation name="LogErrorSimple">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogErrorSimple" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorSimple_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorSimple_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
- <wsdl:operation name="LogErrorAdvanced">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogErrorAdvanced" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorAdvanced_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogErrorAdvanced_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
- <wsdl:operation name="LogBehavior">
  <soap12:operation soapAction="http://tempuri.org/ILogService/LogBehavior" style="document" /> 
- <wsdl:input>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogBehavior_Input_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:input>
- <wsdl:output>
  <wsp:PolicyReference URI="#WSHttpBinding_ILogService_LogBehavior_output_policy" /> 
  <soap12:body use="literal" /> 
  </wsdl:output>
  </wsdl:operation>
  </wsdl:binding>
- <wsdl:service name="LogService">
- <wsdl:port name="WSHttpBinding_ILogService" binding="tns:WSHttpBinding_ILogService">
  <soap12:address location="http://yakinix.admin/LogService.svc" /> 
- <wsa10:EndpointReference>
  <wsa10:Address>http://yakinix.admin/LogService.svc</wsa10:Address> 
- <Identity xmlns="http://schemas.xmlsoap.org/ws/2006/02/addressingidentity">
  <Dns>localhost</Dns> 
  </Identity>
  </wsa10:EndpointReference>
  </wsdl:port>
  </wsdl:service>
  </wsdl:definitions>

My system.serviceModel of web.config looks as follows:

      <system.serviceModel>
    <services>
      <service behaviorConfiguration="LogServiceBehavior" name="LogService">
        <endpoint address="" binding="wsHttpBinding" contract="ILogService">
          <identity>
						<dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="LogServiceBehavior">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="true" />
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>