$685.84 M
5.84%
...
...
...
Introduction of Boojum prover
2023 Jul 17th
Deployment of Boojum - new high-performance proof system.
Fair Onboarding Alpha and Rebranding
2023 Feb 16th
zkSync 2.0 rebrands to zkSync Era and lets registered projects and developers deploy on mainnet.
Uses PLONK zero-knowledge proof system with KZG commitments.
All of the data (SD = state diffs) needed for proof construction is published on chain.
There is no window for users to exit in case of an unwanted upgrade since contracts are instantly upgradable.
Users can submit transactions to an L1 queue, but can’t force them. The sequencer cannot selectively skip transactions but can stop processing the queue entirely. In other words, if the sequencer censors or is down, it is so for everyone.
Only the whitelisted proposers can publish state roots on L1, so in the event of failure the withdrawals are frozen.
Despite their production use zkSTARKs and zkSNARKs proof systems are still relatively new, complex and they rely on the proper implementation of the polynomial constraints used to check validity of the Execution Trace. In addition zkSNARKs require a trusted setup to operate.
Funds can be lost if the proof system is implemented incorrectly.
All the data that is used to construct the system state is published on chain in the form of cheap blobs or calldata. This ensures that it will be available for enough time.
The node software is open-source, and its source code can be found here. The main node software does not rely on Layer 1 (L1) to reconstruct the state, but you can use this tool for that purpose. Currently, there is no straightforward method to inject the state into the main node, but zkSync is actively working on a solution for this.
Bytecodes undergo compression before deployment on Layer 1 (L1). You can find additional information on this process here.
There have been neither genesis states nor regenesis.
Details on data format can be found here.
Each update to the system state must be accompanied by a ZK proof that ensures that the new state was derived by correctly applying a series of valid user transactions to the previous state. These proofs are then verified on Ethereum by a smart contract.
zkSync Era circuits are built from Boojum and are designed to replicate the behavior of the EVM. The source code can be found here. The circuits are checked against tests that can be found here.
Funds can be lost if the proof system is implemented incorrectly.
SNARK verification keys can be generated and checked against the Ethereum verifier contract using this tool. The system requires a trusted setup.
The operator is the only entity that can propose blocks. A live and trustworthy operator is vital to the health of the system.
MEV can be extracted if the operator exploits their centralized position and frontruns user transactions.
If a user is censored by L2 Sequencer, they can try to force transaction via L1 queue. Right now there is no mechanism that forces L2 Sequencer to include transactions from L1 queue in an L1 block.
Users can be censored if the operator refuses to include their transactions.
The user initiates the withdrawal by submitting a regular transaction on this chain. When the block containing that transaction is proven the funds become available for withdrawal on L1. Finally the user submits an L1 transaction to claim the funds. This transaction requires a merkle proof.
If the user experiences censorship from the operator with regular exit they can submit their withdrawal requests directly on L1. The system is then obliged to service this request or halt all messages from L1, including all forced withdrawals and deposits. Once the force operation is submitted and if the request is serviced, the operation follows the flow of a regular exit.
Currently, the Matter Labs multisig (4 / 8) is able to instantly upgrade all contracts (including the diamond and its facets) and roles (including the Governor role). The Governor role that resolves to the multisig is the highest permissioned role defined in the system.
Governor: Can access all AdminFacet
functions and thus upgrade the diamond and the related smart contract system. Additionally inherits access to functions for the Admin role. Can freeze all freezable Facets (currently ExecutorFacet
, MailboxFacet
) and upgrade the bridges.
Validator: Proposes batches from L2 into the ValidatorTimelock
, from where they can be proven and finally executed (through the ExecutorFacet
of the diamond) after a predefined delay (currently 21h). This allows for freezing the L2 chain within the delay if any suspicious activity was detected. Can be set by the Admin or Governor.
Verifier: Verifies the zk proofs that were provided by the Validator. Can be changed by calling ExecuteUpgrade()
on the AdminFacet
from the Governor role.
Admin: Currently not set. Will be able to make non-critical changes like setting the Validator. Will be the role of the multisig when higher permissions are restricted to the Security Council.
Security Council: Currently not set. Will share the Governor role of the main diamond with the Matter Labs multisig through the Governance smart contract (see below).
A Governance
smart contract is set up as the Governor role of the diamond. It includes logic for planning upgrades with parameters like transparency and/or a delay. Currently the delay is optional (minimum delay = 0s) and not used by the multisig. The optional transparency may be used in the future to hide instant emergency upgrades by the Security Council or delay transparent (thus auditable) governance upgrades. The Governance
smart contract has two roles, an owner role and a securityCouncil role.
This MultiSig is the current Governor of zkSync Era main contract and owner of the L1EthBridge. It can upgrade zkSync Era, upgrade bridge, change rollup parameters with no delay. This is a Gnosis Safe with 4 / 8 threshold.
Those are the participants of the Matter Labs Multisig.
Those actors are allowed to propose, revert and execute L2 blocks on L1.
The main Rollup contract. Operator commits blocks, provides ZK proof which is validated by the Verifier contract and process transactions (executes blocks). During block execution it processes L1 --> L2 and L2 --> L1 transactions. It uses separate Verifier to validate ZK proofs. Governance manages list of Validators and can set basic rollup parameters. It is also serves the purpose of ETH bridge. This contract stores the following tokens: ETH.
Can be upgraded by: Matter Labs Multisig
Upgrade delay: No delay
Implements ZK proof verification logic.
Can be upgraded by: Matter Labs Multisig
Upgrade delay: No delay
Contract delaying block execution (ie withdrawals and other L2 --> L1 messages).
Owner can schedule a transparent (you see the upgrade data on-chain) or a shadow (you don’t see the upgrade data on-chain) upgrade. While scheduling an upgrade the owner chooses a delay, that delay has to be bigger than 0 seconds. Canceling the upgrade can be done only by the owner. The owner or the security council can perform the upgrade if the chosen delay is up. Only the security council can force the upgrade to execute even if the delay is not up.
Can be upgraded by: Matter Labs Multisig
Upgrade delay: No delay
Standard bridge for depositing ERC20 tokens to zkSync Era.
Can be upgraded by: Matter Labs Multisig
Upgrade delay: No delay
Main rollup contract, additionally serving as an escrow.
Can be upgraded by: Matter Labs Multisig
Upgrade delay: No delay
Bridge for depositing wrapped stETH (Lido) to zkSync Era.
Can be upgraded by: Lido (Lido Agent)
Upgrade delay: No delay
The current deployment carries some associated risks:
Funds can be stolen if a contract receives a malicious code upgrade. There is no delay on code upgrades (CRITICAL).