Problem description
A form field referenced in the conditions parameter of the Post policy does not exist in the PostObject request body.
Causes
Each condition in the conditions parameter acts as a validation rule: OSS checks that the specified form field exists in the request body and matches the required value. If the form field is missing from the request body, the request fails.
Examples
The following policy uses an eq condition to require that success_action_status equals 200. This means the request body must include a form field named success_action_status with the value 200. If that form field is absent, OSS returns an error.
{
"expiration": "2023-02-19T13:19:00.000Z",
"conditions": [
["eq", "success_action_status", "200"]
]
}Solutions
Make sure every form field referenced in the conditions parameter is included in the PostObject request body.
References
For details about the policy form field, see Appendix: Policy.
To learn how to upload data from a web client using form upload, see Add signatures on the client by using JavaScript and upload data to OSS.
For a full list of PostObject errors and how to resolve them, see Errors and troubleshooting methods of PostObject.