BuyerAgent contract's parameter update functions (setFeeRoyalty and setAmountPerRound) can be executed in incorrect phases due to non-atomic phase validation, allowing manipulation of critical financial parameters during active trading periods.
The phase validation in parameter update functions creates a race condition window between phase check and execution. The vulnerable code paths are: https://github.com/Cyfrin/2024-10-swan-dria/blob/c8686b199daadcef3161980022e12b66a5304f8e/contracts/swan/BuyerAgent.sol#L380-L398
The contract attempts to enforce phase protection through _checkRoundPhase(Phase.Withdraw).
POC
Parameters could be modified during active trading phases
This could disrupt ongoing purchases and financial calculations
Breaks the phase isolation principle of the protocol
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.