Scroll Phase 1 Audit

Off-Chain (Private)
Audited on 2023/10/16
No active critical issues

Summary

Issues 10 (7 resolved) Notes & Additional Information 18 (0 resolved) Client Reported Issues 1 (1 resolved) Scope We audited the scroll-tech/scroll repository at the 3bc8a3f commit of the develop branch. In scope were the following contracts:  contracts/src... and withdrawing into/from the rollup. Update: It is important to note that the develop branch changed the codebase between the audit's start and the fix review. Hence, we only reviewed the fixes in their respective context and cannot guarantee other implications that were introduced in the meantime. System...

Issues (20)

Low
Medium
High
Critical
Total
Not fixed
----0
Fixed
1037-20
Total1037020
Incorrect Batch Hashes Due to Memory Corruption
fixed/high

None
Incorrect Depth Calculation for Extension Nodes Allows Denial-of-Service
fixed/high

None
L2 Standard ERC-20 Token Metadata Can Be Set Arbitrarily
fixed/high

None
Lack of Refunds
fixed/high

None
Non-Standard RLP Encoding of Integer Zero
fixed/high

None
Users Can Lose Refund by Default
fixed/high

None
Withdraw Root Can Be Set Up as a Rug Pull
fixed/high

None
Enforced Transactions Signed Off-Chain Are Likely to Fail
fixed/medium

None
Lack of Upgradeability Storage Gaps
fixed/medium

None
WithdrawTrieVerifier Proves Intermediate Nodes
fixed/medium

None
Batch Events Lack Information
fixed/low

None
Batch Reverting Can Pause Finalization
fixed/low

None
Code Redundancy
fixed/low

None
Initialization Not Disabled for Implementation Contracts
fixed/low

None
Lack of Logs on Sensitive Actions
fixed/low

None
Lost Funds in Messenger Contracts
fixed/low

None
Missing and Misleading Documentation
fixed/low

None
Outdated OpenZeppelin Library Version
fixed/low

None
Unpinned Compiler Version
fixed/low

None
User Can Derive Call to Be on Behalf of the L1ScrollMessenger
fixed/low

None

Contracts (49)

#File Name
1

contracts/src/interfaces/IERC20Metadata.sol

2

contracts/src/libraries/ScrollMessengerBase.sol

3

contracts/src/L1/rollup/IL1MessageQueue.sol

4

contracts/src/L1/IL1ScrollMessenger.sol

5

contracts/src/libraries/gateway/ScrollGatewayBase.sol

6

contracts/src/L1/gateways/L1WETHGateway.sol

7

contracts/src/L1/gateways/L1ETHGateway.sol

8

contracts/src/L2/gateways/IL2ETHGateway.sol

9

contracts/src/L2/gateways/IL2ERC721Gateway.sol

10

contracts/src/libraries/token/IScrollERC1155.sol