CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-34604

CVE-2026-34604: Path Validation Bypass via Symlinks in @tinacms/graphql

Alon Barad
Alon Barad
Software Engineer

Apr 1, 2026·7 min read·36 visits

Executive Summary (TL;DR)

TinaCMS GraphQL API allows path traversal via symlinks, enabling restricted file access.

The @tinacms/graphql package before version 2.2.2 is vulnerable to a path traversal attack due to improper symlink validation. An authenticated attacker can read, write, or delete files outside the intended content root if a symbolic link exists.

Vulnerability Overview

TinaCMS is a headless content management system that relies on a GraphQL API to interact with the underlying filesystem. The @tinacms/graphql package provides the backend logic for reading, writing, and managing content files. This package restricts file operations to a specific base directory to prevent unauthorized access.

CVE-2026-34604 represents a bypass of this directory restriction mechanism. The vulnerability specifically involves improper handling of symbolic links and directory junctions during path validation. An authenticated user with low-level privileges can exploit this flaw to perform unauthorized file operations.

The flaw is classified under CWE-22 (Improper Limitation of a Pathname to a Restricted Directory) and CWE-59 (Improper Link Resolution Before File Access). The vulnerability exposes the underlying host filesystem to unauthorized read, write, and delete operations. This compromises the isolation of the CMS content directory from the broader server environment.

Root Cause Analysis

The root cause resides in the FilesystemBridge class of the @tinacms/graphql package. The system must validate that all user-supplied file paths resolve to locations within the configured baseDir. Prior to version 2.2.2, the bridge relied exclusively on lexical string operations to enforce this boundary.

The vulnerable validation logic utilized Node.js path.resolve() combined with a startsWith() check against the base directory string. While path.resolve() successfully normalizes standard traversal segments like ../, it performs no filesystem interactions. It strictly computes the theoretical path based on lexical rules without verifying the actual filesystem structure.

This lexical approach fails when the filesystem contains symbolic links or directory junctions. If a symlink within the allowed content root points to an external directory, appending a target filename to the symlink path will mathematically appear to reside inside the baseDir. The validation passes because the string manipulation does not follow the symlink to its physical destination on disk.

When the application subsequently passes this validated string to underlying Node.js filesystem functions such as fs.readFile or fs.outputFile, the operating system resolves the symlink. The file operation occurs at the external location pointed to by the symlink, completely bypassing the intended sandbox. The application logic incorrectly assumes that lexical containment guarantees physical filesystem containment.

Code Analysis

Analyzing the vulnerable implementation reveals the reliance on standard path manipulation functions. The application combined the base directory and the user-supplied filepath using path.join(), then applied path.resolve(). The resulting string was evaluated using a simple startsWith() method against the resolved base directory path.

The fix, introduced in commit f124eabaca10dac9a4d765c9e4135813c4830955, replaces the lexical check with a robust physical path resolution strategy. The maintainers introduced a new validation function named assertSymlinkWithinBase. This function utilizes fs.realpathSync() to determine the absolute, canonical path of the target, successfully resolving all symlinks before performing the boundary check.

To handle operations where the target file does not yet exist, such as a file upload or creation, the patch includes a recursive helper function named resolveRealPath. This function climbs the directory tree to find the nearest existing ancestor directory. It resolves the real path of that ancestor and appends the remaining path segments.

The implementation of this logic ensures that path containment is verified against the actual disk layout rather than an abstract string representation. The specific logic for resolveRealPath relies on catching the error thrown by fs.realpathSync() when a file does not exist.

function resolveRealPath(candidate: string): string {
  try {
    return fs.realpathSync(candidate);
  } catch {
    const parent = path.dirname(candidate);
    if (parent === candidate) return candidate;
    return path.join(resolveRealPath(parent), path.basename(candidate));
  }
}

By validating the output of resolveRealPath against the realpath of the base directory, the application guarantees that no filesystem operation escapes the intended root directory, regardless of intermediary symbolic links.

Exploitation Methodology

Exploitation of CVE-2026-34604 requires specific preconditions on the target system. The primary requirement is the existence of a symbolic link within the TinaCMS content directory that points to a location outside of it. Alternatively, an attacker needs the ability to create such a symlink through a separate vulnerability or misconfiguration.

