GHSA-4v7v-gqf9-ww2g: Vyper Call Stack Corruption When Passing Vulnerability
MODERATEGHSA-4v7v-gqf9-ww2g is a MODERATE call stack corruption when passing vulnerability (CWE-682: Incorrect Calculation) affecting Vyper libraries in the PyPI ecosystem. The issue involves call stack corruption when passing complex type containing non-base type members as argument. Remediation is available by upgrading affected packages to version 0.2.6.
GHSA-4v7v-gqf9-ww2g at a Glance
How to Fix GHSA-4v7v-gqf9-ww2g
To remediate this vulnerability, upgrade all affected Vyper dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install vyper>=0.2.6
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show vyper
How to Check if You Are Affected
To determine whether your Python environment is affected by GHSA-4v7v-gqf9-ww2g, inspect your installed packages using pip:
pip show vyper
Analyze the terminal output to locate any version of Vyper in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.2.6), your application is affected.
Note: The pip show vyper command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-682: Incorrect Calculation, where the product performs a calculation that generates incorrect or unintended results that are later used in security-critical decisions or resource management. In Vyper, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-4v7v-gqf9-ww2g Affected Vyper Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
vyper
|
PyPI |
< 0.2.6
|
0.2.6
|
References
Frequently Asked Questions
What is GHSA-4v7v-gqf9-ww2g?
Which Vyper versions are affected?
What version fixes GHSA-4v7v-gqf9-ww2g?
Is vyper affected?
What CWE is associated with GHSA-4v7v-gqf9-ww2g?
How can I check PyPI dependencies for GHSA-4v7v-gqf9-ww2g?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-4v7v-gqf9-ww2g",
"modified" : "2026-10-06T15:22:23Z",
"published" : "2026-10-06T15:22:23Z",
"aliases" : [ ],
"summary" : "Vyper: Call stack corruption when passing complex type containing non-base type members as argument",
"details" : "### Impact\nWhen we pass a multi-dimensional array (like `[[1, 2], [3, 4]]`) as an argument to internal/external functions we get incorrect output. This is due to a stack management issue, because it was assumed that the size of each subtype of an array/struct is 32, which is not always correct.\n\nExample code:\n```python\n@internal\ndef test_input(arr: int128[2][1], i: int128) -> (int128[2][1], int128):\n return arr, i\n\n@external\ndef test_values(arr: int128[2][1], i: int128) -> (int128[2][1], int128):\n return self.test_input(arr, i)\n```\n\nPlease see #2183 for further information\n\n### Patches\nThis problem was fixed in #2184, and released as a part of [`v0.2.6`](https://github.com/vyperlang/vyper/releases/tag/v0.2.6).",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "vyper"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.2.6"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/vyperlang/vyper/security/advisories/GHSA-4v7v-gqf9-ww2g"
}, {
"type" : "WEB",
"url" : "https://github.com/vyperlang/vyper/issues/2183"
}, {
"type" : "WEB",
"url" : "https://github.com/vyperlang/vyper/pull/2184"
}, {
"type" : "WEB",
"url" : "https://github.com/vyperlang/vyper/commit/0be02b7331e8febe79d5a4218829c72e30417a29"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/vyperlang/vyper"
}, {
"type" : "WEB",
"url" : "https://github.com/vyperlang/vyper/releases/tag/v0.2.6"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-682" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-10-06T15:22:23Z",
"nvd_published_at" : null
}
}