Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/221.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android凌空放文件AWS S3签名请求_Android_Amazon S3_Android Volley_Http Status Code 403 - Fatal编程技术网

Android凌空放文件AWS S3签名请求

Android凌空放文件AWS S3签名请求,android,amazon-s3,android-volley,http-status-code-403,Android,Amazon S3,Android Volley,Http Status Code 403,我正在尝试使用一个签名请求,通过截击将一个文件上传到android中的AWS S3 我试图实现,但出现错误403: <Error> <Code>SignatureDoesNotMatch</Code> <Message>The request signature we calculated does not match the signature you provided. Check your key and signing me

我正在尝试使用一个签名请求,通过截击将一个文件上传到android中的AWS S3

我试图实现,但出现错误403:

<Error>
    <Code>SignatureDoesNotMatch</Code>
    <Message>The request signature we calculated does not match the signature you provided. Check your key and signing method.</Message>
    <AWSAccessKeyId>xxx</AWSAccessKeyId>
    <StringToSign>PUT
      x-www-form-urlencoded; charset=UTF-8 <!-- Not wanted parameters -->
      expireTimeStamp
      /my-url
    </StringToSign>
    <SignatureProvided>xxx</SignatureProvided>
    <StringToSignBytes>xxx</StringToSignBytes>
    <RequestId>xxx</RequestId>
    <HostId>xxx</HostId>
</Error>
那么,如何删除
x-www-form-urlencoded;截击请求中的charset=UTF-8

简单地说:

@Override
public String getBodyContentType()
{
    return "";
}
简单地说:

@Override
public String getBodyContentType()
{
    return "";
}
确保在标题中:

内容类型 及 体内

二进制数据: 确保在标题中:

内容类型 及 体内

二进制数据:
我因为这个问题失去了两天的生命。。。谢谢你提供了唯一有效的解决方案,因为这个问题我失去了两天的生命。。。感谢您提供了唯一有效的解决方案