CVE-2025-26622

sqrt doesn't define rounding behavior in Vyper

Published Feb 21, 2025 CVSS 4.0 · 2.3 Low EPSS < 1% KEV · Not listed
Description
vyper is a Pythonic Smart Contract Language for the EVM. Vyper `sqrt()` builtin uses the babylonian method to calculate square roots of decimals. Unfortunately, improper handling of the oscillating final states may lead to sqrt incorrectly returning rounded up results. This issue is being addressed and a fix is expected in version 0.4.1. Users are advised to upgrade as soon as the patched release is available. There are no known workarounds for this vulnerability.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
EUVD EUVD EUVD-2025-4284 Vyper's sqrt doesn't define rounding behavior
Github GHSA Github GHSA GHSA-2p94-8669-xg86 Vyper's sqrt doesn't define rounding behavior
History
Type Values Removed Values Added
First Time appeared Vyperlang
Vyperlang vyper
Weaknesses NVD-CWE-noinfo
CPEs cpe:2.3:a:vyperlang:vyper:*:*:*:*:*:python:*:*
Vendors & Products Vyperlang
Vyperlang vyper
Type Values Removed Values Added
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N'}

ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description vyper is a Pythonic Smart Contract Language for the EVM. Vyper `sqrt()` builtin uses the babylonian method to calculate square roots of decimals. Unfortunately, improper handling of the oscillating final states may lead to sqrt incorrectly returning rounded up results. This issue is being addressed and a fix is expected in version 0.4.1. Users are advised to upgrade as soon as the patched release is available. There are no known workarounds for this vulnerability.
Title sqrt doesn't define rounding behavior in Vyper
Weaknesses CWE-682
References
Metrics cvssV4_0

{'score': 2.3, 'vector': 'CVSS:4.0/AV:N/AC:H/AT:P/PR:L/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Feb 22, 2025, 3:34 PM
Reserved
Feb 12, 2025, 2:51 PM
Status
Analyzed
Published
Feb 21, 2025, 10:15 PM
Modified
Jun 17, 2026, 9:02 AM