The attacker must also possess sufficient privileges to interact with the TinaCMS GraphQL API. Typically, this means the attacker holds an authenticated session as a CMS editor or author. The attack complexity is categorized as High because the presence of the requisite symlink is heavily dependent on the specific deployment environment and configuration.

Once the prerequisites are met, the attacker crafts malicious GraphQL queries invoking the FilesystemBridge methods. By supplying a path that traverses through the known symlink, the attacker dictates the final destination of the file operation. For instance, sending a get() request targeting content/uploads/symlink/passwd forces the application to read the system password file if the symlink points to the /etc/ directory.

Similar techniques apply to data modification. An attacker can execute a put() operation through the symlink to overwrite critical system configuration files or plant executable web shells in publicly accessible directories. A delete() operation can be leveraged to remove application dependencies or configuration data, leading to service degradation or failure.

Impact Assessment

The successful exploitation of this vulnerability yields substantial control over the underlying host filesystem. The impact on confidentiality is high, as the attacker can retrieve sensitive information including environment variables, database credentials, and proprietary source code. This data extraction facilitates further horizontal or vertical privilege escalation within the network environment.

Integrity is similarly compromised at a high level. The ability to write arbitrary files allows the attacker to alter system behavior, modify stored application data, or establish persistent backdoors. Writing malicious payloads to executable directories or startup scripts grants the attacker remote code execution capabilities on the host server.

The availability impact is rated as low in the CVSS vector, though the attacker can delete files. Removing critical system components or application files can cause localized outages or application crashes. The overall CVSS v3.1 base score of 7.1 accurately reflects the severity of the flaw given the required prerequisites and the high impact on confidentiality and integrity.

Remediation and Mitigation

The definitive remediation for CVE-2026-34604 is updating the @tinacms/graphql package to version 2.2.2 or later. This release contains the assertSymlinkWithinBase validation logic that correctly resolves symbolic links before authorizing file operations. System administrators must ensure that all deployments, including development and staging environments, are updated to prevent exploitation.

As a defense-in-depth measure, administrators should implement strict filesystem access controls for the user account executing the Node.js process. The application process should operate with the minimum necessary privileges, restricting read and write access strictly to the required application directories. This limits the potential blast radius if a path traversal vulnerability is successfully exploited.

Environmental isolation further reduces the risk profile. Deploying the CMS within a tightly constrained container environment, such as Docker, prevents a compromised process from accessing the underlying host OS filesystem. Configuring read-only root filesystems and limiting writable mounts to specific, non-executable data volumes provides an additional layer of security against arbitrary file write attacks.

Official Patches

TinaCMSOfficial GitHub Security Advisory for @tinacms/graphql

Fix Analysis (1)

Technical Appendix

CVSS Score
7.1/ 10
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:L

Affected Systems

TinaCMS headless content management systemNode.js environments running @tinacms/graphql below version 2.2.2

Affected Versions Detail

Product
Affected Versions
Fixed Version
@tinacms/graphql
TinaCMS
< 2.2.22.2.2
AttributeDetail
CWE IDCWE-59, CWE-22
Attack VectorNetwork
CVSS Score7.1
Privileges RequiredLow
User InteractionNone
Exploit StatusProof of Concept

MITRE ATT&CK Mapping

T1083File and Directory Discovery
Discovery
T1005Data from Local System
Collection
CWE-59
Improper Link Resolution Before File Access ('Link Following')

The software attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.

Vulnerability Timeline

Security patch committed by TinaCMS maintainers
2026-03-26
Vulnerability publicly disclosed and CVE assigned
2026-04-01
Advisory published on GitHub
2026-04-01

References & Sources

  • [1]GHSA-g9c2-gf25-3x67
  • [2]CVE.org Record for CVE-2026-34604

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•1 day ago•CVE-2026-58254
6.5

CVE-2026-58254: Authorization Bypass in NATS Server Message Tracing for Leaf Node Connections

