Skip to content
Fencer Vulns
high 8.1

CVE-2022-21235 json

Command Injection

published 2022-04-01 4 y ago modified 2026-09-10 1 mo ago also GHSA-6635-c626-vj4r , GO-2022-0414 , EUVD-2022-1643

cvss
8.1
version 3.1, CNA
cisa kev
Not listed
not in CISA's catalog
epss
1.6%
EPSS 1.6% chance of exploitation in 30 days, percentile 75%
public exploits
0
none known

Summary

The package github.com/masterminds/vcs before 1.13.3 are vulnerable to Command Injection via argument injection. When hg is executed, argument strings are passed to hg in a way that additional flags can be set. The additional flags can be used to perform a command injection.

Patch / fix

  • go github.com/Masterminds/vcs 1.13.2, 1.13.3
  • n/a github.com/Masterminds/vcs 1.13.3

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2022-21235 updated cvss 9.8

github.com/Masterminds/vcs: Command Injection via argument injection

  • Red Hat OpenShift Serverless openshift-serverless-1/ingress-rhel8-operator, openshift-serverless-1/knative-rhel8-operator, openshift-serverless-1/serverless-rhel8-operator Red Hat Advanced Cluster Security 3 advanced-cluster-security/rhacs-main-rhel8, advanced-cluster-security/rhacs-scanner-rhel8 Red Hat Ansible Automation Platform 1.2 helm Red Hat OpenShift Container Platform 4 openshift4/ose-console, redhat/redhat-operator-index, openshift4/oc-mirror-plugin-rhel8, openshift4/ose-operator-sdk-rhel8, openshift4/ose-gcp-pd-csi-driver-rhel9, openshift4/special-resource-rhel8-operator, +4 more Red Hat OpenShift Container Platform Assisted Installer 1 rhai-tech-preview/assisted-installer-rhel8, rhai-tech-preview/assisted-installer-agent-rhel8
    affected: no fix available
  • Red Hat Openshift Container Storage 4 ocs4/mcg-rhel8-operator, ocs4/ocs-rhel8-operator
    affected: no fix planned “Out of support scope”
  • Red Hat Openshift Data Foundation 4 odf4/odf-rhel8-operator, odf4/odr-rhel8-operator, odf4/odf-lvm-rhel8-operator, odf4/odf-multicluster-rhel9-operator Red Hat OpenShift GitOps openshift-gitops-1/kam-delivery-rhel8, openshift-gitops-1/gitops-rhel8-operator
    affected: no fix available
  • Red Hat OpenShift Container Platform 4.11 openshift4/ose-agent-installer-csr-approver-rhel8 v4.11.0-202307072028.p0.gaa46748.assembly.stream
    fixed: vendor fix RHSA-2023:4053
  • Red Hat OpenStack Platform 16.2 rhosp-rhel8/osp-director-operator 1.3.0-8
    fixed: vendor fix RHSA-2023:4694
  • Red Hat OpenStack Platform 17.1 rhosp-rhel9/osp-director-agent 1.3.1-10
    fixed: vendor fix RHSA-2023:4582
  • Red Hat OpenShift Developer Tools and Services helm Red Hat 3scale API Management Platform 2 github-Masterminds-vcs github-Masterminds-vcs Red Hat Advanced Cluster Management for Kubernetes 2 rhacm2/acm-search-v2-rhel9, rhacm2/multiclusterhub-rhel8, rhacm2/acm-cluster-proxy-rhel8, rhacm2/multiclusterhub-repo-rhel8, rhacm2/acm-volsync-addon-controller-rhel9, acm-multicluster-globalhub-agent-container, +6 more Red Hat OpenShift Container Platform 4 openshift4/ose-olm-rukpak-rhel8, openshift4/metallb-rhel8-operator, openshift4/ose-cluster-version-operator, openshift4/ose-azure-cluster-api-controllers-rhel8, openshift4-wincw/windows-machine-config-rhel8-operator Red Hat OpenShift Container Platform 4.11 openshift4/ose-cli v4.11.0-202307072028.p0.g2ae2303.assembly.stream, openshift4/ose-pod v4.11.0-202307072028.p0.g990d55b.assembly.stream, openshift4/ose-etcd v4.11.0-202307072028.p0.gc637f9b.assembly.stream, openshift4/ose-tests v4.11.0-202307120842.p0.g7fbbd19.assembly.stream, openshift4/ose-console v4.11.0-202307100428.p0.g08ad567.assembly.stream, openshift4/ose-coredns v4.11.0-202307072028.p0.g227d727.assembly.stream, +174 more Red Hat Openshift Data Foundation 4 odf4/mcg-rhel9-operator, odf4/ocs-rhel9-operator, odf4/odf-csi-addons-sidecar-rhel9
    +2 more products
    Red Hat OpenStack Platform 16.2 rhosp-rhel8/osp-director-agent 1.3.0-9, rhosp-rhel8/osp-director-downloader 1.3.0-10, rhosp-rhel8/osp-director-operator-bundle 1.3.0-17 Red Hat OpenStack Platform 17.1 rhosp-rhel9/osp-director-operator 1.3.1-10, rhosp-rhel9/osp-director-downloader 1.3.1-8, rhosp-rhel9/osp-director-operator-bundle 1.3.1-14
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Exploit prediction

1.58% chance of exploitation in the next 30 days, higher than 75% of all scored CVEs (FIRST EPSS, 2026-11-08).

CVSS scores

assigned by version score vector
CNA 3.1 8.1 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
NVD 3.1 9.8 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
NVD 2.0 6.8 AV:N/AC:M/Au:N/C:P/I:P/A:P
GitHub 3.1 9.8 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Affected packages

ecosystem package affected fixed in
go github.com/Masterminds/vcs
<1.13.2
<1.13.3
1.13.2
1.13.3

Affected products

  • n/a github.com/Masterminds/vcs

Classification

Weakness
  • CWE-88 Improper Neutralization of Argument Delimiters in a Command
  • CWE-77 Improper Neutralization of Special Elements used in a Command

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.