Sparkn

CodeFox Inc.
DeFiFoundryProxy
15,000 USDC
View results
Submission Details
Severity: low

unsafe downcasting in `getProxyAddress` function

Summary

In the getProxyAddress function of ProxyFactory.sol hash is bein downcasted from uint256 to uint160 which would cause unfavorable condition.

Vulnerability Details

In the getProxyAddress function of ProxyFactory.sol hash is bein downcasted from uint256 to uint160 which would cause unfavorable condition.
Generally it is recommended that if you want to downcast then you should use safe library or else truncating to any lower uint value would cause unexpected error

Impact

as the hash is being down casted to uint160 which will cause unexpected errors

Tools Used

Manual Review

Recommendations

A SafeCast library must be used everywhere a typecast is done.

Support

FAQs

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

Give us feedback!