code-423n4 / 2024-04-panoptic-findings

7 stars 3 forks source link

Inaccurate MEV Tax Calculation #511

Closed c4-bot-1 closed 4 months ago

c4-bot-1 commented 4 months ago

Lines of code

https://github.com/code-423n4/2024-04-panoptic/blob/main/contracts/CollateralTracker.sol#L995

Vulnerability details

Impact

The calculation of the MEV tax in the takeCommissionAddData function does not accurately account for the intrinsic value of ITM positions. This could lead to incorrect fee calculations and potential losses for the protocol.

Proof of Concept

https://github.com/code-423n4/2024-04-panoptic/blob/main/contracts/CollateralTracker.sol#L995

Tools Used

Manuel Review

Recommended Mitigation Steps

Revise the calculation of the MEV tax in the takeCommissionAddData function to accurately account for the intrinsic value of premium positions. This may involve adjusting the formula used to calculate the tax or ensuring that the intrinsic value is correctly factored into the calculation.

Assessed type

Other

c4-judge commented 4 months ago

Picodes marked the issue as unsatisfactory: Insufficient proof