0005-00000230

更新时间:
复制 MD 格式

Problem description

Your request failed because the x-oss-server-side-encryption-context header contains an invalid encryption context.

Causes

The value of x-oss-server-side-encryption-context must be a valid JSON string. OSS rejects the request if the value is not a valid JSON string.

Valid format:

{"key": "value"}

Invalid format:

test encryption context parameter

For the full requirements for the encryption context, see EncryptionContext.

Examples

When test encryption context parameter is passed as the value of the x-oss-server-side-encryption-context header, OSS denies the request because the value is a plain string, not a valid JSON string.

Solutions

  1. Check the value you passed in x-oss-server-side-encryption-context.

  2. Replace it with a valid JSON string. For example:

    {"purpose": "data-protection"}
  3. Resubmit the request.

    If the request still fails, see EncryptionContext for all parameter constraints.