1

我正在为我的上传服务使用下面的绑定配置,

<binding name="FileUploadSTSBinding">
          <security authenticationMode="UserNameOverTransport"
                    requireDerivedKeys="false"
                    keyEntropyMode="ServerEntropy"
                    requireSecurityContextCancellation="false"
                    requireSignatureConfirmation="false">
          </security>
          <mtomMessageEncoding/>
          <httpsTransport 
            transferMode="Streamed" 
            maxReceivedMessageSize="2147483647"/>
        </binding>

但是使用此设置,我无法上传超过 1mb 的大文件,服务器响应是错误请求。

有什么想法吗?

4

1 回答 1

0

您还需要设置 maxRequestLength 属性才能进行上传。它可以在这里的 web.config 文件中找到:

<configuration>
   <system.web>
      <httpRuntime>

检查 IIS 应用程序池标识是否有权写入临时文件夹,以便能够临时存储传入数据。

于 2010-10-08T06:22:48.750 回答