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-35338

CVE-2026-35338: Path Validation Bypass in uutils/coreutils chmod --preserve-root Option

Alon Barad
Alon Barad
Software Engineer

Jul 6, 2026·6 min read·18 visits

Executive Summary (TL;DR)

A vulnerability in uutils/coreutils chmod allows local bypass of '--preserve-root' safety checks using unnormalized paths like '/../', leading to recursive root permission destruction.

A path validation bypass vulnerability exists in the chmod utility of uutils/coreutils before version 0.6.0. The '--preserve-root' safety mechanism relies on a literal string comparison, allowing local users to bypass root directory protection via unnormalized paths (such as '/../' or symbolic links) and recursively alter system-wide permissions.

Vulnerability Overview

The uutils/coreutils package is a cross-platform rewrite of the GNU coreutils suite in Rust. The chmod utility is a core component used to modify file and directory permissions across different filesystems. When operating in recursive mode via the -R or --recursive flags, the utility poses a significant risk to system stability if executed on the root directory. To protect against accidental system-wide permission modifications, both GNU coreutils and uutils/coreutils implement a safety mechanism named --preserve-root which is enabled by default.

This safety mechanism is designed to abort execution immediately if the target of a recursive command is identified as the filesystem root (/). However, a path validation bypass vulnerability exists in the chmod utility of uutils/coreutils prior to version 0.6.0. Because the software fails to canonicalize paths before performing the root protection check, attackers or local users can circumvent the validation logic. This bypass allows the utility to execute destructive operations on the root directory, causing system-wide permission loss.

The vulnerability is classified as CWE-22 (Improper Limitation of a Pathname to a Restricted Directory). It exposes systems to complete denial of service and structural breakdown if a recursive chmod command is executed on paths that resolve logically to root but bypass literal checks.

Root Cause Analysis

The root cause of this vulnerability lies in the implementation of the path comparison check inside the recursive validator in src/uu/chmod/src/chmod.rs. To identify if the user-supplied target path points to the filesystem root, the utility performs a direct, literal comparison: file == Path::new("/"). This comparison is lexical and syntax-dependent rather than logical or semantic.

