Protocol fee rate can be arbitrarily modified by the admin/DAO and will apply to all existing options #287
Labels
2 (Med Risk)
Assets not at direct risk, but function/availability of the protocol could be impacted or leak value
bug
Something isn't working
duplicate
This issue or pull request already exists
Lines of code
https://github.com/code-423n4/2022-06-putty/blob/3b6b844bc39e897bd0bbb69897f2deff12dc3893/contracts/src/PuttyV2.sol#L234-L246
https://github.com/code-423n4/2022-06-putty/blob/3b6b844bc39e897bd0bbb69897f2deff12dc3893/contracts/src/PuttyV2.sol#L498-L501
Vulnerability details
Impact
The admin/DAO can set a fee rate that is applied whenever an option is exercised (as per the function comment on L235).
A taker filling a call option knows the current protocol fee in advance and can estimate the receivable strike (strike - fee) at the time being. However, the fee is subject to change anytime, hence the taker could receive less at the time of withdrawing the strike as initially (at the time of filling the option) anticipated.
Proof of Concept
PuttyV2.setFee
PuttyV2.withdraw
Tools Used
Manual review
Recommended mitigation steps
fillOrder
function)The text was updated successfully, but these errors were encountered: