NFTBridge
60,000 USDC
View results
Submission Details
Severity: medium
Invalid

Users suffer from DOS due to incorrect logical implementation.

Summary

Users suffer from DOS due to incorrect logical implementation.

Vulnerability Details

According to protocol flow, users call `depositTokens()` to deposit token in escrow and initiate the transfer to Starknet.
But it will be reverted due to incorrect logical implementation.
```solidity
function depositTokens(
uint256 salt,
address collectionL1,
snaddress ownerL2,
uint256[] calldata ids,
bool useAutoBurn
)
external
payable
{
...
_depositIntoEscrow(ctype, collectionL1, ids);
...
}
```
The `depositTokens()` calls `detectInterface()` of `TokenUtil.sol`.
```solidity
function detectInterface(
address collection
)
internal
view
returns (CollectionType)
{
@ bool supportsERC721 = ERC165Checker.supportsInterface(
collection,
type(IERC721).interfaceId
);
...
@ bool supportsERC1155 = ERC165Checker.supportsInterface(
collection,
type(IERC1155).interfaceId
);
...
}
```
But `supportsInterface()` of `ERC165Checker` is internal function, then `Bridge` contract does not inherit `ERC165Checker`.
So users suffer from DOS.

Impact

Users suffer from DOS due to incorrect logical implementation.

Tools Used

Mannual Review

Recommendations

`Bridge` contract inherits `ERC165Checker` contract.

Updates

Lead Judging Commences

n0kto Lead Judge 11 months ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.