PatchSiren

PatchSiren cyber security CVE debrief

CVE-2026-72711 leanprover CVE debrief

A vulnerability in the Lean 4 kernel allows an attacker to submit an opaque declaration with an unbound free variable, potentially leading to type confusion and security issues. The issue arises from the lack of a closure check in the environment::add_opaque function. This vulnerability can be exploited through a metaprogram that manipulates the type checker's inference cache.

Vendor
leanprover
Product
lean4
CVSS
MEDIUM 6.8
CISA KEV
Not listed in stored evidence
Original CVE published
2026-08-24
Original CVE updated
2026-09-24
Advisory published
2026-08-24
Advisory updated
2026-09-24

Who should care

Developers and users of the Lean 4 kernel, particularly those working with metaprograms or opaque declarations, should review and update to version 4.32.2 or later, implement additional checks, and monitor for potential exploits to prevent type confusion and security issues due to unbound free variables.

Why it matters

The vulnerability in the Lean 4 kernel allows for potential type confusion and security issues due to the lack of a closure check in opaque declarations. Developers and users of the Lean 4 kernel should review and update to version 4.32.2 or later, implement additional checks, and monitor for potential exploits.

  • Potential type confusion and security issues due to unbound free variables
  • Exploitation through metaprograms manipulating the type checker's inference cache
  • Need for additional checks and monitoring to prevent potential exploits

Technical summary

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, allowing a value with a free variable to be accepted. A metaprogram can exploit this by creating a temporary local of type False, recording its type in the type checker's inference cache, restoring the local context, and submitting an opaque declaration with an unbound variable.

Defensive priority

High

Recommended defensive actions

  • Review and update Lean 4 kernel to version 4.32.2 or later
  • Implement additional checks for opaque declarations
  • Monitor for potential exploits
  • Confirm whether affected product deployments exist in managed environments and assign an owner for follow-up
  • Plan vendor-supported updates or mitigations through normal change control where exposure is confirmed
  • Review compensating controls for exposed systems while remediation is scheduled and verified
  • Check relevant monitoring, detection, and logs for exposed assets that need extra review

Evidence notes

The vulnerability is caused by the omission of the check_no_metavar_no_fvar call in the environment::add_opaque function. A metaprogram can exploit this by creating a temporary local of type False, recording its type in the type checker's inference cache, restoring the local context, and then submitting an opaque declaration with an unbound variable.

Sources and references

Verified primary and authoritative sources

  • CVE-2026-72711 CVE Program record

    Publisher, destination, and source semantics verified

    URL: https://www.cve.org/CVERecord?id=CVE-2026-72711

    CVE Program - Official CVE Program record with source-provided CVE metadata.

  • CVE-2026-72711 NVD vulnerability detail

    Publisher, destination, and source semantics verified

    URL: https://nvd.nist.gov/vuln/detail/CVE-2026-72711

    NIST National Vulnerability Database - Official NIST NVD detail page and source-specific vulnerability assessment.

Supplemental references

Methodology and review provenance

AI-assisted synthesis based on stored public vulnerability evidence. System validation, approval state, and publication status do not by themselves establish human review of this revision. PatchSiren helps prioritize defensive review and does not prove exposure or remediation on any system.