Click here to Skip to main content
15,887,135 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Please any one Help me.


Error Response from Web Server for Https:
Works Fine with Http:

XML
<Fault xmlns="http://schemas.microsoft.com/ws/2005/05/envelope/none">
- <Code>
  <Value>Sender</Value>
- <Subcode>
  <Value xmlns:a="http://schemas.microsoft.com/ws/2005/05/addressing/none">a:ActionNotSupported</Value>
  </Subcode>
  </Code>
- <Reason>
  <Text xml:lang="en-US">The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver. Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Message, Transport, None).</Text>
  </Reason>
  </Fault>



Web Config:

XML
<system.serviceModel>
   <bindings>
     <webHttpBinding>
       <binding name="webBinding">
         <security mode="Transport">
         </security>
       </binding>
     </webHttpBinding>
   </bindings>

   <services>
     <service name="MyService" behaviorConfiguration="BehConfig">
       <endpoint contract="IMyService" address="" binding="webHttpBinding" bindingConfiguration="webBinding" />



     </service>
   </services>




   <behaviors>
     <serviceBehaviors>
       <behavior name="BehConfig">

         <serviceMetadata httpsGetEnabled="true"/>
         <serviceDebug includeExceptionDetailInFaults="false"/>
       </behavior>
     </serviceBehaviors>

   </behaviors>
   <serviceHostingEnvironment multipleSiteBindingsEnabled="true"/>
 </system.serviceModel>
Posted
Updated 29-Jun-14 21:12pm
v4
Comments
Kornfeld Eliyahu Peter 1-Jul-14 9:48am    
It seems you have no SSL enabled on your IIS...
Sivachandran R 2-Jul-14 5:27am    
I have fixed it thank you

XML
<endpoint kind="webHttpEndpoint" binding="webHttpBinding" bindingConfiguration="wsBinding" contract="SS_Rest.ITestSOA" />
 
Share this answer
 
v3
Comments
thearultvr 8-May-18 8:48am    
thanks

kind="webHttpEndpoint"
Solution For Https:

XML
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.web>
<compilation debug="true" strict="false" explicit="true" targetFramework="4.0" />
<httpRuntime maxUrlLength="500" />
</system.web>
 <appSettings>
 <add key="Constr" value="Data Source=YourConnection" />
 </appSettings>
<system.serviceModel>
<services>
<service name="MyService">
    <endpoint address="" binding="webHttpBinding" bindingConfiguration="secureHttpBinding" contract="IMyService" behaviorConfiguration="web"  /> </service> </services> <bindings><webHttpBinding><binding name="secureHttpBinding" >
<security mode="Transport">
<transport clientCredentialType="None" />
</security>
</binding>
</webHttpBinding>
</bindings>
<behaviors>
<endpointBehaviors>
 <behavior name="web">
   <webHttp/>
 </behavior>
</endpointBehaviors>
<serviceBehaviors>
 <behavior>
<!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment --> <serviceMetadata httpsGetEnabled="true" httpGetEnabled="false" />
<serviceDebug includeExceptionDetailInFaults="false" /> </behavior>
</serviceBehaviors>
 </behaviors>
 <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
</system.serviceModel>
 <system.webServer> <modules runAllManagedModulesForAllRequests="true" />
 <httpRedirect enabled="false" />
</system.webServer>
</configuration>
 
Share this answer
 
v2
For Http:

XML
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <system.web>
    <compilation debug="true" strict="false" explicit="true" targetFramework="4.0" />
    <httpRuntime />
    <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID" />
  </system.web>
  <appSettings>
    <!--<add key="Constr" value="Data Source=;Initial Catalog=;User ID=;Password="/>-->
    <add key="Constr" value="YourConnection" />
  </appSettings>
  <system.serviceModel>
    <services>
      <service name="MyService" behaviorConfiguration="BehConfig">
        <endpoint address="" binding="webHttpBinding" contract="IMyService " behaviorConfiguration="web" />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="BehConfig">
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="false" />
        </behavior>
      </serviceBehaviors>
      <endpointBehaviors>
        <behavior name="web">
          <webHttp />
        </behavior>
      </endpointBehaviors>
    </behaviors>
    <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
  </system.serviceModel>
  <system.webServer>
    <modules runAllManagedModulesForAllRequests="true" />
    <!--
        To browse web app root directory during debugging, set the value below to true.
        Set to false before deployment to avoid disclosing web app folder information.
      -->
    <directoryBrowse enabled="true" />
        <httpRedirect enabled="false" />
  </system.webServer>
</configuration>
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900