Also note: "Smart contracts MUST implement the ERC-165 supportsInterface function and signify support for the ERC1155TokenReceiver interface to accept transfers."
supportsInterface() is not defined on OceanAdapter contract.
Impact
This contract is not ERC1155 compliant and may reject tokens when trying to transfer to this contract.
Recommended Mitigation Steps
Ensure the contract impelments the ERC1155 to spec or completely remove it's functionality from this contract (i.e.: remove the onERC1155Received() function.)
Lines of code
https://github.com/code-423n4/2023-11-shellprotocol/blob/485de7383cdf88284ee6bcf2926fb7c19e9fb257/src/adapters/OceanAdapter.sol#L14
Vulnerability details
EIP1155 Standard states compliant contracts must implement the support for the
ERC1155TokenReceiver
interface which has bothonERC1155Received()
andonERC1155BatchReceived()
: https://eips.ethereum.org/EIPS/eip-1155#erc-1155-token-receiverAlso note: "Smart contracts MUST implement the ERC-165 supportsInterface function and signify support for the ERC1155TokenReceiver interface to accept transfers."
supportsInterface()
is not defined onOceanAdapter
contract.Impact
This contract is not ERC1155 compliant and may reject tokens when trying to transfer to this contract.
Recommended Mitigation Steps
Ensure the contract impelments the ERC1155 to spec or completely remove it's functionality from this contract (i.e.: remove the onERC1155Received() function.)
Assessed type
Other