Platform: Code4rena
Start Date: 01/09/2023
Pot Size: $36,500 USDC
Total HM: 4
Participants: 70
Period: 6 days
Judge: kirk-baird
Id: 281
League: ETH
Rank: 14/70
Findings: 1
Award: $771.30
🌟 Selected for report: 0
🚀 Solo Findings: 0
771.2966 USDC - $771.30
The natspec documentation for the rUSDY.burn function contains a statement that reads: Admin burn function for burning rUSDY tokens from any account
, which is inaccurate.
This function is intended for use in situations where a user possesses USDY but is legally prohibited from owning it. If a user is blocked, sanctioned, or not on the allowlist, then an account with the BURNER_ROLE will not be able to burn the user's tokens.
Include the following mock contract and test in the Test_rUSDY
to examine it:
contract BlockListMock { function isBlocked(address) external pure returns (bool) { return true; } } function test_rUSDY_adminCannotBurnFromBlocklistedAccount() public dealAndWrapAlice { vm.startPrank(guardian); BlockListMock blocklistContract = new BlockListMock(); rUSDYToken.setBlocklist(address(blocklistContract)); assertEq(address(rUSDYToken.blocklist()), address(blocklistContract)); vm.expectRevert("rUSDY: 'sender' address blocked"); rUSDYToken.burn(alice, 100e18); }
This does not align with the documentation, and the tokens that belonged to this user will be locked. However, any other users who are on the allowlist, not blocked, or sanctioned can have their tokens burned.
Manual
Please contemplate the possibility of enabling the burning of tokens exclusively from blocked or sanctioned accounts.
Context
#0 - c4-pre-sort
2023-09-08T15:18:10Z
raymondfam marked the issue as duplicate of #85
#1 - c4-pre-sort
2023-09-08T15:18:15Z
raymondfam marked the issue as sufficient quality report
#2 - c4-judge
2023-09-19T09:23:22Z
kirk-baird changed the severity to QA (Quality Assurance)
#3 - c4-judge
2023-09-26T23:49:04Z
This previously downgraded issue has been upgraded by kirk-baird
#4 - c4-judge
2023-09-26T23:49:11Z
kirk-baird marked the issue as not a duplicate
#5 - c4-judge
2023-09-26T23:50:31Z
kirk-baird marked the issue as duplicate of #136
#6 - c4-judge
2023-09-26T23:50:40Z
kirk-baird marked the issue as satisfactory