The protocol lacks functionality to remove fee recipients from protocolFeeRecipients. The only way to "disable" a recipient is by setting their share to zero, but they remain in the Enumerable Mapping and still receive transfer calls. This can cause entire reward distributions to fail if any recipient becomes invalid
In configureFeeRecipient, recipients can only have their shares modified:
During reward distribution, transfers are attempted to all recipients regardless of share amount:
This is called in critical protocol functions:
fulfillSwap
: Distributes swap fees
_convertAssetsToUsdc
: Handles USDC conversions
sendWethToFeeRecipients
: Distributes WETH rewards
If any recipient becomes invalid (blacklisted, reverts on transfer, etc.) or receives a zero-value transfer with a token that doesn't allow it and reverts, all reward distributions will fail
No way to remove problematic recipients
Gas inefficiency from iterating over and attempting transfers to zero-share recipients
Could completely block core protocol functions that depend on successful fee distribution
Foundry
Inside configureFeeRecipient
if shares == 0 add an if statement at the end of updating protocol total fee shares values
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.