CVE-2026-72711

Source
https://cve.org/CVERecord?id=CVE-2026-72711
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-72711.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-72711
Published
2026-08-24T20:08:33.219Z
Modified
2026-08-27T11:47:48.163816222Z
Severity
  • 6.8 (Medium) CVSS_V4 - CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N CVSS Calculator
Summary
Lean 4 before 4.32.2 Kernel Accepts Opaque Declaration With an Unbound Free Variable
Details

The Lean 4 kernel does not check that the body of an opaque declaration is closed. environment::addopaque omits the checknometavarno_fvar call that the definition and theorem paths perform, so a value containing a free variable that is absent from the local context is not rejected outright. A metaprogram can first cause the kernel to create a temporary local of type False and record its type in the type checker's inference cache, then restore the local context while that cache entry persists on the same type checker instance, and finally submit an opaque declaration whose value is the now-unbound variable. The cache lookup answers before the branch that would test membership of the local context, so the kernel infers the cached type and admits an opaque constant of type False, from which any proposition follows. The declaration is accepted through the ordinary checked path at maximum kernel checking, without sorry, unsafeCast, debug.skipKernelTC, addDeclWithoutChecking, foreign code or a modified .olean file, and the result carries no axioms. Fixed in 4.32.2 by adding the missing closure check.

Database specific
{
    "cwe_ids": [
        "CWE-20"
    ],
    "cna_assigner": "VulnCheck",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/72xxx/CVE-2026-72711.json"
}
References

Affected packages

Git / github.com/leanprover/lean4

Affected ranges

Type
GIT
Repo
https://github.com/leanprover/lean4
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Database specific
Show details
{
    "source": "AFFECTED_FIELD",
    "extracted_events": [
        {
            "introduced": "0"
        },
        {
            "fixed": "4.32.2"
        }
    ]
}

Affected versions

Other
CADE25
ICFP19
ICFP20
IFL
IFL19
IJCAR20
IJCAR20-LMCS
NFM2022
cade2021
cade21
nightly-2018-03-19
nightly-2018-03-26
nightly-2018-03-27
nightly-2018-03-29
nightly-2018-03-30
nightly-2018-04-02
nightly-2018-04-06
nightly-2018-04-10
popl_17
popl_2017
popl_paris_2017
test1
test2
v3.*
v3.0.0
v3.1.0
v3.2.0
v3.3.0
v4.*
v4.0.0-M1
v4.0.0-m1
v4.0.0-m2
v4.0.0-m3
v4.0.0-m4
v4.0.0-m5
v4.0.0-rc1
v4.0.0-rc2
v4.0.0-rc3
v4.0.0-rc4
v4.12.0-rc1
v4.32.0
v4.32.0-rc1
v4.32.1

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-72711.json"