Link Search Menu Expand Document

Lack of Content Type Headers in Frontend

Play SecureFlag Play Frontend Labs on this vulnerability with SecureFlag!

Node.js

For example, let’s pick Node.js with Express. Setting a Content-Type header correctly ensures that the data exchanged between servers and clients is properly understood and processed.

res.setHeader('Content-Type', 'application/json');