Vulnerability · Published Jun 16, 2026 · Assigned by redhat

CVE-2026-12398Galaxy_ng: shell injection in legacy role import via unsanitized git ref names

High 7.5

In plain English

A high-severity OS command injection in Red Hat Ansible Automation Platform 2 from Red Hat. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.9% (higher than 60% of all known vulnerabilities).

Severity (CVSS 3.1)7.5High
Exploit odds (30 days)0.9%top 40.5% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

A command injection vulnerability was found in galaxy_ng. The do_git_checkout() function in the legacy role import API (v1) interpolates unsanitized git ref names (branch/tag names) into shell commands executed via subprocess.run() with shell=True. An authenticated user who controls a git repository can create a branch or tag with shell metacharacters in the name to achieve remote code execution on the pulp worker. The vulnerable endpoint is only reachable when GALAXY_ENABLE_LEGACY_ROLES is set to True, which is not the default configuration.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
PyPIgalaxy-ngno fix listedGHSA-6hw7-j4jw-wpff
PyPIgalaxy-ngno fix listedPYSEC-2026-2486

Affected products (as reported)

Weakness: CWE-78 · Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H

References