Lucene search
K

_getFirstSample returns wrong sample if count < sampleMemory

🗓️ 01 Dec 2021 00:00:00Reported by Code4renaType 
code423n4
 code423n4
🔗 github.com👁 8 Views

_getFirstSample returns wrong sample if count < sampleMemory. The MovingAverage.sol contract defines variables for a ring buffer with incorrect index computation leading to wrong TWAP calculation. Recommended mitigation includes adding an additional check for correct index computation in _getFirstSample.

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

26 Jan 2022 00:00Current
6.9Medium risk
Vulners AI Score6.9
8