Dliteofficial - A leverage Trader can use additionalSize to exploit the Flat Money Points for more Flat Money Point Tokens in LeverageModule::executeOpen() or LeverageModule::executeAdjust() #149
A leverage Trader can use additionalSize to exploit the Flat Money Points for more Flat Money Point Tokens in LeverageModule::executeOpen() or LeverageModule::executeAdjust()
Summary
A leverage trader can deposit a certain margin, enter a position with the maximum additionalSize to secure more than enough Flat Money Points tokens, exit the position. He can perform this action repeatedly for maximum rewards.
Vulnerability Detail
As a rewards to leverage traders and UNIT LPs, they get Flat Money Point tokens to be redeemed according to a vesting schedule later in the future. When a leverage trader announces a leverage open order and it gets executed, the user is given flat money points tokens according to the additional size taken. To top it off, the points is not taken if the trader exits the system.
For maximum reward, the user can take the maximum additional size, secure the Flat Money Points Tokens, exit the position and do it all over again. Of course, consideration will be put in the execution of this attack however, the benefit far outweighs the cost. For a leverage ratio of 25x and a margin of 1 ETH, the trader can get 24ETH additional size. with the points per deposit, the reward is amplified.
Impact
The trader accesses more Flat Money Points Tokens that he deserves in a short period of time.
Dliteofficial
medium
A leverage Trader can use additionalSize to exploit the Flat Money Points for more Flat Money Point Tokens in LeverageModule::executeOpen() or LeverageModule::executeAdjust()
Summary
A leverage trader can deposit a certain margin, enter a position with the maximum additionalSize to secure more than enough Flat Money Points tokens, exit the position. He can perform this action repeatedly for maximum rewards.
Vulnerability Detail
As a rewards to leverage traders and UNIT LPs, they get Flat Money Point tokens to be redeemed according to a vesting schedule later in the future. When a leverage trader announces a leverage open order and it gets executed, the user is given flat money points tokens according to the additional size taken. To top it off, the points is not taken if the trader exits the system.
For maximum reward, the user can take the maximum additional size, secure the Flat Money Points Tokens, exit the position and do it all over again. Of course, consideration will be put in the execution of this attack however, the benefit far outweighs the cost. For a leverage ratio of 25x and a margin of 1 ETH, the trader can get 24ETH additional size. with the points per deposit, the reward is amplified.
Impact
The trader accesses more Flat Money Points Tokens that he deserves in a short period of time.
Code Snippet
LeverageModule::executeOpen()
Tool used
Manual Review
Recommendation
Flat Money Points Token should be given based on the margin provided like that of UNIT LPs rather than additional size for Leverage traders.
Duplicate of #187