Platform: Code4rena
Start Date: 13/11/2023
Pot Size: $24,500 USDC
Total HM: 3
Participants: 120
Period: 4 days
Judge: 0xTheC0der
Id: 306
League: ETH
Rank: 74/120
Findings: 1
Award: $4.08
🌟 Selected for report: 0
🚀 Solo Findings: 0
🌟 Selected for report: chaduke
Also found by: 0xpiken, Bauchibred, Matin, MohammedRizwan, MrPotatoMagic, OMEN, Pheonix, SandNallani, T1MOH, Topmark, ZanyBonzy, adriro, aslanbek, ayden, bareli, bart1e, bin2chen, btk, cheatc0d3, codynhat, critical-or-high, d3e4, erebus, firmanregar, hunter_w3b, jasonxiale, kaveyjoe, ksk2345, lsaudit, max10afternoon, merlinboii, nailkhalimov, osmanozdemir1, peanuts, pep7siup, pontifex, sbaudh6, shenwilly, sl1, tourist, wisdomn_, young, zhaojie
4.0797 USDC - $4.08
https://github.com/code-423n4/2023-11-canto/blob/main/1155tech-contracts/src/Market.sol#L226-L241
Indirect Share Participation with Less Payout allows NFT holders, in addition to regular shareholders, to burn the NFT. This enables them to participate indirectly (through burnNFT()
) in specific shares with less payout than direct participation through buy()
.
The Market
contract allows not only the holder of a share to burn the NFT token, conflicting with what is described in the project details.
By calling the burnNFT
function, callers who do not hold shares can participate in a specific share by paying only the required fee for burning their owned NFT.
227: uint256 fee = getNFTMintingPrice(_id, _amount); 228: 229: SafeERC20.safeTransferFrom(token, msg.sender, address(this), fee);
Consequently, this creates a vulnerability in indirect share participation with less payout, which may be considered unfair to other holders.
Assuming that Alice and Bob each hold some tokens for payment, and Bob has not participated in any shares:
buy
function.burnNFT
function. In this process, he only pays the fee required to participate.Consequence:
Resources
burnNFT
.The recommendation should be considered in alignment with the project's business requirements, and any updates should be tested to ensure they meet the specific needs of the project.
Invalid Validation
#0 - c4-pre-sort
2023-11-18T16:09:37Z
minhquanym marked the issue as sufficient quality report
#1 - c4-sponsor
2023-11-27T11:18:18Z
OpenCoreCH (sponsor) disputed
#2 - OpenCoreCH
2023-11-27T11:22:46Z
If Alice sells the NFT to Bob, the price should be (at least) 90% of the current market price, anything lower than that opens up arbitrage opportunities. But that's no vulnerability or unfairness, that's just the primary market which sets a floor on the secondary market by having a buyback mechanism, i.e. a mechanism that exists in many protocols / markets.
#3 - MarioPoneder
2023-11-29T14:45:10Z
Although I acknowledge the concerns outlined in the report, this rather a design choice and market mechanics than an explicit bug of the protocol per se, therefore QA seems appropriate.
#4 - c4-judge
2023-11-29T14:45:16Z
MarioPoneder changed the severity to QA (Quality Assurance)
#5 - c4-judge
2023-11-29T22:41:15Z
MarioPoneder marked the issue as grade-b