🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: CSRF and CORS: all 10 questions

Quiz: CSRF and CORS · Question 9 of 10

What is the dangerous CORS mistake?

What is the dangerous CORS mistake?

  1. A.Allowing only your own frontend origin
  2. B.Reflecting any Origin back in Access-Control-Allow-Origin together with Allow-Credentials: true
  3. C.Not using CORS on a public, cookie-free API
  4. D.Setting SameSite=Lax
Answer & explanation

Correct answer: Reflecting any Origin back in Access-Control-Allow-Origin together with Allow-Credentials: true

That lets any website read logged-in users' data through their browsers.

Can you get the rest right without peeking?

Take the timed Quiz: CSRF and CORS quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →