no comments (yet)

sorted by: hot top controversial new old
there doesn't seem to be anything here
9 comments in c/programming@programming.dev view that post
[–] 12 points 4 months ago

When I first learned about CORS, I had trouble understanding it because I couldn't figure out how this protected the server and I couldn't understand why you would do this just for the client 😄

  • source
  • [–] 9 points 4 months ago (1 child)

    One thing to note, CORS only makes sense if your API uses cookies for authentication, most APIs use custom headers, the Authentication header, or even url tokens, they don't rely on cookies, so most of the time, APIs don't care about CORS. People keep blindly repeating that accepting all origins "*", is bad for security, but the situations where this is relevant are really uncommon.

  • source
  • hideshow 1 child comment
  • [–] 29 points 4 months ago* (4 children)

    Absolutely NOTHING! Good God, y'all.

  • source
  • hideshow 4 child comments
  • [–] 1 point 4 months ago

    protecting me from using my fucking browser, most of the time

  • source