CVE-2022-31249
JSON

7.5high

[RANCHER] OS command injection in Rancher and Fleet

Severity
7.5high CVSS:3.1 by suse
Exploit likelihood
3.86% (higher than 90% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
suse
Also known as
GHSA-qrg7-hfx7-95c5GO-2023-1519

Description

A Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') vulnerability in wrangler of SUSE Rancher allows remote attackers to inject commands in the underlying host via crafted commands passed to Wrangler. This issue affects: SUSE Rancher wrangler version 0.7.3 and prior versions; wrangler version 0.8.4 and prior versions; wrangler version 1.0.0 and prior versions.

Affected

Product or packageVersionsReported by
SUSE Rancherfrom wrangler up to 0.7.3CVE List
github.com/rancher/wrangler (Go)before 0.7.4-security1, from 0.8.0 before 0.8.5-security1, from 1.0.0 before 1.0.1, from 0.8.6 before 0.8.11GitHub Advisory Database, Go Vulnerability Database
suse wranglerbefore 0.7.4, from 0.8.0 before 0.8.5, 1.0.0NVD

All scores

suse7.5high CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
GitHub7.5high CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
NVD9.8critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Classification

CWE-77CWE-78CWE-88

SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.

What each source says

CVE List

A Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') vulnerability in wrangler of SUSE Rancher allows remote attackers to inject commands in the underlying host via crafted commands passed to Wrangler. This issue affects: SUSE Rancher wrangler version 0.7.3 and prior versions; wrangler version 0.8.4 and prior versions; wrangler version 1.0.0 and prior versions.

GitHub Advisory Database
Impact

A command injection vulnerability was discovered in Wrangler's Git package affecting versions up to and including v1.0.0.

Wrangler's Git package uses the underlying Git binary present in the host OS or container image to execute Git operations. Specially crafted commands can be passed to Wrangler that will change their behavior and cause confusion when executed through Git, resulting in command injection in the underlying host.

Workarounds

A workaround is to sanitize input passed to the Git package to remove potential unsafe and ambiguous characters. Otherwise, the best course of action is to update to a patched Wrangler version.

Patches

Patched versions include v1.0.1 and later and the backported tags - v0.7.4-security1, v0.8.5-security1 and v0.8.11.

For more information

If you have any questions or comments about this advisory:

Go Vulnerability Database

A command injection vulnerability exists in the Wrangler Git package. Specially crafted commands can be passed to Wrangler that will change their behavior and cause confusion when executed through Git, resulting in command injection in the underlying host.

A workaround is to sanitize input passed to the Git package to remove potential unsafe and ambiguous characters. Otherwise, the best course of action is to update to a patched Wrangler version.

References

https://bugzilla.suse.com/show_bug.cgi?id=1200299issue-tracking, web
https://github.com/rancher/wrangler/security/advisories/GHSA-qrg7-hfx7-95c5web
https://nvd.nist.gov/vuln/detail/CVE-2022-31249advisory
https://github.com/rancher/wrangler/commit/12397eec50155cb2d24aa70bdf9e90c5f3b9a727web
https://github.com/rancher/wrangler/commit/341018c8fef3e12867c7cb2649bd2cecac75f287web
https://github.com/rancher/wrangler/commit/5a387e13e8d51e3340d9e5012a1951f0cca5fc90web
https://github.com/rancher/wrangler/commit/8649ecc062204f28764fd80157a621cbae89c9cfweb
https://github.com/advisories/GHSA-qrg7-hfx7-95c5advisory
https://github.com/rancher/wranglerpackage
https://github.com/rancher/wrangler/compare/v0.7.2...v0.7.4-security1web
https://github.com/rancher/wrangler/compare/v0.8.4...v0.8.5-security1web
https://pkg.go.dev/vuln/GO-2023-1519web

Sources

SourceRecordLicence
CVE ListCVE-2022-31249 changed 2025-03-25CVE Terms of Use
GitHub Advisory DatabaseGHSA-qrg7-hfx7-95c5 changed 2023-11-08CC-BY-4.0
Go Vulnerability DatabaseGO-2023-1519 changed 2024-05-20CC-BY-4.0
NVDCVE-2022-31249 changed 2026-06-17Public domain