この質問は重複している可能性があります。クライアントが特定のファイルをサーバーにアップロードするWCFアップロードサービスがあります。
サービスを通じて12MBのサイズのファイルを正常に送信できました。
これで、自己認証SSL証明書をWCFサービスに統合しました。SSLなしで正常に動作していた同じアプリケーションが、リモートサーバーがエラー(413)要求エンティティが大きすぎることを返すというエラーを返すようになりました。
このエラーを修正するにはどうすればよいですか?これはSSLと関係がありますか?
どこが間違っているのか。
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="customHttpBinding" openTimeout="00:10:00" sendTimeout="00:10:00"
maxReceivedMessageSize="10067108864"
messageEncoding="Mtom" transferMode="Streamed">
<security mode="Transport">
<transport clientCredentialType="Certificate" />
</security>
</binding>
</basicHttpBinding>
</bindings>
<behaviors>
<serviceBehaviors>
<behavior name="customServiceBehavior">
<serviceMetadata httpsGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="true"/>
<serviceCredentials>
<clientCertificate>
<authentication certificateValidationMode="PeerOrChainTrust" trustedStoreLocation="LocalMachine"/>
</clientCertificate>
</serviceCredentials>
</behavior>
</serviceBehaviors>
</behaviors>
<services>
<service behaviorConfiguration="customServiceBehavior" name="FileTransferService">
<endpoint address="" binding="basicHttpBinding" bindingConfiguration="customHttpBinding"
contract="IFileTransferService" />
</service>
</services>
ありがとう