Skip to content

Commit

Permalink
Report for issue #28 updated by rvierdiiev
Browse files Browse the repository at this point in the history
  • Loading branch information
code423n4 committed Jun 21, 2023
1 parent d25e82c commit 68bbfcf
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion data/rvierdiiev-Q.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,20 @@ The idea here is to better sell DISABLED token over SOUND.
But IFFY token can become DEFAULTED as well soon. That's why i believe that it should be prioritized to sell over SOUND asset. So i guess that SOUND tokens should be sold in last order.

## Recommended Mitigation Steps
In case if current is SOUND and `other` is IFFY, then sell IFFY.
In case if current is SOUND and `other` is IFFY, then sell IFFY.

## #3. StRSR.pushDraft will make new draft be withdrawable later, then it should be in case if current unstakingDelay is smaller then previous one.

## Impact
User should be able to withdraw his draft after `unstakingDelay` period, but he should wait more.

## Proof of Concept
When user creates new draft, then `availableAt` time [is calculated for him](https://github.com/reserve-protocol/protocol/blob/c4ec2473bbcb4831d62af55d275368e73e16b984/contracts/p1/StRSR.sol#L623). This is a time when he should be able to withdraw his draft.

However, because [of this check](https://github.com/reserve-protocol/protocol/blob/c4ec2473bbcb4831d62af55d275368e73e16b984/contracts/p1/StRSR.sol#L624-L626) it's possible that user will wait more time to withdraw that draft.

This can happen when `unstakingDelay` governance param was changed to smaller one.

While, i understand that should be done, because of algorithm that is used to work with drafts, this submission is about unfair waiting time.
## Recommended Mitigation Steps
Think, that it can't be changed, as it will break work with drafts.

0 comments on commit 68bbfcf

Please sign in to comment.