0002-00000062
Updated at:
Problem description
The signature format is invalid.
Cause
The signature included in the request header is in an invalid format.
Example Problem
You initiated a request that contains a signature in the header. However, the value of the Authorization field is in an invalid format. For example, the Authorization field is missing the colon (:) that separates the AccessKey ID and the signature.
GET /test.txt HTTP/1.0
Date: Tue, 20 Dec 2022 08:48:18 GMT
Host: oss-example.oss-cn-hangzhou.aliyuncs.com
Authorization: OSS qn6q**************:77Dv****************
Solution
Calculate the value of the Authorization field as follows:
Authorization = "OSS " + AccessKeyId + ":" + Signature
Signature = base64(hmac-sha1(AccessKeySecret,
VERB + "\n"
+ Content-MD5 + "\n"
+ Content-Type + "\n"
+ Date + "\n"
+ CanonicalizedOSSHeaders
+ CanonicalizedResource))
For more information about how to calculate the value of the Authorization field, see Include signatures in the Authorization header.
Note
You can use an SDK to send requests. SDKs automatically sign your requests. For more information, see Use Alibaba Cloud SDKs to initiate requests.
Is this page helpful?