CVE-2022-29184

Command Injection/Argument Injection in GoCD

HIGH
8.8
CVSS Score
Published: May 20, 2022 at 07:25 PM UTC
Updated: June 17, 2026 at 04:39 AM UTC
2 products affected across 2 vendorsGocdGocd

Using gocd by gocd?

Get instant alerts when new vulnerabilities affect gocd - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
HIGH8.8
Exploit prediction
EPSS 4%
SSVC
No known exploit

Description

GoCD is a continuous delivery server. In GoCD versions prior to 22.1.0, it is possible for existing authenticated users who have permissions to edit or create pipeline materials or pipeline configuration repositories to get remote code execution capability on the GoCD server via configuring a malicious branch name which abuses Mercurial hooks/aliases to exploit a command injection weakness. An attacker would require access to an account with existing GoCD administration permissions to either create/edit (`hg`-based) configuration repositories; create/edit pipelines and their (`hg`-based) materials; or, where "pipelines-as-code" configuration repositories are used, to commit malicious configuration to such an external repository which will be automatically parsed into a pipeline configuration and (`hg`) material definition by the GoCD server. This issue is fixed in GoCD 22.1.0. As a workaround, users who do not use/rely upon Mercurial materials can uninstall/remove the `hg`/Mercurial binary from the underlying GoCD Server operating system or Docker image.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v < 22.1.0
Affected range stops below 22.1.0, so it looks safe — our inference, not a vendor statement
v < 22.1.0
Affected range stops below 22.1.0, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

References (4)

x_refsource_MISCRelease NotesThird Party Advisory
https://github.com/gocd/gocd/releases/tag/22.1.0
x_refsource_MISCRelease NotesVendor Advisory
https://www.gocd.org/releases/#22-1-0

SSVC — Action Prioritization

SSVCNo known exploitNot automatableTotal impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

8.8HIGHGitHub_M
Attack Vector
NETWORK
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
HIGH
Integrity
HIGH
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-77CWE-88

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card