CVE-2021-45985

Source
https://cve.org/CVERecord?id=CVE-2021-45985
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-45985.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2021-45985
Aliases
Downstream
Published
2023-04-10T09:15:07.250Z
Modified
2026-04-11T23:37:26.877110Z
Severity
  • 7.5 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H CVSS Calculator
Summary
[none]
Details

In Lua 5.4.3, an erroneous finalizer called during a tail call leads to a heap-based buffer over-read.

References

Affected packages

Git / github.com/lua/lua

Affected ranges

Type
GIT
Repo
https://github.com/lua/lua
Events
Database specific
{
    "versions": [
        {
            "introduced": "5.4.0"
        },
        {
            "fixed": "5.4.4"
        }
    ]
}

Affected versions

v5.*
v5.4.0
v5.4.1
v5.4.2
v5.4.3

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-45985.json"
vanir_signatures_modified
"2026-04-11T23:37:26Z"
vanir_signatures
[
    {
        "signature_version": "v1",
        "signature_type": "Line",
        "source": "https://github.com/lua/lua/commit/cf613cdc6fa367257fc61c256f63d917350858b5",
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "33833490466441759291322153683438719705",
                "84369104082086107190645463707502174029",
                "295511310105421369746384700970995315737",
                "12203473177769128110561359607199773707",
                "315007898064505767868322756796827846696",
                "278707840460729215257930947771055151307",
                "289853073820757707898851752461450092833",
                "79699182784658544092265369729132165017"
            ]
        },
        "id": "CVE-2021-45985-607c555b",
        "deprecated": false,
        "target": {
            "file": "ldo.c"
        }
    },
    {
        "signature_version": "v1",
        "signature_type": "Function",
        "source": "https://github.com/lua/lua/commit/cf613cdc6fa367257fc61c256f63d917350858b5",
        "digest": {
            "function_hash": "74565152130787818120172892330726743781",
            "length": 1036.0
        },
        "id": "CVE-2021-45985-fe306226",
        "deprecated": false,
        "target": {
            "file": "ldo.c",
            "function": "luaD_pretailcall"
        }
    }
]