All Products
Search
Document Center

Object Storage Service:0002-00000418

Last Updated:Apr 15, 2025

Problem description

The signature included in the request URL expires.

Causes

The V4 signature that is compatible with Amazon S3 is used in the request. However, the signature expires.

Examples

The signature is specified by the parameter in the URL of a request. However, the time when the request is received by OSS exceeds the timeout period specified by the X-Amz-Date and X-Amz-Expires parameters in the request.

GET /test.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=LTAI****************/20221220/us-east-1/s3/aws4_request&X-Amz-Date=20221220T084818Z86400&X-Amz-Expires=86400&X-Amz-SignedHeaders=host&X-Amz-Signature=ab2***st HTTP/1.0
Date: Tue, 20 Dec 2022 08:48:18 GMT
Host: oss-example.oss-cn-hangzhou.aliyuncs.com
x-oss-s3-compat: true
  • The X-Amz-Expires parameter specifies the expiration time of a signed request URL. The value must be a UNIX timestamp that ranges from 0 to 604800.

  • The X-Amz-Date parameter specifies the time when the client initiates a signed URL.

If the time when the request is received by OSS exceeds the timeout period specified by the X-Amz-Date and X-Amz-Expires parameters in the URL, the signed URL expires.

Solutions

Regenerate a signed URL. When you regenerate a signed URL, we recommend that you adjust the value of the X-Amz-Expires parameter to specify a longer validity period for the signed URL.

We recommend that you use Amazon S3 SDKs to initiate the request. For more information, see Use Amazon S3 SDKs to access OSS.