Articles → AWS → CORS In AWS S3
CORS In AWS S3
What Is CORS?
Why Do We Need To Enable CORS In S3?
CORS JSON
[
{
"AllowedHeaders": [
"*"
],
"AllowedMethods": [
"PUT",
"POST",
"DELETE"
],
"AllowedOrigins": [
"http://www.example1.com"
],
"ExposeHeaders": []
},
….
]
- AllowedHeaders → This attribute specifies which headers are allowed in preflight CORS requests. The preflight CORS request checks if the CORS protocol is understood between the website and the resource on the other domain
- AllowedMethods → This attribute specifies which HTTP methods are allowed while performing the HTTP request
- AllowedOrigins → This attribute specifies the domain where the resource is stored
- ExposeHeaders → This attribute specifies which headers are exposed to the client in the HTTP response
How To Enable CORS In S3?
Click to Enlarge
Click to Enlarge
Click to Enlarge