CVE-2026-72711
published medium CVSS 4.0 · 6.8Lean 4 before 4.32.2 Kernel Accepts Opaque Declaration With an Unbound Free Variable
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| leanprover | — | lean40 to < 4.32.2 · Other versions: unaffected | Affected | Not stated | VulnCheck |
Description
The Lean 4 kernel does not check that the body of an opaque declaration is closed. environment::add_opaque omits the check_no_metavar_no_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.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 4.0
- Base score
- 6.8 / 10
- Severity
- medium
- Provider
- VulnCheck · cna
- Vector string
- 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
Additional Assessments
| Version | Score | Severity | Provider | Vector | Scenarios |
|---|---|---|---|---|---|
| 3.1 | 6.3 | medium | VulnCheck · cna | CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N | — |
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| leanprover | lean4 | 0 to < 4.32.2 (affected · semver)Default: unaffected | VulnCheck · cna |
Weaknesses
1- CWE-20 Improper Input Validation
References
6- http://www.openwall.com/lists/oss-security/2026/10/26/3
- https://github.com/endrazine/lean-cve-poc-14484
- https://github.com/leanprover/lean4
- https://github.com/leanprover/lean4/issues/14484
- https://github.com/leanprover/lean4/pull/14498
- VulnCheck Advisory: Lean 4 before 4.32.2 Kernel Accepts Opaque Declaration With an Unbound Free Variable https://www.vulncheck.com/advisories/lean-4-before-kernel-accepts-opaque-declaration-with-an-unbound-free-variable
Provider assertions
3VulnCheck · cna
Lean 4 before 4.32.2 Kernel Accepts Opaque Declaration With an Unbound Free Variable
CISA-ADP · adp
CISA ADP Vulnrichment
CVE · adp
CVE Program Container
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 6bc81315cfc748a612b28891e780ca51c0658a963ab25ef58622a9bb90bbc938
- Ingested
- 26 Oct 2026, 01:40:59 UTC
- Source record
- Official CVE record