Access control
Server action changes data without checking who is callingaccess.server-action-no-auth
Every exported function in a "use server" file is a public HTTP endpoint — Next.js gives it an id that the browser can call with any arguments, from any page, signed in or not. This one writes data and never checks the session.
- In force Rule access.server-action-no-auth
- 3 clauses
At a glance
| Severity | high |
|---|---|
| Certainty | Needs review — a heuristic; confirm before changing code |
| Looks at | your source code |
| When it runs | Runs on every scan |
How to fix it
Authenticate inside the action itself (not only on the page that renders the form), and check the caller owns whatever the arguments point at.
Check your own app
Run npx scanlyfix scan in your project. Every finding gets an id; after fixing, npx scanlyfix verify <id> proves it is gone.
If it is a false positive in your project, silence that one line with // scanlyfix-ignore-next-line access.server-action-no-auth -- <why>.
Your code stays
on your machine
Only findings are uploaded, and only to your own dashboard.
ScanlyFix
Security, privacy pages, SEO and AI visibility checked in one scan, with fixes your AI editor can apply.
Home