code-423n4 / 2021-09-defiprotocol-findings

1 stars 0 forks source link

Missing Zero-Address Checks #86

Open code423n4 opened 3 years ago

code423n4 commented 3 years ago

Handle

shenwilly

Vulnerability details

Impact

Accidental use of zero-address from faulty deployment script can force re-deployment of contract. Recommend adding zero-address check on Factory.sol constructor, especially because _auctionImpl & _basketImpl are unchangeable.

Proof of Concept

https://github.com/code-423n4/2021-09-defiProtocol/blob/52b74824c42acbcd64248f68c40128fe3a82caf6/contracts/contracts/Factory.sol#L18-L22

Recommended Mitigation Steps

Consider adding zero address checks in the Factory.sol constructor.

GalloDaSballo commented 2 years ago

Agree with finding, will keep this as the main finding and set others to dupes