Vulnerability in Leanprover Lean4
CVE-2026-72844
- CVSS v3
- 6.3 Medium
- Public exploits
- 1 repository
- EPSS
- 0.002 · 8.3th percentile
- Published
- 2026-08-20
The Lean 4 kernel does not verify that the structure named in a projection expression matches the type of the value being projected, and environment::add_inductive in src/kernel/inductive.cpp did not type check the nested inductive applications that are replaced by auxiliary types, so their parametric arguments escaped checking. A metaprogram running in the Lean process can register an ill-typed nested inductive whose constructor applies a .proj C 0 projection to a value of the unrelated type W, and the kernel admits the declaration through the ordinary checked addDecl path at maximum kernel checking, without sorry, unsafeCast, debug.skipKernelTC, addDeclWithoutChecking, FFI, or a modified .olean file. The result is a type confusion yielding a proof of False that carries no axioms, from which any proposition can be derived. The published proof of concept additionally pads two expressions until their hashes and approximate depths collide, which defeats kernel caching; that is the technique used to reach the flaw, not its cause. Exploitation requires running a metaprogram in-process, for example by building a project or importing a malicious Lake dependency.
Published · last modified .
CVSS v3 metric
CVSS v3 base score 6.3 (Medium). Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N.
- Attack Vector
- Local
AV:L - Attack Complexity
- Low
AC:L - Privileges Required
- None
PR:N - User Interaction
- Required
UI:R - Scope
- Changed
S:C - Confidentiality
- None
C:N - Integrity
- High
I:H - Availability
- None
A:N
EPSS exploit prediction
EPSS 0.002, 8.3th percentile (last changed ); unchanged over 30 days. About EPSS.
Affected products
- Leanprover Lean4 — versions 4.33.0-rc1
Weakness classification (CWE)
Public exploits and proof-of-concept code
1 public repository with exploit or proof-of-concept code for this CVE:
- endrazine/lean-cve-poc (26 stars, last pushed 2026-08-22): CVE-2026-72844 : Example of proving "0 = 1" using a vulnerability in the Lean 4 kernel.
References
- GitHub Issue #14576 (issue-tracking)
- fix: missing check at kernel inductive declaration (patch)
- GitHub Pull Request #14577 (issue-tracking, patch)
- lean-cve-poc (exploit)
- CollatzLean (exploit)
- oss-security: Lean 4 kernel soundness bug (third-party-advisory)
- github.com/leanprover/lean4 (product)
- VulnCheck Advisory: Lean 4 Kernel Type Checking Bypass via Mismatched Structure Projections (third-party-advisory)
- www.openwall.com/lists/oss-security/2026/10/26/2
This CVE has public exploit evidence. See the latest CVEs with public exploits.