CVE-2024-25817: Eza Eza Potential Heap Overflow Vulnerability Vulnerability

HIGH
Advisory Identifier: GHSA-3qx3-6hxr-j2ch
CVSS 8.4
Published
Advisory Summary

CVE-2024-25817 is a HIGH (CVSS 8.4) eza potential heap overflow vulnerability vulnerability (General Security Weakness) affecting Eza libraries in the crates.io ecosystem. The issue involves eza potential heap overflow vulnerability for aarch64. Remediation is available by upgrading affected packages to version 0.18.2.

CVE-2024-25817 at a Glance

CVE Identifier CVE-2024-25817
GHSA Identifier GHSA-3qx3-6hxr-j2ch
Severity HIGH
CVSS v3.1 Base Score 8.4
CWE Classification General Security Weakness
Affected Product Eza
Package Ecosystem crates.io
Published Date
Last Updated

Security Impact

CVSS: 8.4

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).

Attack Vector Local (AV:L)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2024-25817

To remediate this vulnerability, upgrade all affected Eza dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

eza fixed: 0.18.2
Upgrade eza to 0.18.2
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for eza

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-25817, inspect your project dependencies for Eza:

inspect dependencies for eza

Analyze the terminal output to locate any version of Eza in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.18.2), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under General Security Weakness. In Eza, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary In `eza`, there exists a potential heap overflow vulnerability, first seen when using Ubuntu for Raspberry Pi series system, on `ubuntu-raspi` kernel, relating to the `.git` directory. ### Details The vulnerability seems to be triggered by the `.git` directory in some projects. This issue may be related to specific files, and the directory structure also plays a role in triggering the vulnerability. Files/folders that may be involved in triggering the vulnerability include `.git/HEAD`, `.git/refs`, and `.git/objects`. As @polly pointed out to me, this is likely caused by [GHSA-j2v7-4f6v-gpg8](https://github.com/libgit2/libgit2/security/advisories/GHSA-j2v7-4f6v-gpg8), which we do seem to use currently. ### PoC For more information check @CuB3y0nd's blogpost [blog](https://www.cubeyond.net/blog/eza-cve-report). ### Impact Arbitrary code execution.

CVE-2024-25817 Affected Eza Versions

1 component(s)
Fixed Versions:
0.18.2
Product / Package Ecosystem Affected Versions Fixed Version
eza
crates.io
< 0.18.2
0.18.2

References

Frequently Asked Questions

What is CVE-2024-25817?
CVE-2024-25817 is a security vulnerability in Eza involving eza Potential Heap Overflow Vulnerability for AArch64 under General Security Weakness.
Which Eza versions are affected?
Affected versions include releases prior to 0.18.2 across affected packages: eza.
What version fixes CVE-2024-25817?
Upgrading to 0.18.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is eza affected?
Yes, eza is affected in releases prior to 0.18.2. Upgrade your dependency to 0.18.2 or later.
What is the CVSS score of CVE-2024-25817?
CVE-2024-25817 has a CVSS v3.1 base score of 8.4 (HIGH) with vector string CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2024-25817?
CVE-2024-25817 is classified under General Security Weakness.
How can I check crates.io dependencies for CVE-2024-25817?
Run the dependency tree command: 'inspect dependencies for eza'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-3qx3-6hxr-j2ch",
  "modified" : "2024-03-06T15:34:20Z",
  "published" : "2024-02-08T18:47:28Z",
  "aliases" : [ "CVE-2024-25817" ],
  "summary" : "eza Potential Heap Overflow Vulnerability for AArch64",
  "details" : "### Summary\nIn `eza`, there exists a potential heap overflow vulnerability, first seen when using Ubuntu for Raspberry Pi series system, on `ubuntu-raspi` kernel, relating to the `.git` directory.\n\n### Details\nThe vulnerability seems to be triggered by the `.git` directory in some projects. This issue may be related to specific files, and the directory structure also plays a role in triggering the vulnerability. Files/folders that may be involved in triggering the vulnerability include `.git/HEAD`, `.git/refs`, and `.git/objects`.\n\nAs @polly pointed out to me, this is likely caused by [GHSA-j2v7-4f6v-gpg8](https://github.com/libgit2/libgit2/security/advisories/GHSA-j2v7-4f6v-gpg8), which we do seem to use currently.\n\n### PoC\nFor more information check @CuB3y0nd's blogpost [blog](https://www.cubeyond.net/blog/eza-cve-report).\n\n### Impact\nArbitrary code execution.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "eza"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.18.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/eza-community/eza/security/advisories/GHSA-3qx3-6hxr-j2ch"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/eza-community/eza/commit/47c9b90368c49117ba42760bd58acafa3362cbd4"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/eza-community/eza"
  } ],
  "database_specific" : {
    "cwe_ids" : [ ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-02-08T18:47:28Z",
    "nvd_published_at" : null
  }
}