Access tapes are sometimes stored in a (secure http-only at best) cookie, so clients donβt need to manually add them to each request: cookies are automatically linked to browser requests. This is the reason that CSRF protection must be implemented.
The article you are linking suggests that clients generate and send the same unique secret value in both the Cookie and the custom HTTP header, which is pretty convenient:
Given that a website is read-only / cookie allowed for its own domain, only a real website can send the same value in both headers.
That is, if, for example, you receive an email with fake graphic targeting http://yourserver.com/admin/deleteAll (and the server processes it through GET ...), a unique secret will not be set in the request header (the old one can do everything still present in the cookie): the server must reject the request.
sp00m source share