code-423n4 / 2022-03-volt-findings

0 stars 0 forks source link

Need to change the logic of smart contracts in the face of negative inflation #99

Closed code423n4 closed 2 years ago

code423n4 commented 2 years ago

Lines of code

https://github.com/code-423n4/2022-03-volt/blob/cec24b859c69d1397ce4048b6e9b8e96410b31dd/contracts/oracle/ScalingPriceOracle.sol#L122

Vulnerability details

Impact

Given that the possibility of negative inflation in the economy is not impossible (even now observed in some countries, ) it is important to clearly explain to users the act of smart contracts against negative inflation. In the current logic of the VOLT smartcontract, the value of this VOLT decreases during negative inflation. But it is advisable to change the logic of the program so that the value of the VOLT in the face of negative inflation falls to the level of" one dollar" and does not fall more than one dollar.

Proof of Concept

Users don't like to invest in a contract which may reduce the value of their assets more than beginning of staking

Tools Used

Recommended Mitigation Steps:

changing the logic of this smartcontract against of negative inflation

ElliotFriedman commented 2 years ago

this is expected behavior. if the dollar deflates, volt's price will be lowered by the oracle