p5.js-web-editor/server
Andrew Nicolaou 6cbc376d6e CSRF/XSS protection (#374)
* /api endpoints only allows requests with application/json Content-Type

Otherwise sends 406 Unacceptable

* Uses CSRF token

The CSRF token is sent as the cookie 'XSRF-TOKEN' on all HTML page
requests. This token is  picked up automatically by axios
and sent to the API with all requests as an 'X-XSRF-TOKEN' header.
The middleware runs on all routes and verifies that the token matches
what's stored in the session.
2017-06-26 13:58:58 -04:00
..
config Email verification (#369) 2017-06-26 12:48:28 -04:00
controllers change all email links to update protocol based on node env 2017-06-26 13:48:24 -04:00
migrations #339 add region to .env 2017-04-13 14:39:03 -04:00
models Email verification (#369) 2017-06-26 12:48:28 -04:00
routes Email verification (#369) 2017-06-26 12:48:28 -04:00
utils CSRF/XSS protection (#374) 2017-06-26 13:58:58 -04:00
views Email verification (#369) 2017-06-26 12:48:28 -04:00
config.js fix a ton of eslint errors 2016-06-23 18:29:55 -04:00
examples.js fix lingering linting errors 2017-06-13 16:47:36 -04:00
server.js CSRF/XSS protection (#374) 2017-06-26 13:58:58 -04:00