CVE-2022-24787
published high CVSS 3.1 · 7.5Incorrect Comparison in Vyper
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| vyperlang | — | vyper<= 0.3.1 | Affected | Not stated | GitHub_M |
Description
Vyper is a Pythonic Smart Contract Language for the Ethereum Virtual Machine. In version 0.3.1 and prior, bytestrings can have dirty bytes in them, resulting in the word-for-word comparisons giving incorrect results. Even without dirty nonzero bytes, two bytestrings can compare to equal if one ends with `"\x00"` because there is no comparison of the length. A patch is available and expected to be part of the 0.3.2 release. There are currently no known workarounds.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 3.1
- Base score
- 7.5 / 10
- Severity
- high
- Provider
- GitHub_M · cna
- Vector string
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| vyperlang | vyper | <= 0.3.1 (affected) | GitHub_M · cna |
Weaknesses
1- CWE-697 CWE-697: Incorrect Comparison
References
2Provider assertions
3GitHub_M · cna
Incorrect Comparison in Vyper
CISA-ADP · adp
CISA ADP Vulnrichment
CVE · adp
CVE Program Container
Provenance
- Schema
- 5.1
- Searchable
- yes
- Content hash
- fc2f80a45df7624a866f1d13e1e67b9a3aaac1297b6013953132000482a26b84
- Ingested
- 23 Sep 2026, 07:58:57 UTC
- Source record
- Official CVE record