WCF http & hhtps endpoint one contract
Posted
by Andrew Kalashnikov
on Stack Overflow
See other posts from Stack Overflow
or by Andrew Kalashnikov
Published on 2010-04-05T03:49:29Z
Indexed on
2010/04/05
3:53 UTC
Read the original article
Hit count: 546
Hello colleagues. I've created wcf service and want use http and https version. Service is hosted by IIS 6.0.
At my config I have:
<bindings>
<basicHttpBinding>
<binding name="BindingConfiguration1" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647">
<readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647"
maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647"/>
<security mode="TransportWithMessageCredential">
<transport clientCredentialType="None"/>
<message clientCredentialType="UserName" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<services>
<service name="RegistratorService.Registrator" behaviorConfiguration="RegistratorService.Service1Behavior">
<endpoint binding="basicHttpBinding"
contract="RegistratorService.IRegistrator"
bindingConfiguration="BindingConfiguration1">
<identity>
<dns value="localhost" />
</identity>
</endpoint>
<endpoint binding="basicHttpBinding" contract="RegistratorService.IRegistrator">
<identity>
<dns value="localhost" />
</identity>
</endpoint>
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange"/>
<host>
<baseAddresses>
<add baseAddress="http://aurit-server2" />
</baseAddresses>
</host>
</service>
</services>
But even at browser I've got exception "The provided URI scheme 'http' is invalid; expected 'https'"
What's wrong? Thanks.
© Stack Overflow or respective owner