CVE-2026-75926

Description

A flaw was found in Hugo. This vulnerability enables arbitrary command execution by bypassing security restrictions designed to confine asset-processing tools. Because TailwindCSS is granted permission to create child processes by default, an attacker providing a malicious theme, module, or configuration file can escape the restricted environment during a site build. Consequently, commands are executed with the full privileges of the user running the build process.

Statement

A command execution flaw rated Critical was found in Hugo, affecting the static site generator's Node.js asset-processing pipeline in versions 0.162.0 through 0.164.x. Hugo 0.161.0 placed its Node asset pipelines behind the Node.js permission model so that tools such as PostCSS, Babel, and TailwindCSS could not reach the file system outside the project directory. Hugo 0.162.0 then added tailwindcss to the default AllowChildProcess security configuration, and because TailwindCSS loads the site's tailwind.config.js through require at startup, top-level code in a Tailwind configuration supplied by a theme, module, or starter template executes inside the permitted Node process and can call child_process to spawn a shell. The spawned process is not a Node process and inherits none of the permission flags, so building a site with an untrusted Tailwind configuration results in arbitrary command execution with the full privileges of the account running the build, rather than the confined file access the permission model was introduced to enforce. Within Red Hat's product scope, only the Fedora community hugo package is affected, and a fix is being pursued for that community distribution. The hugo package shipped in Red Hat Hardened Images is not affected because the version shipped does not contain the vulnerable code. Upstream assesses this flaw as Critical with a CVSS 4.0 score of 9.3, while the Red Hat CVSS 3.1 vector scores it 8.6 (Important); this difference reflects the CVSS version and metrics used rather than the flaw's Red Hat impact rating of Critical.

Mitigation

Remove tailwindcss from the security.exec.allow allowlist in the site configuration. In hugo.toml, set the [security.exec] allow list explicitly without tailwindcss, for example:

[security.exec]
  allow = ['^(dart-)?sass$', '^go$', '^git$', '^node$', '^postcss$']

This prevents Hugo from launching the tailwindcss executable during builds, at the cost of TailwindCSS-based asset processing. Alternatively, only build sites whose themes, modules, and Tailwind configuration files come from trusted sources. Upstream Hugo 0.165.0 removes tailwindcss from the default security.exec.allow list, so upgrading to a version that includes this change also addresses the issue.

Common Vulnerability Scoring System (CVSS) Score Details

Info alert:Important note

CVSS scores for open source components depend on vendor-specific factors (e.g. version or build chain). Therefore, Red Hat's score and impact rating can be different from NVD and other vendors. Red Hat remains the authoritative CVE Naming Authority (CNA) source for its products and services (see Red Hat classifications).

The following CVSS metrics and score provided are preliminary and subject to review.

CVSS v3 Score Breakdown

Red HatNVDcve.org
Base Score8.6N/A8.6
Attack VectorLocalN/ALocal
Attack ComplexityLowN/ALow
Privileges RequiredNoneN/ANone
User InteractionRequiredN/ARequired
ScopeChangedN/AChanged
ConfidentialityHighN/AHigh
Integrity ImpactHighN/AHigh
Availability ImpactHighN/AHigh

Vector

Red Hat: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

cve.org: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H

Understanding the Weakness (CWE)

Confidentiality,Integrity,Availability,Non-Repudiation

Technical Impact: Execute Unauthorized Code or Commands; DoS: Crash, Exit, or Restart; Read Files or Directories; Modify Files or Directories; Read Application Data; Modify Application Data; Hide Activities

Attackers could execute unauthorized operating system commands, which could then be used to disable the product, or read and modify data for which the attacker does not have permissions to access directly. Since the targeted application is directly executing the commands instead of the attacker, any malicious activities may appear to come from the application or the application's owner.

Frequently Asked Questions

Want to get errata notifications? Sign up here.