Vulnerability · Published Feb 1, 2022 · Assigned by GitHub_M

CVE-2022-21687Command injection in gh-ost

Medium 6.8

In plain English

A medium-severity improper input validation in the github.com/github/gh-ost package (Go). There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 1.0% (higher than 63% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)6.8Medium
Exploit odds (30 days)1.0%top 36.9% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

gh-ost is a triggerless online schema migration solution for MySQL. Versions prior to 1.1.3 are subject to an arbitrary file read vulnerability. The attacker must have access to the target host or trick an administrator into executing a malicious gh-ost command on a host running gh-ost, plus network access from host running gh-ost to the attack's malicious MySQL server. The `-database` parameter does not properly sanitize user input which can lead to arbitrary file reads.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Gogithub.com/github/gh-ost1.1.3GHSA-rrp4-2xx3-mv29
Gogithub.com/github/gh-ost1.1.3GO-2022-0298

Affected products (as reported)

VendorProductVersions
n/a n/a n/a

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

References