Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. vyper
  4. ›
  5. CVE-2025-21607

CVE-2025-21607: Vyper Does Not Check the Success of Certain Precompile Calls

January 14, 2025 (updated April 24, 2025)

When the Vyper Compiler uses the precompiles EcRecover (0x1) and Identity (0x4), the success flag of the call is not checked. As a consequence an attacker can provide a specific amount of gas to make these calls fail but let the overall execution continue. Then the execution result can be incorrect.

Based on EVM’s rules, after the failed precompile the remaining code has only 1/64 of the pre-call-gas left (as 63/64 were forwarded and spent). Hence, only fairly simple executions can follow the failed precompile calls. Therefore, we found no significantly impacted real-world contracts.

The fix is tracked in https://github.com/vyperlang/vyper/pull/4451.

References

  • github.com/advisories/GHSA-vgf2-gvx8-xwc3
  • github.com/pypa/advisory-database/tree/main/vulns/vyper/PYSEC-2025-33.yaml
  • github.com/vyperlang/vyper
  • github.com/vyperlang/vyper/commit/7136eab0a254aa2ff7ddca41cc05f2ee1fa99caf
  • github.com/vyperlang/vyper/pull/4451
  • github.com/vyperlang/vyper/security/advisories/GHSA-vgf2-gvx8-xwc3
  • nvd.nist.gov/vuln/detail/CVE-2025-21607

Code Behaviors & Features

Detect and mitigate CVE-2025-21607 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions

Solution

Unfortunately, there is no solution available yet.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

Learn more about CVSS

Weakness

  • CWE-670: Always-Incorrect Control Flow Implementation
  • CWE-703: Improper Check or Handling of Exceptional Conditions

Source file

pypi/vyper/CVE-2025-21607.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:14:42 +0000.