Skip to content
Access control Disclosed report Intermediate CVE-2026-106073

Permission Model bypass with fs.realpathSync

The Node.js Permission Model did not apply read-permission checks to fs.realpathSync(), so code running under --permission with restricted --allow-fs-read could still resolve paths and check file existence outside the allowed directories. This was an incomplete fix of an earlier CVE that only covered the native variant of the same function.

0xoroot Follow

Originally disclosed on HackerOne

  • Triaged in 57 days
  • Fixed in 4 months
  • Disclosed after 4 months

Summary by the program

A flaw in Node.js Permission Model filesystem enforcement leaves fs.realpathSync() without the required read permission checks. This is an incomplete fix of CVE-2026-21715, which only covered fs.realpathSync.native().

As a result, code running under --permission with restricted --allow-fs-read can still use fs.realpathSync() to check file existence, resolve symlink targets, and enumerate filesystem paths outside of permitted directories.

The original report as published on HackerOne, by 0xoroot. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the permission check was added only to the native realpath implementation, leaving the JavaScript-level fs.realpathSync() path unguarded.

Impact

Code under the Permission Model with restricted read access could check file existence, resolve symlink targets and enumerate paths outside permitted directories.

What the attacker needed

Node.js run with --permission; Restricted --allow-fs-read list; Ability to run code in that process

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

Node.js has an optional mode that lets you run code with only certain files and folders allowed, so untrusted code cannot read everything on the machine. One function that turns a path into its real, symlink-free form was left out of that check, so restricted code could still ask the system whether files exist and where links point. That leaks information about the filesystem even though reading file contents was blocked.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More by 0xoroot

View all

4 more disclosed reports, best first.

More from Node.js

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.