# Vyper memory corruption in nested function calls and tuples

Source: https://junglewise.ai/threats/vyper-memory-corruption-using-function-calls-within-tuples-nested-calls-c0689acb  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-10-06. Updated: 2026-10-06  
License: CC BY 4.0 with a link back

Severity: medium · Published 2026-10-06

Vyper is a programming language for writing smart contracts on Ethereum. When code contains nested function calls or function calls within tuples, a memory corruption bug can cause incorrect data to be written to or read from memory, potentially leading to contract logic failures or data integrity issues. Developers using vulnerable versions may deploy contracts with unpredictable behavior that could be exploited.

Technologies: [vyper (PyPI)](https://junglewise.ai/threats/technologies/vyper), [Vyper](https://junglewise.ai/threats/technologies/vyper-vyper). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi), [Vyper](https://junglewise.ai/threats/vendors/vyper).

## Quick answers

**Is This vulnerability exploited in the wild?** No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.

**How severe is This vulnerability?** Medium severity, published 6 October 2026.

**Which products and versions are affected?** vyper (PyPI) < 0.2.6; Vyper < 0.2.6.

**Is there a fix for This vulnerability?** Yes: fixed in 0.2.6. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is This vulnerability attacked?** It is attacked over the network, in a software library.

**Am I affected?** Check whether you run vyper (PyPI) or Vyper at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- Fixed in 0.2.6

## Technical details

The vulnerability is a memory corruption issue in the Vyper compiler that occurs when processing function calls inside tuples or as arguments to other function calls. The bug stems from an incorrect stack pointer calculation, causing the compiler to reference the wrong memory location. This is a compile-time issue affecting generated bytecode; any contract compiled with the vulnerable version contains the defect and is affected upon execution of the vulnerable code pattern.

## Affected products

- Vyper Vyper < 0.2.6

## Timeline

- 2020-10-10: disclosed
- 2020-10-10: patched

## References

- [https://github.com/vyperlang/vyper/security/advisories/GHSA-2r3x-4mrv-mcxf](https://github.com/vyperlang/vyper/security/advisories/GHSA-2r3x-4mrv-mcxf)

## Related threats

- [Vyper name resolution scope vulnerability in constants and defaults](https://junglewise.ai/threats/cve-2026-114663-vyper-0-4-0b1-through-0-5-0b1-miscompiles-unfoldable-constants)
- [Vyper create_from_blueprint offset validation bypass via unsigned wraparound](https://junglewise.ai/threats/cve-2026-114118-vyper-0-3-4-through-0-5-0b1-computes-the-remaining-blueprint)
- [Vyper optimizer miscompilation in ternary expressions](https://junglewise.ai/threats/cve-2026-114117-vyper-0-3-8-through-0-5-0b1-contains-an-optimizer-miscompilation)
- [Vyper source-line table parsing allows numeric literal value manipulation](https://junglewise.ai/threats/cve-2026-114116-vyper-0-1-0b1-before-0-1-0b17-and-0-4-1-through-0-5-0b1-builds)
- [Vyper source literal value substitution via multi-byte characters](https://junglewise.ai/threats/cve-2026-114114-vyper-0-1-0b1-before-0-1-0b12-0-1-0b14-and-0-4-1-through-0-5-0b1)
