code-423n4 / 2023-08-reserve-mitigation-findings

0 stars 0 forks source link

M-09 MitigationConfirmed #16

Open code423n4 opened 1 year ago

code423n4 commented 1 year ago

Lines of code

Vulnerability details

This issue is mitigated.

Explanation of found problem

StRSR allows user unstake RSR. Later, user can cancel this request by calling cancelUnstake function. Because this function doesn't pay rewards before minting shares, that means that wrong exchange rate will be used and initiator of cancelUnstake will receive more shares, then he should and as result other stakers will lose part of rewards as they were not distributed before canceling.

How it was fixed

Reserve team fixed this issue, be calling _payoutRewards function, before minting new shares. So now exchange rate is up to date.

c4-judge commented 1 year ago

0xean marked the issue as satisfactory

c4-judge commented 1 year ago

0xean marked the issue as confirmed for report