CVE-2024-32646: vyper performs double eval of the slice args when buffer from adhoc locations
Using the slice
builtin can result in a double eval vulnerability when the buffer argument is either msg.data
, self.code
or <address>.code
and either the start
or length
arguments have side-effects.
A contract search was performed and no vulnerable contracts were found in production. Having side-effects in the start and length patterns is also an unusual pattern which is not that likely to show up in user code. It is also much harder (but not impossible!) to trigger the bug since 0.3.4
since the unique symbol fence was introduced (https://github.com/vyperlang/vyper/pull/2914).
References
Detect and mitigate CVE-2024-32646 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →