CVE-2024-32647

Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection') (CWE-95)

Published: Apr 25, 2024 / Updated: 6mo ago

010
CVSS 5.3EPSS 0.04%Medium
CVE info copied to clipboard

Summary

Vyper is a Pythonic Smart Contract Language for the Ethereum virtual machine. In versions 0.3.10 and prior, using the `create_from_blueprint` builtin can result in a double eval vulnerability when `raw_args=True` and the `args` argument has side-effects. The `_build_create_IR` function of the `create_from_blueprint` builtin doesn't cache the `args` argument to the stack, causing it to be evaluated multiple times instead of retrieving the value from the stack.

Impact

This double evaluation of the `args` argument with side-effects could potentially lead to unintended code execution or denial of service. However, no vulnerable production contracts were found, and the double evaluation should be easily discoverable in client tests, so the overall impact is considered low.

Exploitation

There is no evidence that a public proof-of-concept exists. There is no evidence of proof of exploitation at the moment.

Patch

As of the time of publication, no fixed versions were available for Vyper 0.3.10 and prior versions affected by this vulnerability.

Mitigation

While no official mitigation is provided, it is recommended to update to the latest patched version of Vyper once it becomes available. In the meantime, carefully review any use of the `create_from_blueprint` builtin with `raw_args=True` and ensure that the `args` argument does not have any unintended side-effects.

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Timeline

CVE Assignment

NVD published the first details for CVE-2024-32647

Apr 25, 2024 at 6:15 PM
CVSS

A CVSS base score of 5.3 has been assigned.

Apr 25, 2024 at 6:20 PM / nvd
First Article

Feedly found the first article mentioning CVE-2024-32647. See article

Apr 25, 2024 at 6:22 PM / National Vulnerability Database
Trending

This CVE started to trend in security discussions

Apr 25, 2024 at 9:42 PM
EPSS

EPSS Score was set to: 0.04% (Percentile: 8.2%)

Apr 26, 2024 at 9:20 AM
Trending

This CVE stopped trending in security discussions

Apr 26, 2024 at 10:31 PM
EPSS

EPSS Score was set to: 0.04% (Percentile: 8.3%)

May 6, 2024 at 9:45 PM
Static CVE Timeline Graph

Affected Systems

Vyperlang/vyper
+null more

Patches

Github Advisory
+null more

Attack Patterns

CAPEC-35: Leverage Executable Code in Non-Executable Files
+null more

Vendor Advisory

[GHSA-3whq-64q2-qfj6] vyper performs double eval of raw_args in create_from_blueprint
Factory = b.loads_partial(src1) The vulnerability is demonstrated in the following boa test: src1 = """

News

Update Fri Aug 2 14:35:21 UTC 2024
Update Fri Aug 2 14:35:21 UTC 2024
NA - CVE-2024-32647 - Vyper is a pythonic Smart Contract Language for...
Vyper is a pythonic Smart Contract Language for the Ethereum virtual machine. In versions 0.3.10 and prior, using the `create_from_blueprint` builtin can result in a double eval vulnerability when...
advng deleted project branch advng/pypi/vyper/CVE-2024-32647 at GitLab.org / security-products / advisory-database
advng (07288679) at 25 Apr 21:53
CVE-2024-32647 | Vyper up to 0.3.10 neutralization of directives (GHSA-3whq-64q2-qfj6)
A vulnerability classified as problematic has been found in Vyper up to 0.3.10 . This affects an unknown part. The manipulation leads to improper neutralization of directives in dynamically evaluated code ('eval injection'). This vulnerability is uniquely identified as CVE-2024-32647 . It is possible to initiate the attack remotely. There is no exploit available.
CVE-2024-32647
In versions 0.3.10 and prior, using the `create_from_blueprint` builtin can result in a double eval vulnerability when `raw_args=True` and the `args` argument has side-effects. It can be seen that the `_build_create_IR` function of the `create_from_blueprint` builtin doesn't cache the mentioned `args` argument to the stack.
See 4 more articles and social media posts

CVSS V3.1

Attack Vector:Network
Attack Complexity:Low
Privileges Required:None
User Interaction:None
Scope:Unchanged
Confidentiality:None
Integrity:Low
Availability Impact:None

Categories

Be the first to know about critical vulnerabilities

Collect, analyze, and share vulnerability reports faster using AI