CVE-2022-29255
mediumpriority · track · 30EPSS 0.013 · 71 %ileEUUSEPSS · scored 2026-10-28
Vyper is a Pythonic Smart Contract Language for the ethereum virtual machine. In versions prior to 0.3.4 when a calling an external contract with no return value, the contract address (including side effects) could be evaluated twice. This may result in incorrect outcomes for contracts. This issue has been addressed in v0.3.4.
cvss
Technical severity, 0–10. One row per scoring source.
base score 0–10 · higher = more severe · hover a vector to decode⚠ sources disagree · medium–high · 5–8.2
ssvc
A stakeholder decision — act, attend, or track — from exploitation and impact.
weaknesses
The CWE weakness classes this flaw belongs to.
affected products (3)
Products and version ranges known to be affected.
advisories (2)
Vendor and ecosystem advisories describing this.
- GHSA-4v9q-cgpw-cf38Multiple evaluation of contract address in call in vyper2022-06-06ghsa · osvUS
### Impact when a calling an external contract with no return value, the contract address could be evaluated twice. this is usually only an efficiency problem, but if evaluation of the contract address has side effects, it could result in double evaluation of the side effects. in the following example, `Foo(msg.sender).bar()` is the contract address for the following call (to `.foo()`), and could get evaluated twice ```vyper interface Foo: def foo(): nonpayable def bar() -> address: nonpayable @external def do_stuff(): Foo(Foo(msg.sender).bar()).foo() ``` ### Patches 6b4d8ff185de071252feaa1c319712b2d6577f8d ### Workarounds assign contract addresses to variables. the above example would change to ```vyper @external def do_stuff(): t: Foo = Foo(msg.sender).bar() t.foo() ``` ### References ### For more information
- PYSEC-2022-430532022-06-09vendor · osvUS
Vyper is a Pythonic Smart Contract Language for the ethereum virtual machine. In versions prior to 0.3.4 when a calling an external contract with no return value, the contract address (including side effects) could be evaluated twice. This may result in incorrect outcomes for contracts. This issue has been addressed in v0.3.4.
also known as (6)
Other names and identifiers for this entity.
sources
Which sources assert this record, and when.
references (7)
External citations — patches, advisories, analysis.
- https://cxsecurity.com/cveshow/CVE-2022-29255/cnnvd
- https://github.com/vyperlang/vyper/commit/6b4d8ff185de071252feaa1c319712b2d6577f8dcnnvd
- https://github.com/vyperlang/vyper/security/advisories/GHSA-4v9q-cgpw-cf38cnnvd
- https://github.com/vyperlang/vyper/commit/6b4d8ff185de071252feaa1c319712b2d6577f8denisa_euvd
- https://github.com/vyperlang/vyper/security/advisories/GHSA-4v9q-cgpw-cf38enisa_euvd
- https://github.com/vyperlang/vyper/commit/6b4d8ff185de071252feaa1c319712b2d6577f8dPatchThird Party Advisorynvd
- https://github.com/vyperlang/vyper/security/advisories/GHSA-4v9q-cgpw-cf38ExploitMitigationThird Party Advisorynvd
Attackers weaponise vulnerabilities like this against internet-exposed services. See what is exposed on your perimeter with a free passive scan.
Free scan