3 ms·
CRSF is not an issue for JSON API endpoints, since cross-origin requests are disabled by default. XSS in my experience is best solved by a reasonable templatin
by klodolph 8y ago
CRSF is not an issue for JSON API endpoints, since cross-origin requests are disabled by default.
XSS in my experience is best solved by a reasonable templating language. The same way you don't use string concatenation to insert user data into HTML documents, you don't use string concatenation to insert user data into SQL queries. Frameworks don't add anything here that you don't already have, and a lot of frameworks let you choose your templating system anyway.
This was a big reason to use frameworks in past days, though.