Sveltejs kit
SvelteKit: Build-time server-only module import guard could fail, resulting in server secrets being statically replaced in client bundle
SvelteKit is a framework for rapidly developing robust, performant web applications using Svelte. From version 3.0.0 until 3.1.1, the build-time server-only module guard did not treat src/params.js as a client entry point even though parameter matchers can run in the browser. Server-only modules imported through src/params.js could consequently enter the client bundle, where statically replaced private environment values or other server secrets could be exposed. This issue is fixed in 3.1.1.
First public PoC
None yetno public PoC found
Public PoCs00 on GitHub
CVSS7.5high · scored by CNA · CWE-200
CISA KEV
Not listednot known exploited
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
sveltejs kit
- >= 3.0.0, < 3.1.1
Fixed in 3.1.1
Mitigation
Upgrade kit to 3.1.1 or later.
References
- Vendor advisory github.com/sveltejs/kit/security/advisories/GH…
- Patch github.com/sveltejs/kit/commit/ae07803806f75b8…
- Release notes github.com/sveltejs/kit/releases/tag/@sveltejs…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.