CVE-2026-97038

Description

A flaw was found in cmd/go. This vulnerability allows arbitrary code execution on the build system when compiling untrusted packages. The Go build tool passes linker input files to the external linker without properly validating their format or checking for embedded directives. An attacker can exploit this flaw by providing a malicious package containing crafted linker inputs, enabling the injection of unauthorized linker flags and the execution of arbitrary code during the link step.

Statement

This vulnerability is evaluated as having a Moderate impact because triggering the flaw requires an attacker to convince a user to retrieve and compile an untrusted Go package, restricting exploitation to development workstations and build environments rather than production services. While link-time code execution allows arbitrary commands to run under the privileges of the user executing the build, it does not directly expose systems running pre-compiled binaries. Runtime deployments and server environments are not affected unless they actively compile untrusted external sources.

Mitigation

Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base, or stability.

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 Score7.8N/A8.8
Attack VectorLocalN/ANetwork
Attack ComplexityLowN/ALow
Privileges RequiredNoneN/ANone
User InteractionRequiredN/ARequired
ScopeUnchangedN/AUnchanged
ConfidentialityHighN/AHigh
Integrity ImpactHighN/AHigh
Availability ImpactHighN/AHigh

Vector

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

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

Understanding the Weakness (CWE)

Confidentiality,Integrity,Availability,Other

Technical Impact: Execute Unauthorized Code or Commands; Alter Execution Logic; Read Application Data; Modify Application Data

If an attacker can provide an untrusted input that contains argument-separating delimiters, then the resulting command will have more arguments than intended by the developer, potentially changing the expected behavior of the command. Depending on the functionality supported by the extraneous arguments, this may have security-relevant consequences. The attacker could include arguments that allow unintended commands or code to be executed, allow sensitive data to be read or modified, or cause other unintended behavior.

Frequently Asked Questions

Want to get errata notifications? Sign up here.