CVE-2025-27105: AugAssign evaluation order causing OOB write within the object in Vyper
Vyper handles AugAssign statements by first caching the target location to avoid double evaluation. However, in the case when target is an access to a DynArray and the rhs modifies the array, the cached target will evaluate first, and the bounds check will not be re-evaluated during the write portion of the statement. In other words, the following code is equivalent to: rather than:
Published Feb 21, 2025 · Updated Apr 9, 2025
Affected packages
vyper
- Ecosystem
- PyPI
- Affected
- <= 0.4.0
- Fixed in
- 0.4.1
- Check
pip show vyper
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Vyper handles AugAssign statements by first caching the target location to avoid double evaluation. However, in the case when target is an access to a DynArray and the rhs modifies the array, the cached target will evaluate first, and the bounds check will not be re-evaluated during the write portion of the statement. In other words, the following code
def poc():
a: DynArray[uint256, 2] = [1, 2]
a[1] += a.pop()is equivalent to:
def poc():
a: DynArray[uint256, 2] = [1, 2]
a[1] += a[len(a) - 1]
a.pop()rather than:
def poc():
a: DynArray[uint256, 2] = [1, 2]
s: uint256 = a[1]
t: uint256 = a.pop()
a[1] = s + t # reverts due to oob accessReferences
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More PyPI vulnerabilities
All PyPI entriesGHSA-2r3x-4mrv-mcxf
Vyper: Memory corruption using function calls within tuples / nested calls
medium6.9Oct 6, 2026GHSA-4v7v-gqf9-ww2g
Vyper: Call stack corruption when passing complex type containing non-base type members as argument
medium6.9Oct 6, 2026GHSA-vg88-3v92-rjx2
Vyper: Return inside for loop more than 1 level deep
medium6.3Oct 6, 2026CVE-2025-47285
Vyper's `concat()` builtin may elide side-effects for zero-length arguments
low2.9No fixMay 16, 2025CVE-2025-47774
Vyper's `slice()` may elide side-effects when output length is 0
low2.9No fixMay 16, 2025CVE-2025-26622
Vyper's sqrt doesn't define rounding behavior
low2.3Feb 21, 2025
