code-423n4 / 2023-05-juicebox-findings

1 stars 1 forks source link

Invalid ERC-165 implementation #134

Closed code423n4 closed 1 year ago

code423n4 commented 1 year ago

Lines of code

https://github.com/code-423n4/2023-05-juicebox/blob/9d0458282511ff269b3b35b5b082b56d5cc08663/juice-buyback/contracts/JBXBuybackDelegate.sol#L359-L362

Vulnerability details

Detail

The supportsInterface implementation does not comply to EIP-165.

Tools Used

https://eips.ethereum.org/EIPS/eip-165

Recommended Mitigation Steps

function supportsInterface(bytes4 _interfaceId) external pure override returns (bool) {
         return interfaceId == type(IERC165).interfaceId
               _interfaceId == type(IJBFundingCycleDataSource).interfaceId
            || _interfaceId == type(IJBPayDelegate).interfaceId;
}

Assessed type

Other

c4-pre-sort commented 1 year ago

dmvt marked the issue as low quality report

dmvt commented 1 year ago

Lacking information about the impact of this oversight

c4-judge commented 1 year ago

dmvt marked the issue as unsatisfactory: Insufficient quality