You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add maximum size limit for postponed body parsing (#88175)
Adds a configurable `experimental.maxPostponedStateSize` limit for PPR
postponed state body parsing to prevent OOM/DoS attacks.
The postponed state body was read entirely without size limits, creating
a potential denial-of-service vector through unbounded memory
allocation.
Enforces a 10 MB default limit (configurable via next.config.js) with
byte counting during body parsing. Returns HTTP 413 when exceeded with a
helpful error message directing users to increase the limit if needed.
<!-- Closes NEXT- -->
<!-- Fixes # -->
Copy file name to clipboardExpand all lines: packages/next/errors.json
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -973,5 +973,7 @@
973
973
"972": "Failed to resolve pattern \"%s\": %s",
974
974
"973": "Server Actions are not enabled for this application. This request might be from an older or newer deployment.\nRead more: https://nextjs.org/docs/messages/failed-to-find-server-action",
975
975
"974": "Failed to find Server Action%s. This request might be from an older or newer deployment.\\nRead more: https://nextjs.org/docs/messages/failed-to-find-server-action",
976
-
"975": "Failed to find Server Action. This request might be from an older or newer deployment.\\nRead more: https://nextjs.org/docs/messages/failed-to-find-server-action"
976
+
"975": "Failed to find Server Action. This request might be from an older or newer deployment.\\nRead more: https://nextjs.org/docs/messages/failed-to-find-server-action",
977
+
"976": "Decompressed resume data cache exceeded %s byte limit",
978
+
"977": "maxPostponedStateSize must be a valid number (bytes) or filesize format string (e.g., \"5mb\")"
0 commit comments