ERC1155::supportsInterface
should be virtual
#322
Labels
bug
Something isn't working
downgraded by judge
Judge downgraded the risk level of this issue
grade-b
Q-28
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
Lines of code
https://github.com/code-423n4/2024-04-panoptic/blob/833312ebd600665b577fbd9c03ffa0daf250ed24/contracts/tokens/ERC1155Minimal.sol#L200-L204
Vulnerability details
Impact
ERC1155::supportsInterface
should bevirtual
, otherwise it can't be override to add other interface-support.Proof of Concept
In the function ERC1155::supportsInterface, there is no
virtual
for the function, so that it can not be override.Since
ERC1155
currently doesn't supportinterfaceId == 0x0e89341c(ERC165 Interface ID for ERC1155MetadataURI)
, thesupportsInterface
could not be changed to add more interfaces. This may cause future integration problems.Tools Used
Manual
Recommended Mitigation Steps
Add
virtual
for functionsupportsInterface
so that more interfaces could be added in the future for better implementation.Assessed type
Other
The text was updated successfully, but these errors were encountered: