40,000 USDC
View results
Submission Details
Severity: low

Low Risk and Non-Critical finding

[L-01] Missing checks for address(0x0) when assigning values to address state variables

Findings:

2023-07-escrow-main/src/Escrow.sol::45 => i_price = price;
2023-07-escrow-main/src/Escrow.sol::46 => i_tokenContract = tokenContract;
2023-07-escrow-main/src/Escrow.sol::47 => i_buyer = buyer;
2023-07-escrow-main/src/Escrow.sol::48 => i_seller = seller;
2023-07-escrow-main/src/Escrow.sol::49 => i_arbiter = arbiter;
2023-07-escrow-main/src/Escrow.sol::50 => i_arbiterFee = arbiterFee;

Non-Critical Issues

[N-01] Adding a return statement when the function defines a named return variable, is redundant

Findings:

2023-07-escrow-main/src/Escrow.sol::136 => return i_price;
2023-07-escrow-main/src/Escrow.sol::140 => return i_tokenContract;
2023-07-escrow-main/src/Escrow.sol::144 => return i_buyer;
2023-07-escrow-main/src/Escrow.sol::148 => return i_seller;
2023-07-escrow-main/src/Escrow.sol::152 => return i_arbiter;
2023-07-escrow-main/src/Escrow.sol::156 => return i_arbiterFee;
2023-07-escrow-main/src/Escrow.sol::160 => return s_state;
2023-07-escrow-main/src/EscrowFactory.sol::52 => return escrow;
2023-07-escrow-main/src/EscrowFactory.sol::85 => return predictedAddress;

[N-02] Unused file

Findings:

2023-07-escrow-main/src/Escrow.sol::1 => // SPDX-License-Identifier: MIT
2023-07-escrow-main/src/EscrowFactory.sol::1 => // SPDX-License-Identifier: MIT

[N-03] public functions not called by the contract should be declared external instead

Impact

Contracts are allowed to override their parents’ functions and change the visibility from public to external .

Findings:

2023-07-escrow-main/src/EscrowFactory.sol::66 => ) public pure returns (address) {

Tools used

c4udit

Support

FAQs

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