Auth bypass in Vyperlang Vyper
CVE-2023-39363
Vyper is a Pythonic Smart Contract Language for the Ethereum Virtual Machine (EVM). In versions 0.2.15, 0.2.16 and 0.3.0, named re-entrancy locks are allocated incorrectly. Each function using a named re-entrancy lock gets a unique lock regardless of the key, allowing cross-function re-entrancy in contracts compiled with the susceptible versions. A specific set of conditions is required to result in misbehavior of affected contracts, specifically: a `.vy` contract compiled with `vyper` versions `0.2.15`, `0.2.16`, or `0.3.0`; a primary function that utilizes the `@nonreentrant` decorator with a specific `key` and does not strictly follow the check-effects-interaction pattern (i.e. contains an external call to an untrusted party before storage updates); and a secondary function that utilizes the same `key` and would be affected by the improper state caused by the primary function. Version 0.3.1 contains a fix for this issue.
Vulnerability class: Broken Access Control
Published · last modified .
CVSS v3 metric
CVSS v3 base score 5.9 (Medium). Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N.
EPSS exploit prediction
EPSS: 0.008 (56.6th percentile), scored .
Very low probability of exploitation in the next 30 days; routine patching cadence is appropriate. 57th percentile — 56.6% of CVEs in the catalogue have a lower EPSS than this one. How to read EPSS.
EPSS over last 30 days · oldest: 0.008 · newest: 0.008 · change: 0.000
Affected products
- Vyperlang Vyper — versions 0.3.0, = 0.2.15, 0.2.16
Weakness classification (CWE)
Public proof-of-concept exploits
References
- github.com/vyperlang/vyper/security/advisories/GHSA-5824-cm3x-3c38 (Exploit, Patch, Third Party Advisory)
- github.com/vyperlang/vyper/pull/2439 (Patch)
- github.com/vyperlang/vyper/pull/2514 (Patch)
- hackmd.io/@LlamaRisk/BJzSKHNjn (Exploit, Third Party Advisory)
- hackmd.io/@vyperlang/HJUgNMhs2 (Exploit, Third Party Advisory)
Frequently asked questions
- What is CVE-2023-39363?
- CVE-2023-39363 is a medium-severity vulnerability in Vyperlang Vyper, classified under Incorrect Authorization. CVSS score: 5.9/10. Published 2023-08-07.
- How severe is CVE-2023-39363?
- Medium severity. CVSS v3 base score is 5.9 out of 10.
- Is CVE-2023-39363 known to be exploited?
- 1 public proof-of-concept repositories are indexed. Not currently listed in the CISA KEV catalog.