Platform: Code4rena
Start Date: 31/01/2023
Pot Size: $36,500 CANTO
Total HM: 5
Participants: 38
Period: 3 days
Judge: berndartmueller
Total Solo HM: 2
Id: 212
League: ETH
Rank: 16/38
Findings: 1
Award: $108.60
🌟 Selected for report: 0
🚀 Solo Findings: 0
360.4223 CANTO - $108.60
https://github.com/code-423n4/2023-01-canto-identity/blob/main/src/AddressRegistry.sol#L1
The _cidNFTID
will be registered to incorrect owner in case of NFT transfer. In some cases this can lead to multiple registration for same _cidNFTID
1
is owned by User Afunction register(uint256 _cidNFTID) external { if (ERC721(cidNFT).ownerOf(_cidNFTID) != msg.sender) // We only guarantee that a CID NFT is owned by the user at the time of registration // ownerOf reverts if non-existing ID is provided revert NFTNotOwnedByUser(_cidNFTID, msg.sender); cidNFTs[msg.sender] = _cidNFTID; emit CIDNFTAdded(msg.sender, _cidNFTID); }
_cidNFTID
to User B. This is allowed since cidNFT contract implements ERC721 contractRegistration of _cidNFTID
should be removed if _cidNFTID
is transferred
#0 - c4-judge
2023-02-09T12:45:23Z
berndartmueller marked the issue as duplicate of #177
#1 - c4-judge
2023-02-17T21:37:21Z
berndartmueller marked the issue as satisfactory