1
通信にhttps、応答形式にjsonを使用しているWCFサービスがあります。私の方法を誰にでも利用できるようにしたいので、IISの認証を匿名の&から基本的なものに変更します。 httpsを介したWCF認証
はこれまでのところ、ブラウザがユーザーのために尋ねるとパスが、私は次のエラーを取得している:WebHttpBindingバインディングとエンドポイントのスキームはhttpに一致するベースアドレスが見つかりませんでした。登録ベースアドレス方式は[https]です。
認証を使用するためにエンドポイントに変更する必要があるのは何ですか?この設定ファイルは私の問題を解決し
<?xml version="1.0"?>
<configuration>
<system.web>
<compilation debug="false" targetFramework="4.0" />
</system.web>
<system.serviceModel>
<bindings>
<webHttpBinding>
<binding name="restBinding">
<security mode="TransportCredentialOnly">
<transport clientCredentialType="Basic" proxyCredentialType="Basic" />
</security>
</binding>
</webHttpBinding>
</bindings>
<services>
<service name="ContactLibrarySecure.ContactLibraryService">
<endpoint address="mex" binding="mexHttpsBinding" bindingConfiguration=""
name="mex" contract="IMetadataExchange" />
<endpoint address="rest" behaviorConfiguration="restBehavior"
binding="webHttpBinding" bindingConfiguration="restBinding"
name="rest" contract="ContactLibrarySecure.IContact" />
<host>
<baseAddresses>
<add baseAddress="https://192.168.1.31/ContactLibrary2.0HTTPS" />
</baseAddresses>
</host>
</service>
</services>
<behaviors>
<endpointBehaviors>
<behavior name="restBehavior">
<webHttp />
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpsGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
</system.serviceModel>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
</configuration>