On UNIX and Linux operating systems, multiple syntactically unique paths resolve to the exact same physical directory. Specifically, the path /../ refers directly to the root directory because the parent directory of the root is recursively evaluated as the root itself. Similarly, redundant path delimiters (such as //) or relative-path tokens (such as /./) are resolved by the OS kernel to the root directory during system calls.

Because the comparison check in chmod.rs only verifies if the unnormalized string or path is strictly equal to /, it fails to recognize /../ or // as equivalent paths. As a result, when an execution is triggered with /../ as the argument, the conditional block evaluating the safety guard returns false, thereby authorizing the recursive directory traversal and permission changes.

Code Analysis

An examination of the vulnerable code segment in src/uu/chmod/src/chmod.rs shows the reliance on a literal check. The snippet below highlights the vulnerable logic before patch application:

// Vulnerable check in chmod.rs
if self.recursive && self.preserve_root && file == Path::new("/") {
    return Err(ChmodError::PreserveRoot("/".into()).into());
}

The fix introduced in Git commit 413055b378fa6fe2299c5e5f538c8e6e841ab810 replaces this literal comparison with a dedicated helper function Self::is_root(file) that leverages absolute path resolution:

// Patched check in chmod.rs
if self.recursive && self.preserve_root && Self::is_root(file) {
    return Err(ChmodError::PreserveRoot("/".into()).into());
}
 
// Helper function implementing canonicalization
fn is_root(file: impl AsRef<Path>) -> bool {
    matches!(fs::canonicalize(&file), Ok(p) if p == Path::new("/"))
}

The function is_root invokes std::fs::canonicalize(), which resolves all intermediate symbolic links, redundant separators, and relative directory traversals like .. and .. The resulting absolute path p is then verified against the literal root path. If the resolved path matches /, the safety guard successfully triggers, throwing an error and terminating the command before execution begins.

Exploitation & Attack Scenarios

Exploitation of this vulnerability requires local shell access to execute the chmod utility, or the ability to influence arguments passed to a recursive execution of chmod. The most immediate attack scenario involves an unprivileged local user or an administrative account mistakenly executing a recursive permission change. Under normal conditions, attempting to execute a recursive permission deletion on the root directory is blocked by the default safety configuration.

To bypass this check, an operator or local actor can execute the following command:

chmod -R --preserve-root 000 /../

Because the utility fails to canonicalize /../, it bypasses the safety guard. The OS then processes the target as the filesystem root, recursively descending through every directory starting from the root. This results in the complete loss of all file permissions, rendering the operating system inoperable. Symbolic links pointing to / can also be exploited to trigger similar outcomes if the link itself is targeted during execution.

Security Implications and Fix Completeness

The security implications of bypassing --preserve-root are substantial, as it leads directly to local denial of service and structural system failure. If executed with high privileges, such as root or sudo, the system loses all capability to load shared libraries, run system binaries, or authenticate users due to the destruction of standard UNIX file permissions (e.g., setuid flags on /bin/sudo or read permissions on configuration files).

While the fix in version 0.6.0 resolves simple path-traversal bypasses using canonicalization, certain advanced vectors remain relevant for security engineers to consider. For example, a Time-of-Check to Time-of-Use (TOCTOU) race condition is theoretically possible. If an operator starts a recursive chmod on a benign directory, an attacker with write access to the parent directories could swap the target directory with a symbolic link to the root directory during the active traversal, bypassing the initial canonicalization check.

Additionally, std::fs::canonicalize() requires that the path elements exist and are accessible. If path resolution fails due to intermediate permission restrictions, the helper function is_root evaluates to false. A more complete fix, similar to the implementation in GNU coreutils, would compare the device identifier (st_dev) and inode number (st_ino) of the target path against the root mount point to ensure absolute identity resolution regardless of the directory string state.

Remediation & Detection

The primary remediation path is upgrading uutils/coreutils to version 0.6.0 or later. This release integrates the canonicalization fix that secures the --preserve-root guard against directory traversal bypass vectors. If immediate upgrading is not possible, organizations should deploy wrapper scripts or monitoring rules to detect and block recursive execution of chmod containing parent directory tokens.

Detection of exploit attempts or accidental execution can be achieved by monitoring shell history and system audit logs for suspicious execution parameters. Specifically, look for command invocations matching the pattern chmod -R or chmod --recursive followed by arguments containing /.. or other non-standard root path representations.

In highly sensitive environments, administrators can configure system policies (such as AppArmor or SELinux) to restrict the execution of recursive permission changes on system-level directories. This restricts the potential blast radius of both accidental errors and malicious exploitation.

Official Patches

uutilsSecurity Fix Pull Request #10033

Fix Analysis (1)

Technical Appendix

CVSS Score
7.3/ 10
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H
EPSS Probability
0.18%
Top 93% most exploited

Affected Systems

uutils/coreutils (chmod recursive execution)

Affected Versions Detail

Product
Affected Versions
Fixed Version
uutils/coreutils
uutils
< 0.6.00.6.0
AttributeDetail
CWE IDCWE-22
Attack VectorLocal (AV:L)
CVSS v3.1 Score7.3
EPSS Score0.00175
EPSS Percentile7.13%
ImpactLocal Denial of Service / Structural Permissions Failure
Exploit StatusProof of Concept Available
CISA KEV StatusNot Listed

MITRE ATT&CK Mapping

T1083File and Directory Discovery
Discovery
T1005Data from Local System
Collection
CWE-22
Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

The product uses unsanitized input to construct a pathname that should be within a restricted directory, but it does not properly resolve or neutralize paths that traverse outside of the restricted directory.

References & Sources

  • [1]CVE org Entry
  • [2]uutils/coreutils Release Tag 0.6.0
  • [3]Security Fix Pull Request #10033
  • [4]Official Fix Commit

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

•22 minutes ago•CVE-2026-53951
8.8

CVE-2026-53951: Trust-Prefix Bypass via Path Traversal leading to Remote Code Execution in Copier

A security vulnerability in Copier versions 9.5.0 through 9.15.1 allows unauthenticated remote code execution via crafted HTTP requests or local paths containing traversal sequences. The trust-evaluation mechanism compares target repository paths or URLs against trusted prefixes using unnormalized string comparison, while the subsequent fetching mechanism normalizes the path before cloning. Attackers can exploit this asymmetry to bypass security warning prompts and execute arbitrary commands under the local user context.

Amit Schendel
Amit Schendel
0 views•6 min read
•about 1 hour ago•GHSA-P77J-G7H5-R2VW
8.8

GHSA-P77J-G7H5-R2VW: Tier-0 Security Hardening in GeoLens

GeoLens before version 1.2.4 contains multiple critical-tier security vulnerabilities including improper authorization in metadata access, tile cache scope leakage, dataset title enumeration, weak default credentials, and denial of service via STAC POST search.

Amit Schendel
Amit Schendel
0 views•6 min read
•about 2 hours ago•CVE-2026-55694
7.1

CVE-2026-55694: Chained Information Disclosure and IDOR in Snipe-IT EULA Management

CVE-2026-55694 is a chained Information Disclosure and Insecure Direct Object Reference (IDOR) vulnerability in Snipe-IT prior to version 8.6.3. The vulnerability allows authenticated, restricted users to completely bypass randomized file-naming security controls, leak the obfuscated filenames of signed End User License Agreements (EULAs), and subsequently download these confidential documents across tenant boundaries.

Amit Schendel
Amit Schendel
2 views•7 min read
•about 3 hours ago•CVE-2026-55703
4.3

CVE-2026-55703: Missing Authorization in Snipe-IT Maintenance Records

Snipe-IT is an IT asset/license management system. Prior to 8.6.3, any activated account can request /maintenances/{id} and read maintenance records for assets in the same company without asset or maintenance permission. app/Http/Controllers/MaintenancesController.php show() renders the record without authorize(), while company-scoped route-model binding only prevents access to other companies. Disclosed fields include asset tags, suppliers, purchase costs, notes, and dates. This issue is fixed in version 8.6.3.

Amit Schendel
Amit Schendel
3 views•5 min read
•about 4 hours ago•CVE-2026-61807
6.3

CVE-2026-61807: Stored DOM-Based Cross-Site Scripting in Snipe-IT

A Stored DOM-based Cross-Site Scripting (DOM XSS) vulnerability exists in Snipe-IT versions prior to 8.6.2. The vulnerability occurs when a stored manufacturer or supplier name is converted to CamelCase and rendered within the 'data-selected-count-id' attribute of a table. Client-side JavaScript retrieves this decoded attribute and performs unsafe string concatenation, passing it directly into jQuery's '.after()' method, enabling authenticated attackers to execute arbitrary JavaScript in the victim's session.

Alon Barad
Alon Barad
3 views•6 min read
•about 6 hours ago•CVE-2026-62673
8.2

CVE-2026-62673: Security Bypass in Grav CMS via Case-Sensitivity Mismatch

CVE-2026-62673 (also known as CVE-2026-62230 and GHSA-vwg3-w8w3-pc79) is a high-severity security bypass vulnerability in the Grav CMS. It permits unauthenticated remote attackers to circumvent directory and file access policies defined in Apache .htaccess. This flaw allows direct retrieval of sensitive configuration files, system-level credentials, and database equivalents from case-insensitive host filesystems.

Amit Schendel
Amit Schendel
3 views•6 min read