CVE-2021-41122
MEDIUM4.3EPSS 0.20%missing clamps for decimal args in external functions
Published: 10/6/2021Modified: 3/13/2026
Description
### Impact The following code does not properly validate that its input is in bounds. ```python @external def foo(x: decimal) -> decimal: return x ``` ### Patches 0.3.0 / #2447 ### Workarounds Don't use decimal args
Affected packages (2)
- PyPI/vyperfrom 0, < 0.3.0
- PyPI/vyperfrom 0, < 0.3.0
CVSS scores
| Source | Version | Severity | Vector |
|---|---|---|---|
| osv | CVSS 4.0 | — | CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N |
| osv | CVSS 3.1 | MEDIUM4.3 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N |
References (5)
- ADVISORYhttps://nvd.nist.gov/vuln/detail/CVE-2021-41122
- PATCHhttps://github.com/vyperlang/vyper
- WEBhttps://github.com/pypa/advisory-database/tree/main/vulns/vyper/PYSEC-2021-366.yaml
- WEBhttps://github.com/vyperlang/vyper/pull/2447
- WEBhttps://github.com/vyperlang/vyper/security/advisories/GHSA-c7pr-343r-5c46