In S3 Bucket CORS Configrations not allowing "XML" and asking for "Json" instead
<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
<AllowedMethod>POST</AllowedMethod>
<AllowedMethod>PUT</AllowedMethod>
<AllowedHeader>*</AllowedHeader>
</CORSRule>
</CORSConfiguration>
Was Working earlier but now it is giving me this error "The CORS configuration must be written in valid JSON." Some Changes are made in "Amazon S3 Bucket" by AMAZON , Please give me json of this to add in CORS ?
In the new S3 console, the CORS configuration must be JSON. Read more here.
In your case, the JSON CORS configuration can be written as follow:
[
{
"AllowedHeaders": [
"*"
],
"AllowedMethods": [
"POST",
"GET",
"PUT"
],
"AllowedOrigins": [
"*"
]
}
]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With