OOmnistu

Blog / Engineering Playbooks

Engineering Playbooks

Node.js app security: a checklist from OWASP's guidance

Review Node.js request limits, asynchronous errors, permissions, headers and dependencies without treating runtime controls as a sandbox.

OOmnistu
Reviewed 2026-11-16 · 4 min read

OWASP's NodeJS Security Cheat Sheet says Node.js apps are prone to the same web vulnerabilities as other frameworks and groups its advice under application security, error and exception handling, server security and platform security. We read all of its text on 15 November 2026. We skimmed its code samples without running them and did not read the Node.js and Express pages it links. Everything attributed is OWASP's. Module names appear only because the sheet names them, and we do not endorse them. Versions and flags are the sheet's statements; check the current Node.js documentation before relying on them.

Application security

Permissions

The sheet says a Permission Model exists from Node.js 20, is stable from 23.5.0 (also backported to22.13.0 per the official documentation), and is turned on with the --permission flag, with separate allow flags for file reads, file writes, child processes, workers, native addons and WASI. Its warning: symbolic links are followed even when they point outside the allowed paths, so avoid relative symlinks inside allowed paths. The current official documentation (https://nodejs.org/api/permissions.html) calls it a seat belt for trusted code, not a sandbox or protection against malicious code. Available permissions differ by release; use your deployed release's documentation.

Errors and exceptions

Handle uncaughtException by cleaning up, logging and exiting, so the process does not continue in an unknown state. Listen for error events on emitters. In asynchronous callbacks, pass an Error as the first argument and propagate it; callback failures must be routed to the framework's error handler. Promise rejection handling depends on the Express version and handler style; do not assume all asynchronous errors are caught automatically.

Server security

Platform security

Questions for your team

Related: REST API security checklist, error handling without leaking details, XSS prevention for app teams, vulnerable dependencies.

Limits

One OWASP page, text read in full; code samples skimmed and untested; linked pages unread. Node.js version statements and module names reflect the sheet on the fetch date and may be out of date. We give no code and no statistics. Not every item applies to every app.

By Omnistu.

Sources

Previous
How to test a mobile app before launch: a practical plan