Skip to main content

Lean 4 CVE-2026-72711

| EUVDEUVD-2026-65142 MEDIUM
Improper Input Validation (CWE-20)
2026-08-24 disclosure@vulncheck.com GHSA-fhmq-xvc2-q54h
6.8
CVSS 4.0 · Vendor: vulncheck
Share

Severity by source

Vendor (vulncheck) PRIMARY
6.8 MEDIUM
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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
vuln.today AI
5.5 MEDIUM

AV:L because Lean code must be locally executed; PR:N since no elevated privileges are needed to write metaprograms; UI:R for required user compile or import action; I:H for complete logical soundness violation.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (vulncheck).

CVSS VectorVendor: vulncheck

Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
P
Scope
X

Lifecycle Timeline

4
Patch available
Aug 24, 2026 - 21:02 EUVD
Source Code Evidence Fetched
Aug 24, 2026 - 20:33 vuln.today
Analysis Generated
Aug 24, 2026 - 20:33 vuln.today
CVE Published
Aug 24, 2026 - 20:17 cve.org
MEDIUM 6.8

DescriptionCVE.org

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.

AnalysisAI

Lean 4's formal proof kernel accepts unsound opaque declarations due to a missing closure check in environment::add_opaque, enabling a metaprogram to admit a constant of type False without sorry, unsafeCast, or any unsafe mechanism - directly shattering the kernel's soundness guarantee. All Lean 4 versions before 4.32.2 are affected; a publicly available proof-of-concept at https://github.com/endrazine/lean-cve-poc-14484 confirms exploitability. …

Unlock full vulnerability intelligence

  • Risk assessment & exploitation conditions
  • Attack chain visualization
  • Remediation with exact patch versions
  • Threat intelligence from 22 sources
  • Personal watchlist & email alerts

Free forever · No credit card required

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata

Recon
technique details hidden
Delivery
technique details hidden
Exploit
technique details hidden
Install
technique details hidden
C2
technique details hidden
Execute
technique details hidden
Impact
technique details hidden

Vulnerability AssessmentAI

Exploitation Exploitation requires executing Lean 4 metaprogram code on an affected version (before 4.32.2) within a single type-checker instance where the inference cache is shared between the cache-priming step and the opaque declaration submission - a condition that holds in the standard Lean elaboration pipeline. … Additional conditions and limiting factors are described in the full assessment.
Risk Assessment The CVSS 4.0 score of 6.8 (AV:L/AC:L/AT:N/PR:N/UI:P/VI:H) accurately captures the attack profile: local execution of Lean 4 metaprogram code with no privileges required, but user interaction (compiling or importing the malicious file) is necessary. … Full risk analysis with EPSS, KEV, and SSVC signal comparison available after sign-in.
Exploit Scenario Full exploit scenario with step-by-step reproduction available after sign-in.
Remediation Upgrade Lean 4 to version 4.32.2 or later, which adds the missing closure check check_no_metavar_no_fvar to environment::add_opaque (see https://github.com/leanprover/lean4/pull/14498 for the exact one-line fix). … Detailed patch versions, workarounds, and compensating controls in full report.

Threat intelligence, references, and detailed analysis are available after sign-in.

Share

CVE-2026-72711 vulnerability details – vuln.today

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy