0006-00000209

更新时间:
复制 MD 格式

Problem description

A PostObject request fails because the policy form field is missing the required expiration and conditions fields.

Causes

The policy form field must always contain both expiration and conditions. A PostObject request that includes a policy without these two fields is malformed and returns a request error.

Examples

The following policy value triggers the error — it is valid JSON but omits both required fields:

{

}

Solutions

Add both expiration and conditions to the policy form field. The expiration field sets when the policy expires (ISO 8601 format), and conditions is an array of upload constraints.

{
    "expiration": "2023-02-19T13:19:00.000Z",
    "conditions": [
        ["content-length-range", 0, 1048576000]
    ]
}

References