Vyper: Storage corruption via @nonreentrant decorator
Summary
Vyper 0.2.13 before 0.2.15 allocates storage slots for @nonreentrant reentrancy locks at the same locations as contract storage variables. Calling a function marked @nonreentrant overwrites an overlapping storage variable, which corrupts contract state and breaks the intended logic. Smart contracts compiled with the affected Vyper versions are at risk, and an attacker without privileges may be able to trigger the bug through public functions, depending on the contract design.
Affected
- Vyper 0.2.13 up to but excluding 0.2.15 (vyperlang/vyper, PyPI package vyper)
- Contracts compiled with these versions that use @nonreentrant
Fixed in
- Vyper 0.2.15 (fix in PRs #2391 and #2379)
- Caution: according to a secondary source, a separate later bug in the reentrancy lock affects 0.2.15, 0.2.16 and 0.3.0, and that source reports a fix in 0.3.1. Verify this against the vendor advisory.
Workaround
- Do not use the @nonreentrant decorator in affected versions (this is a code change that requires reworking contract logic)
- No other workaround known.
Exploitation
Unknown whether this CVE is exploited in the wild. No public proof of concept found. CISA SSVC: exploitation none, not automatable. A 2023 attack on a Curve pool used a different Vyper reentrancy flaw, not this CVE.
Our recommendation
- Check whether Vyper is used, including indirect dependencies in lockfiles (e.g. eth-brownie).
- Identify contracts compiled with 0.2.13 or 0.2.14, and contracts using @nonreentrant that were compiled with 0.2.15 to 0.3.0.
- After a smart contract audit, recompile and redeploy with a current Vyper release; patching alone does not address the later lock bug.
- Relevant only for organisations building or operating blockchain or DeFi contracts; otherwise no action needed.
Public exploits
PoC-in-GitHub, Metasploit and Exploit-DB list nothing for this CVE.
Research sources
- GitHub Security Advisory GHSA-7f92-rr6w-cq64 github.com
- VulnCheck Advisory: Vyper Storage Corruption via @nonreentrant Decorator www.vulncheck.com
- OSV: GHSA-7f92-rr6w-cq64 osv.dev
- Vyper 0.2.15 release notes docs.vyperlang.org
- Tenable CVE-2021-48018 www.tenable.com
- Kodem CVE archive: GHSA-7f92-rr6w-cq64 www.kodemsecurity.com
- Highland Security: Vyper reentrancy 0-day post-mortem highlandsecurity.substack.com
Researched and written up in English and German by an AI (Claude by Anthropic) based on NVD, CISA, EPSS and the sources listed. The vendor information is authoritative. Researched on 1 Nov 2026, 13:28.
Original description (NVD)
Vyper from 0.2.13 before 0.2.15 allocates storage slots for @nonreentrant reentrancy locks at the same locations as contract storage variables. When a function using @nonreentrant is called, setting the lock overwrites the overlapping storage variable, corrupting contract state and breaking the contract's intended logic.
Sources
The tracker combines official, freely usable data sources – updated continuously:
- NVD (NIST) – CVEs, rating (CVSS), affected products
- CISA KEV – vulnerabilities confirmed by CISA as actively exploited
- CISA Vulnrichment – CISA assessment (SSVC) in the official CVE record
- FIRST EPSS – probability of exploitation
- Microsoft MSRC – Patch Tuesday: vulnerabilities, severity, updates
- PoC-in-GitHub – public proof-of-concept repositories
- Metasploit (Rapid7) – modules of the Metasploit Framework
- Exploit-DB (OffSec) – archive of public exploits (links only)
- Patch days: official vendor pages (linked per vendor) (Vendor patch days)
This product uses data from the NVD API but is not endorsed or certified by the NVD. EPSS data © FIRST.org.
Affected? We can help.
We check whether your systems are affected, install updates and close the gap – continuously with the System Health Checker if you wish.
