开发者社区> 问答> 正文

批量删除时身份验证失败,求解答啊


做批量删除,添加Content-MD5内容之后,一直返回这个错误,实在误解,求各位解答。
ACCESS_ID: 84wb5aoz2hkfvw7raqbuvafd
ACCESS_KEY: uFEwAT8H4AbrC5KKPDCxsjHC9pI=



Content-MD5 生成方式如下:
MD5CryptoServiceProvider md5 = new MD5CryptoServiceProvider();
             byte[] hash = md5.ComputeHash(this._content);
             this._content.Position = 0;
             md5.Clear();
             this._contentMd5 = Convert.ToBase64String(hash, Base64FormattingOptions.None);


发送内容如下:
POST /thinkcity?delete HTTP/1.1
Date: Sun, 07 Oct 2012 12:56:23 GMT
Content-Type:
Content-MD5: ZdjlNT4JzRvLFHTKwtuIEg==
Authorization: OSS 84wb5aoz2hkfvw7raqbuvafd:aMa2sTvy s8iCR6loSxTMEpifdA=
User-Agent: aliyun-openservices-sdk-dotnet_0.0.0.0
Host: storage.aliyun.com
Content-Length: 87

<Delete><Quiet>true</Quiet><Object><Key>1.76榫嶆棌浼犲.rar</Key></Object></Delete>


返回错误如下:
<?xml version="1.0" encoding="UTF-8"?>
<Error>
  <Code>SignatureDoesNotMatch</Code>
  <Message>The request signature we calculated does not match the signature you provided. Check your key and signing method.</Message>
  <StringToSignBytes>50 4F 53 54 0A 5A 64 6A 6C 4E 54 34 4A 7A 52 76 4C 46 48 54 4B 77 74 75 49 45 67 3D 3D 0A 0A 53 75 6E 2C 20 30 37 20 4F 63 74 20 32 30 31 32 20 31 32 3A 35 36 3A 32 33 20 47 4D 54 0A 2F 74 68 69 6E 6B 63 69 74 79 3F 64 65 6C 65 74 65 </StringToSignBytes>
  <SignatureProvided>aMa2sTvy s8iCR6loSxTMEpifdA=</SignatureProvided>
  <StringToSign>POST ZdjlNT4JzRvLFHTKwtuIEg==  Sun, 07 Oct 2012 12:56:23 GMT /thinkcity?delete</StringToSign>
  <OSSAccessKeyId>84wb5aoz2hkfvw7raqbuvafd</OSSAccessKeyId>
  <RequestId>50717BF6ACD33BD244118D20</RequestId>
  <HostId>storage.aliyun.com</HostId>
</Error>

展开
收起
siceblue 2012-10-07 21:10:57 9302 0
1 条回答
写回答
取消 提交回答
  • Re批量删除时身份验证失败,求解答啊
    依然没有人回答???在线等啊
    2012-10-08 11:18:52
    赞同 展开评论 打赏
问答分类:
问答地址:
问答排行榜
最热
最新

相关电子书

更多
安全机制与User账户身份验证实战 立即下载
低代码开发师(初级)实战教程 立即下载
阿里巴巴DevOps 最佳实践手册 立即下载