CVE-2026-18370

Source
https://cve.org/CVERecord?id=CVE-2026-18370
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-18370.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-18370
Downstream
Published
2026-08-10T12:56:34.454Z
Modified
2026-08-12T16:24:48.175100Z
Severity
  • 4.8 (Medium) CVSS_V4 - CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N CVSS Calculator
Summary
Heap-based buffer overflow in entr
Details

entr is vulnerable to Heap-based buffer overflow in runutility() function. The function allocates a fixed-size heap buffer using malloc(ARGMAX) and copies command-line arguments into it. It advances the destination pointer based on the return value of strlcpy(), which returns the total length of the source string rather than the number of bytes written. When the buffer is exactly filled, the remaining size underflows as an unsigned sizet, causing subsequent copies to write out of bounds. This can be triggered by supplying command-line arguments whose combined length fills the buffer, or via the / substitution feature which expands a short token into a longer pathname at runtime. The local attacker can cause memory corruption, process abort, and denial of service. 

This issue was fixed in commit 2467fe0

Database specific
{
    "cwe_ids": [
        "CWE-122"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/18xxx/CVE-2026-18370.json",
    "cna_assigner": "CERT-PL"
}
References

Affected packages

Git / github.com/eradman/entr

Affected ranges

Type
GIT
Repo
https://github.com/eradman/entr
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Database specific
Show details
{
    "extracted_events": [
        {
            "introduced": "0"
        },
        {
            "last_affected": "5.8"
        }
    ],
    "source": [
        "AFFECTED_FIELD",
        "REFERENCES"
    ]
}

Affected versions

1.*
1.0
1.1
1.2
1.3
1.4
1.5
1.6
1.7
1.8
1.9
2.*
2.0
2.1
2.2
2.3
2.4
2.5
2.6
2.7
2.8
2.9
3.*
3.0
3.1
3.2
3.3
3.4
3.5
3.6
3.7
3.8
3.9
4.*
4.0
4.1
4.2
4.4
4.5
4.6
4.7
4.8
4.9
5.*
5.0
5.1
5.2
5.3
5.4
5.5
5.6
5.7
5.8

Database specific

vanir_signatures_modified
"2026-08-12T16:24:48Z"
vanir_signatures
[
    {
        "id": "CVE-2026-18370-6a021648",
        "deprecated": false,
        "signature_type": "Function",
        "signature_version": "v1",
        "digest": {
            "length": 1718.0,
            "function_hash": "276606393004605122152861407540889898263"
        },
        "source": "https://github.com/eradman/entr/commit/2467fe0aa5f2b1b074110a9186ef51d35809c9a4",
        "target": {
            "function": "run_utility",
            "file": "entr.c"
        }
    },
    {
        "id": "CVE-2026-18370-91649ddd",
        "deprecated": false,
        "signature_type": "Line",
        "signature_version": "v1",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "269975521854743244551355607164671995131",
                "31179057363200452603020407363956537160",
                "253807624859640318489896242095082929429",
                "256940127245833804332100564230463112302",
                "157282998715602790763209993625110581473",
                "294418611756353865155733645814392882559",
                "218738410719447917971631019666648619093",
                "166550865639109025354653581228856146352",
                "146186445451325385753754557223228989192",
                "252318302088992255806393236776113469526",
                "321156796876200768883322691812981217980",
                "113092171757042819869650263397396597689",
                "79362782607812667333055954473706226538",
                "299773467512851013738044028931377805912",
                "156023305720868709331982817426511173624",
                "86215291507037079813073828338944721447",
                "102767061800365379016946732456318145351",
                "209981164888847855159403898279739563785",
                "3438109003332299407140334041673344136",
                "288592917407306500746510892187381158348",
                "52738834039411281678812245340434842924",
                "334191224839529287660117934541389228704",
                "272237902367988918566252924293017707484"
            ]
        },
        "source": "https://github.com/eradman/entr/commit/2467fe0aa5f2b1b074110a9186ef51d35809c9a4",
        "target": {
            "file": "entr.c"
        }
    }
]
source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-18370.json"