NATS Server prior to versions 2.12.8 and 2.14.3 contains an incorrect authorization vulnerability (CWE-863) in its message tracing subsystem. When evaluating whether a connection is permitted to publish trace events to a destination subject specified in the Nats-Trace-Dest header, the server only checks standard client permissions and omits permission checks for leaf node connections. This allows a connected leaf node operator with restricted publishing privileges to emit internal trace events to unauthorized subjects and suppress standard message delivery using the Nats-Trace-Only header.

Alon Barad
Alon Barad
6 views•10 min read
•1 day ago•CVE-2026-63341
7.5

CVE-2026-63341: Unauthenticated Denial of Service via Unbounded Topic Depth in Aedes MQTT Broker

CVE-2026-63341 is a high-severity Denial of Service (DoS) vulnerability in the Aedes MQTT broker for Node.js affecting all versions prior to 1.1.1. The flaw stems from missing input validation on the hierarchical depth of incoming MQTT topic strings before they are passed to the underlying topic-matching engine, qlobber. Because qlobber enforces a hardcoded limit of 100 topic levels and throws a synchronous exception when this threshold is exceeded, an attacker can send a single MQTT packet containing 101 or more forward-slash-separated levels to trigger an uncaught exception that immediately terminates the Node.js broker process.

Alon Barad
Alon Barad
11 views•12 min read
•1 day ago•CVE-2026-61725
6.1

CVE-2026-61725: Path Traversal and Arbitrary File Overwrite in sevenz-rust2

CVE-2026-61725 is a path traversal vulnerability (CWE-22) in the sevenz-rust2 Cargo package prior to version 0.21.1. The vulnerability occurs because the decompression utility fails to validate or sanitize archive entry filenames before joining them with the destination directory path via std::path::Path::join. An attacker who supplies a crafted 7z archive containing parent directory traversal sequences or absolute paths can write or overwrite arbitrary files on the host filesystem with the privileges of the extracting process.

Alon Barad
Alon Barad
6 views•12 min read
•1 day ago•CVE-2026-77309
8.8

CVE-2026-77309: Unauthenticated Remote Code Execution in NASA-AMMOS AIT-GUI via Incomplete File Cleanup and Path Traversal

CVE-2026-77309 (GHSA-jrjx-9jjw-747m) is a high-severity unauthenticated remote code execution vulnerability affecting NASA-AMMOS AIT-GUI versions 1.0.0 through 2.5.0. The flaw results from chaining an incomplete file cleanup error in the telemetry query endpoint (/tlm/query) with a directory traversal flaw in the script execution endpoint (/script/run). An attacker on an adjacent network can stage arbitrary Python statements into a static file on disk and execute that file under the privileges of the AIT-GUI web server process.

Amit Schendel
Amit Schendel
13 views•10 min read
•1 day ago•CVE-2026-77332
2.3

CVE-2026-77332: Surfaced-Memory Envelope Injection and Stored Prompt Injection in memtomem-stm

A vulnerability classified under CWE-116 (Improper Encoding or Escaping of Output) exists in memtomem-stm versions 0.1.0 through 0.1.33. The software acts as a Model Context Protocol (MCP) short-term memory proxy gateway for AI agent architectures. When surfacing retrieved memories and scratchpad items into downstream Large Language Model (LLM) context envelopes, the SurfacingFormatter component fails to properly sanitize untrusted memory attributes. An attacker with the ability to plant untrusted content into the agent's long-term or working memory store can inject arbitrary structural delimiters, close the <surfaced-memories> XML boundary prematurely, visually obscure instructions using Unicode bidirectional overrides, and execute stored prompt injection attacks against downstream LLM agents.

Alon Barad
Alon Barad
14 views•10 min read
•1 day ago•CVE-2026-77331
2.0

CVE-2026-77331: Race Condition and Session State Corruption in memtomem-stm

CVE-2026-77331 (GHSA-72jh-722p-rqr3) is a concurrency and session-state synchronization vulnerability in memtomem-stm, a short-term memory proxy gateway for AI agents. In versions 0.1.2 prior to 0.1.34, concurrent Model Context Protocol (MCP) Remote Procedure Call (RPC) failures or mid-flight task cancellations can initiate duplicate reconnect loops and permit dirty or cancelled transport sessions to be reused. This deficiency results in session-state integrity loss and local service degradation.

Amit Schendel
Amit Schendel
6 views•9 min read