Low

SvelteKit: URL redirection to untrusted site via enhanced form submission

  • Disclosed: 23.10.2026
  • Updated: 24.10.2026 00:17

Impact

Applications using enhanced form actions (use:enhance) on routes that accept paths beginning with //, such as catch-all routes, may be vulnerable to an open redirect.

Patches

A fix has been prepared for @sveltejs/kit 3.0.0. Users should upgrade to 3.0.0 or later.

The fix preserves leading double slashes in action paths without generating protocol-relative URLs, restricts non-redirect action navigation to the current origin, and includes the origin when comparing action locations with the current page.

Workarounds

Reject requests whose parsed URL pathname begins with // before route resolution, for example in a reverse proxy or a SvelteKit handle hook.

Alternatively, disable navigation for non-redirect enhanced form results by supplying a custom submission callback:

svelte
<form method="POST" use:enhance={() => ({ update }) => update({ navigate: false })}>
  <!-- form fields -->
</form>

This applies non-redirect results to the current page instead of navigating to the action location.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package @sveltejs/kit < 3.0.0 3.0.0

References

CVSS score 4.7/10
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N
Weakness (CWE)
CWE-601
Platform
npm
Package
@sveltejs/kit
Disclosed
23.10.2026
Updated
24.10.2026 00:17

Sources and licenses

OSV / GitHub Advisory Database - GHSA-pfhg-q3qv-9q6r - CC BY 4.0

Vulnerability history: @sveltejs/kit

All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (19) in the archive
Total entries
19
First → latest
04.2023 10.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 6
  • Medium 8
  • Low 5

Disclosures per year

  1. 2023: 2
  2. 2024: 3
  3. 2025: 1
  4. 2026: 13
Severity:
  1. SvelteKit: URL redirection to untrusted site via enhanced form submission this entry
    Low · 4.7 CVE-2026-114060 < 3.0.0 3.0.0
  2. High CVE-2026-40073 < 2.57.1 2.57.1
  3. High · 7.5 CVE-2024-23641 >= 2.0.0, < 2.4.3 2.4.3
  4. High · 8.8 CVE-2023-29003 < 1.15.1 1.15.1

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.