High

tinacms is vulnerable to arbitrary code execution

  • Disclosed: 18.12.2025
  • Updated: 11.10.2026 10:22

Summary

tinacms uses the gray-matter package in an insecure way allowing attackers that can control the content of the processed markdown files, e.g., blog posts, to execute arbitrary code.

Details

The gray-matter package executes by default the code in the markdown file's front matter. tinacms does not change this behavior when process markdown file, e.g., by passing a custom engine property for js/javascript in the options object.

PoC

  1. Create a tinacms app using the cli/documentation:
bash
npx create-tina-app@latest
  1. Modify one of the blog posts to contain the following front matter:
js
---js
{
  "title": "Pawned" + console.log(require("fs").readFileSync("/etc/passwd").toString())
}
---
  1. Start the tinacms server, e.g., with npm run dev
  2. Observe the console of the server printing the password file, showing that attackers can execute arbitrary commands.

Impact

RCE: attackers can execute arbitrary JavaScript code on the server hosting tinacms.

Feasibility

Potential attack scenarios can be executed like this: Companies often have technical writers as contractors. These contractors produce md files, which they send over email or upload in a shared cloud folder. Developers download these files and upload them in tinacms's content folder. While this example might appear speculative or contrived, a general observation is that developers would be very surprised to find out that processing untrusted markdown files via tinacms = server-side code execution = complete machine take over. That is, tinacms users might not expect markdown files to contain anything else than data and gray-matter violates that assumption.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package tinacms < 3.1.1 3.1.1
npm package @tinacms/cli < 2.0.4 2.0.4
npm package @tinacms/graphql < 2.0.3 2.0.3

References

CVSS score -
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:P
Weakness (CWE)
CWE-94
Platform
npm
Package
tinacms, @tinacms/cli, @tinacms/graphql
Disclosed
18.12.2025
Updated
11.10.2026 10:22

Sources and licenses

OSV / GitHub Advisory Database - GHSA-529f-9qwm-9628 - CC BY 4.0

Vulnerability history: tinacms

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

Total entries
5
First → latest
12.2025 10.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • Critical 1
  • High 3
  • Medium 1

Disclosures per year

  1. 2025: 1
  2. 2026: 4
  1. High · 7.4 CVE-2026-28791 < 2.1.7 2.1.7
  2. tinacms is vulnerable to arbitrary code execution this entry
    High CVE-2025-68278 < 3.1.1 3.1.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.