Networking III: origins, CORS and cookies across sites
Explain the same-origin policy and CORS precisely.
- WEB.14.01Same-origin policy, sites and originsCoreMid-level10 min
- WEB.14.02CORS in depthCoreMid-level12 min
Interview questions in this module
- What is the same-origin policy?
- What is CORS and what triggers a preflight request?
- Why does my request work in Postman/curl but fail in the browser?
- Why can't you use
Access-Control-Allow-Origin: *with cookies? - What is the difference between same-origin and same-site?