CVE-2020-24370

Source
https://nvd.nist.gov/vuln/detail/CVE-2020-24370
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2020-24370.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2020-24370
Aliases
Downstream
Related
Published
2020-08-17T17:15:13Z
Modified
2025-10-21T05:47:06.543614Z
Severity
  • 5.3 (Medium) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L CVSS Calculator
Summary
[none]
Details

ldebug.c in Lua 5.4.0 allows a negation overflow and segmentation fault in getlocal and setlocal, as demonstrated by getlocal(3,2^31).

References

Affected packages

Git / github.com/lua/lua

Affected ranges

Type
GIT
Repo
https://github.com/lua/lua
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed

Affected versions

v1.*

v1.2

v2.*

v2.1
v2.2
v2.3-beta
v2.4
v2.4-beta
v2.5
v2.5-beta
v2.5.1

v3.*

v3.0
v3.0-alpha
v3.1
v3.1-alpha
v3.2
v3.2-beta

v4.*

v4.0
v4.0-alpha
v4.0-beta
v4.1-alpha

v5.*

v5.0
v5.0-alpha
v5.0-beta
v5.1
v5.1-alpha
v5.1-beta
v5.1.1
v5.2-alpha
v5.2-beta
v5.2.0
v5.2.1
v5.2.2
v5.3-alpha
v5.3-beta
v5.3.0
v5.3.1
v5.3.2
v5.3.3
v5.3.4
v5.4-alpha
v5.4-beta
v5.4-w2
v5.4.0

Database specific

vanir_signatures

[
    {
        "signature_version": "v1",
        "source": "https://github.com/lua/lua/commit/a585eae6e7ada1ca9271607a4f48dfb17868ab7b",
        "deprecated": false,
        "id": "CVE-2020-24370-3408fa99",
        "target": {
            "function": "luaG_findlocal",
            "file": "ldebug.c"
        },
        "digest": {
            "function_hash": "160457310741932794514906761248697216809",
            "length": 606.0
        },
        "signature_type": "Function"
    },
    {
        "signature_version": "v1",
        "source": "https://github.com/lua/lua/commit/a585eae6e7ada1ca9271607a4f48dfb17868ab7b",
        "deprecated": false,
        "id": "CVE-2020-24370-a6e6ec70",
        "target": {
            "function": "findvararg",
            "file": "ldebug.c"
        },
        "digest": {
            "function_hash": "176948320927037737175998274991413929359",
            "length": 298.0
        },
        "signature_type": "Function"
    },
    {
        "signature_version": "v1",
        "source": "https://github.com/lua/lua/commit/a585eae6e7ada1ca9271607a4f48dfb17868ab7b",
        "deprecated": false,
        "id": "CVE-2020-24370-caf2fa2e",
        "target": {
            "file": "ldebug.c"
        },
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "308106254715576835832771124558186333737",
                "28150857163617153757180128882987340278",
                "67856167705625202229537381893379792047",
                "118168772934001778875555195425693302437",
                "316101619877408557194703765822106706457",
                "103962487352111355186447672861982043630",
                "180146486087139942444320654781720975268",
                "293123111573401127190810486268369394313",
                "110117011450095061191785096815592359580"
            ]
        },
        "signature_type": "Line"
    }
]