You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of using the proxy pattern for new Escrow contracts, the Escrow contract is deployed every time. This leads to unwanted gas expenditure.
Vulnerability Details
Although all Escrow contracts have the same code, a new contract is deployed everytime instead of deploying a single implementation followed by proxies.
Not using Proxy pattern
Severity
Gas Optimization / Informational
Relevant GitHub Links
2023-07-escrow/src/EscrowFactory.sol
Lines 40 to 52 in 65a60eb
Summary
Instead of using the proxy pattern for new Escrow contracts, the Escrow contract is deployed every time. This leads to unwanted gas expenditure.
Vulnerability Details
Although all Escrow contracts have the same code, a new contract is deployed everytime instead of deploying a single implementation followed by proxies.
Impact
Unwanted gas expenditure of about 400000 for every new escrow contract.
Tools Used
Foundry gas reported
Recommendations
Have a single escrow implementation contract and then deploy proxies.
The text was updated successfully, but these errors were encountered: