cve.bz

CVE-2024-58266 comex shlex: Improper Encoding or Escaping of Output

9.8 criticalEPSS 0.8%Fix available

Critical (9.8) in comex shlex. EPSS 0.8% estimated probability of exploitation activity in the next 30 days. Fixed in shlex 1.3.0.

On this page
The shlex crate before 1.2.1 for Rust allows unquoted and unescaped instances of the { and \xa0 characters, which may facilitate command injection.

Severity

CVSS 3.1

9.8 critical
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS
0.8% (unchanged from 0.8% a week ago; 0.8% 30 days ago) estimated probability of exploitation activity in the next 30 days; 57th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: no · Technical impact: partial, assessed 2025-07-28. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-116 Improper Encoding or Escaping of Output
OWASP Top 10
A05:2025 Injection
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2024-58266 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2024-58266?via=ask-ai-copy and https://cve.bz/cve/CVE-2024-58266?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2024-58266 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
comex shlexbefore 1.2.1

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-r7qv-8r2h-pg27crates.ioshlex<1.3.01.3.0
RUSTSEC-2024-0006crates.ioshlex>=0.0.0-0 <1.3.01.3.0

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12rust-shlexno fix listedDEBIAN-CVE-2024-58266
Debian13, 14rust-shlex1.3.0-1DEBIAN-CVE-2024-58266
Ubuntu20.04:LTS, 22.04:LTS, 24.04:LTS and 3 morerust-shlexno fix listedUBUNTU-CVE-2024-58266
SUSELinux Enterprise Module for Basesystem 15 SP6, Linux Enterprise Module for Basesystem 15 SP7rav1e0.6.6-150600.3.6.1SUSE-SU-2025:03077-1
SUSELinux Micro 6.0rust-keylime0.2.8+12-1.1SUSE-SU-2025:20717-1
SUSELinux Micro 6.1rust-keylime0.2.8+12-slfo.1.1_1.1SUSE-SU-2025:20858-1
openSUSELeap 15.6rav1e0.6.6-150600.3.6.1SUSE-SU-2025:03077-1
openSUSETumbleweedframework-inputmodule-control0.2.0-3.1openSUSE-SU-2025:15433-1
Azure Linux2kata-containersno fix listedAZL-66008
Azure Linux2rustno fix listedAZL-66017
Azure Linux3rust1.75.0-30AZL-66029
Azure Linux3rust1.86.0-3AZL-66035

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; SUSE security data, CC BY 4.0; Microsoft's Azure Linux vulnerability data, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · SUSE · openSUSE.

Red Hat

Red Hat rates this Low.

Red Hat's statement

This CVE was rated as Low severity. It involves three distinct issues: (1) Failure to quote characters, which can cause a single argument to be interpreted as multiple arguments in a shell, but does not directly allow arbitrary command execution; (2) Handling of null bytes in strings, which cannot be used in Unix command arguments or environment variables, making exploitation in typical environments unlikely; and (3) Lack of escaping for control characters in interactive shells, where writing control characters to the input of an interactive shell could cause misbehavior, though non-interactive shells are unaffected. Exploitation of these issues requires high attack complexity and targeting of uncommon scenarios. The overall impact is limited, and the affected scenarios are constrained in typical usage. Considering the high attack complexity, restricted exploitability, and limited impact, a Low severity rating is appropriate.

Red Hat's mitigation

Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.

ProductPackageStateAdvisory
Confidential Compute Attestationconfidential-compute-attestation-tech-preview/trustee-rhel9Not affected
Logging Subsystem for Red Hat OpenShiftopenshift-logging/cluster-logging-operator-bundleFix deferred
Logging Subsystem for Red Hat OpenShiftopenshift-logging/cluster-logging-rhel9-operatorFix deferred
Logging Subsystem for Red Hat OpenShiftopenshift-logging/eventrouter-rhel9Fix deferred
Logging Subsystem for Red Hat OpenShiftopenshift-logging/log-file-metric-exporter-rhel9Fix deferred
Logging Subsystem for Red Hat OpenShiftopenshift-logging/vector-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh-dev-preview-beta/istio-ztunnel-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-cni-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-must-gather-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-pilot-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-proxyv2-rhel9Fix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-rhel9-operatorFix deferred
OpenShift Service Mesh 3openshift-service-mesh/istio-sail-operator-bundleFix deferred
Red Hat Directory Server 11redhat-ds:11/389-ds-baseNot affected
Red Hat Discovery 2discovery/discovery-server-rhel9Not affected
Red Hat Enterprise Linux 10389-ds-baseNot affected
Red Hat Enterprise Linux 10aardvark-dnsNot affected
Red Hat Enterprise Linux 10bootcNot affected
Red Hat Enterprise Linux 10clevis-pin-tpm2Not affected
Red Hat Enterprise Linux 10device-mapper-persistent-dataNot affected
56 more in the JSON and on Red Hat's page.

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2024-58266.

Attack patterns (CAPEC)

  • CAPEC-73 User-Controlled Filename Likelihood: High · Severity: High
  • CAPEC-81 Web Server Logs Tampering Likelihood: Medium · Severity: High
  • CAPEC-85 AJAX Footprinting Likelihood: High · Severity: Low
  • CAPEC-104 Cross Zone Scripting Likelihood: Medium · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON