GHSA-pfhg-q3qv-9q6r

Suggest an improvement
Source
https://github.com/advisories/GHSA-pfhg-q3qv-9q6r
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-pfhg-q3qv-9q6r/GHSA-pfhg-q3qv-9q6r.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-pfhg-q3qv-9q6r
Aliases
Published
2026-10-23T20:58:24Z
Modified
2026-10-23T21:15:03Z
Severity
  • 4.7 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N CVSS Calculator
  • 2.1 (Low) CVSS_V4 - CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N CVSS Calculator
Summary
SvelteKit: URL redirection to untrusted site via enhanced form submission
Details

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:

<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.

Database specific
{
    "cwe_ids":  [
        "CWE-601"
    ],
    "github_reviewed":  true,
    "github_reviewed_at":  "2026-10-23T20:58:24Z",
    "nvd_published_at":  null,
    "severity":  "LOW"
}
References

Affected packages

npm / @sveltejs/kit

Package

Name
@sveltejs/kit
View open source insights on deps.dev
Purl
pkg:npm/%40sveltejs/kit

Affected ranges

Type
SEMVER
Events
Introduced
0 Unknown introduced version / All previous versions are affected
Fixed
3.0.0

Database specific

source
"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-pfhg-q3qv-9q6r/GHSA-pfhg-q3qv-9q6r.json"