All vulnerabilities

Servers and applications

GHSA-59wf-wmcq-r5j8

Memory exhaustion when reading remote functions `form` request bodies (experimental only)

Severity
Medium
Published
25 Nov 2026
Last changed
25 Nov 2026
Added to UpHeron
25 Nov 2026
Fixed in
3.4.1
Weakness
Memory leak (CWE-401)Allocation without limits (CWE-770)
Sources
Project advisories (GitHub)

Description

This only affects applications using the experimental remote functions flag and exposing a form remote function.

When a remote form request is submitted with the application/x-sveltekit-formdata content type, SvelteKit reads the request body incrementally. Memory used while reading the body grew with the number of chunks the body was split into rather than with its size, so a request within BODY_SIZE_LIMIT could cause the server to hold far more memory than the limit suggests.

In addition, when using @sveltejs/adapter-node (or getRequest from @sveltejs/kit/node), a request body that had not finished arriving when the response was sent was not released when the connection closed. If anything else kept the request alive, such as the first request to load a given .remote module, or a timer or pooled connection created during the request, that memory was retained.

From sveltejs/kit's security advisory. Shortened; the full text is there.

Workarounds

Place the application behind a reverse proxy that buffers complete request bodies before forwarding them to the server.

Workarounds as given by sveltejs/kit's security advisory.

Affected software

SoftwareAffected versions
SvelteKitServers and applications · github:sveltejs/kit
  • From 2.49.0 before 3.4.1

About SvelteKit

web development, streamlined

From its GitHub repository.
Weekly downloads (npm)
5,128,894npm, 22 Nov 2026
GitHub stars
20,926GitHub, 22 Nov 2026
Forks
2,391GitHub, 22 Nov 2026
Latest release
@sveltejs/[email protected]GitHub, 22 Nov 2026
Released
18 Nov 2026GitHub
License
MITGitHub
First published on GitHub
15 Oct 2020GitHub

References