Commit 2fcd986
authored
feat: contracts for zksync os genesis (#4399)
## What ❔
<!-- What are the changes this PR brings about? -->
<!-- Example: This PR adds a PR template to the repo. -->
<!-- (For bigger PRs adding more context is appreciated) -->
## Why ❔
<!-- Why are these changes done? What goal do they contribute to? What
are the principles behind them? -->
<!-- The `Why` has to be clear to non-Matter Labs entities running their
own ZK Chain -->
<!-- Example: PR templates ensure PR reviewers, observers, and future
iterators are in context about the evolution of repos. -->
## Is this a breaking change?
- [ ] Yes
- [ ] No
## Operational changes
<!-- Any config changes? Any new flags? Any changes to any scripts? -->
<!-- Please add anything that non-Matter Labs entities running their own
ZK Chain may need to know -->
## Checklist
<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->
- [ ] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [ ] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
- [ ] Code has been formatted via `zkstack dev fmt` and `zkstack dev
lint`.1 parent 3db09e1 commit 2fcd986
File tree
4 files changed
+47
-11
lines changed- etc/env/file_based
- zkstack_cli/crates/config/src/forge_interface/deploy_ecosystem
4 files changed
+47
-11
lines changed- AllContractsHashes.json+1-1
- audits/v28/ZKsync Crypto Precompile Audit.pdf
- audits/v28/ZKsync Era-contracts Precompile Audit.pdf
- audits/v28/ZKsync Protocol Precompiles Implementation Audit.pdf
- audits/v28/pr-review.pdf
- audits/v28/report-cantinacode-matter-labs-0321_final.pdf
- l1-contracts/contracts/bridge/asset-router/AssetRouterBase.sol+7-18
- l1-contracts/contracts/bridge/asset-router/L1AssetRouter.sol+21-1
- l1-contracts/contracts/bridge/asset-router/L2AssetRouter.sol+88-21
- l1-contracts/contracts/bridge/interfaces/IL2WrappedBaseToken.sol+16
- l1-contracts/contracts/bridge/ntv/L1NativeTokenVault.sol+34-12
- l1-contracts/contracts/bridge/ntv/L2NativeTokenVault.sol+77-31
- l1-contracts/contracts/bridge/ntv/L2NativeTokenVaultZKOS.sol+78
- l1-contracts/contracts/bridge/ntv/NativeTokenVault.sol+17-33
- l1-contracts/contracts/bridge/ntv/UpgradeableBeaconDeployer.sol+45
- l1-contracts/contracts/bridgehub/BridgehubBase.sol+51-54
- l1-contracts/contracts/bridgehub/L1Bridgehub.sol+86
- l1-contracts/contracts/bridgehub/L1MessageRoot.sol+41
- l1-contracts/contracts/bridgehub/L2Bridgehub.sol+96
- l1-contracts/contracts/bridgehub/L2MessageRoot.sol+39
- l1-contracts/contracts/bridgehub/MessageRootBase.sol+16-21
- l1-contracts/contracts/common/L1ContractErrors.sol+2
- l1-contracts/contracts/common/L2ContractAddresses.sol+2
- l1-contracts/contracts/common/interfaces/ISystemContext.sol+63
- l1-contracts/contracts/dev-contracts/test/DummyBridgehubSetter.sol+3-7
- l1-contracts/contracts/dev-contracts/test/L2NativeTokenVaultDev.sol+22-21
- l1-contracts/contracts/l2-upgrades/IZKOSContractDeployer.sol+22
- l1-contracts/contracts/l2-upgrades/L2ComplexUpgrader.sol+38-9
- l1-contracts/contracts/l2-upgrades/L2GenesisForceDeploymentsHelper.sol+316
- l1-contracts/contracts/l2-upgrades/L2GenesisUpgrade.sol+15-6
- l1-contracts/contracts/state-transition/chain-deps/DiamondInit.sol+9-3
- l1-contracts/contracts/state-transition/chain-deps/GatewayCTMDeployer.sol+5-1
- l1-contracts/contracts/state-transition/chain-deps/facets/Executor.sol+92-58
- l1-contracts/contracts/state-transition/l2-deps/IComplexUpgrader.sol+34
- l1-contracts/contracts/state-transition/l2-deps/IL2GenesisUpgrade.sol+1
- l1-contracts/contracts/upgrades/L1GenesisUpgrade.sol+8-2
- l1-contracts/deploy-scripts/AdminFunctions.s.sol+5-25
- l1-contracts/deploy-scripts/BlakeContractHashing.s.sol+18
- l1-contracts/deploy-scripts/DeployL1.s.sol+37-27
- l1-contracts/deploy-scripts/DeployUtils.s.sol+11-9
- l1-contracts/deploy-scripts/GatewayCTMFromL1.s.sol+3-1
- l1-contracts/deploy-scripts/GatewayGovernanceUtils.s.sol-1
- l1-contracts/deploy-scripts/GatewayPreparation.sol
- l1-contracts/deploy-scripts/GatewayVotePreparation.s.sol+9-7
- l1-contracts/deploy-scripts/InitializeL2WethToken.s.sol+2-2
- l1-contracts/deploy-scripts/PrepareZKChainRegistrationCalldata.s.sol+5-5
- l1-contracts/deploy-scripts/RegisterZKChain.s.sol+6-5
- l1-contracts/deploy-scripts/Utils.sol+38-5
- l1-contracts/deploy-scripts/upgrade/ChainUpgrade.s.sol+2-2
- l1-contracts/deploy-scripts/upgrade/EcosystemUpgrade.s.sol+30-20
- l1-contracts/deploy-scripts/upgrade/EcosystemUpgrade_v26_1.s.sol+9-8
- l1-contracts/deploy-scripts/upgrade/EcosystemUpgrade_v27_1.s.sol+8-9
- l1-contracts/deploy-scripts/upgrade/FinalizeUpgrade.s.sol+5-5
- l1-contracts/foundry.toml+1-1
- l1-contracts/package.json+3-1
- l1-contracts/scripts/blake2s256.ts+32
- l1-contracts/test/foundry/l1/integration/DeploymentTest.t.sol+2-2
- l1-contracts/test/foundry/l1/integration/L1GatewayTests.t.sol+51
- l1-contracts/test/foundry/l1/integration/_GatewayPreparationForTests.sol+4-4
- l1-contracts/test/foundry/l1/integration/_SharedL1ContractDeployer.t.sol+3-3
- l1-contracts/test/foundry/l1/integration/l2-tests-in-l1-context/_SharedL2ContractL1Deployer.sol+11-29
- l1-contracts/test/foundry/l1/unit/concrete/Bridgehub/Initialize.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/Bridgehub/MessageRoot.t.sol+7-6
- l1-contracts/test/foundry/l1/unit/concrete/Bridgehub/_Bridgehub_Shared.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/Bridgehub/experimental_bridge.t.sol+6-7
- l1-contracts/test/foundry/l1/unit/concrete/DiamondCut/Initialization.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/DiamondCut/UpgradeLogic.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/Executor/_Executor_Shared.t.sol+7-5
- l1-contracts/test/foundry/l1/unit/concrete/Governance/PermanentRestriction.t.sol+6-6
- l1-contracts/test/foundry/l1/unit/concrete/Utils/Utils.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/ChainTypeManager/ChainTypeManagerSetters.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/ChainTypeManager/CreateNewChain.t.sol+3-4
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/ChainTypeManager/ProtocolVersion.t.sol-1
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/ChainTypeManager/RevertBatches.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/ChainTypeManager/_ChainTypeManager_Shared.t.sol+7-7
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/chain-deps/DiamondInit/Initialize.t.sol+9-9
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/chain-deps/DiamondProxy/DiamondProxy.t.sol+7-7
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/chain-deps/facets/Mailbox/FinalizeWithdrawal.t.sol+2-2
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/chain-deps/facets/Mailbox/ProvingL2LogsInclusion.t.sol+1-1
- l1-contracts/test/foundry/l1/unit/concrete/state-transition/chain-deps/facets/Mailbox/RequestL2Transaction.t.sol+3-2
- l1-contracts/test/foundry/l2/integration/L2Utils.sol+11-19
- l1-contracts/test/foundry/l2/integration/_SharedL2ContractL2Deployer.sol+1-1
- l1-contracts/test/foundry/l2/unit/GatewayCTMDeployer/GatewayCTMDeployer.t.sol+3-2
- l1-contracts/test/foundry/unit/concrete/chain-registrator/ChainRegistrar.t.sol+1-1
- l1-contracts/test/foundry/unit/concrete/script-utils/ScriptUtils.t.sol+17
- l1-contracts/upgrade-envs/v0.28.0-precompiles/mainnet.toml+62
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/mainnet/run-latest.json+3.5k
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/mainnet/v28-ecosystem-mainnet.toml+103
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/mainnet/v28-ecosystem-mainnet.yaml+143
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/mainnet/verification-logs+462
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/testnet/v28-ecosystem.toml+103
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/testnet/v28-ecosystem.yaml+119
- l1-contracts/upgrade-envs/v0.28.0-precompiles/output/testnet/verification-logs.txt+63
- l1-contracts/upgrade-envs/v0.28.0-precompiles/testnet.toml+55
- system-contracts/contracts/L2GatewayUpgrade.sol-109
- system-contracts/contracts/L2GenesisForceDeploymentsHelper.sol-236
- system-contracts/contracts/interfaces/IL2GenesisUpgrade.sol+1
- yarn.lock+1.0k-1.2k
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2691 | 2691 | | |
2692 | 2692 | | |
2693 | 2693 | | |
2694 | | - | |
2695 | | - | |
| 2694 | + | |
2696 | 2695 | | |
2697 | 2696 | | |
2698 | 2697 | | |
2699 | 2698 | | |
2700 | | - | |
2701 | | - | |
| 2699 | + | |
| 2700 | + | |
| 2701 | + | |
| 2702 | + | |
| 2703 | + | |
| 2704 | + | |
| 2705 | + | |
| 2706 | + | |
| 2707 | + | |
| 2708 | + | |
| 2709 | + | |
2702 | 2710 | | |
2703 | 2711 | | |
2704 | 2712 | | |
| |||
4272 | 4280 | | |
4273 | 4281 | | |
4274 | 4282 | | |
4275 | | - | |
| 4283 | + | |
4276 | 4284 | | |
4277 | 4285 | | |
4278 | 4286 | | |
| |||
10822 | 10830 | | |
10823 | 10831 | | |
10824 | 10832 | | |
10825 | | - | |
| 10833 | + | |
10826 | 10834 | | |
10827 | 10835 | | |
10828 | 10836 | | |
| |||
10839 | 10847 | | |
10840 | 10848 | | |
10841 | 10849 | | |
| 10850 | + | |
| 10851 | + | |
| 10852 | + | |
| 10853 | + | |
| 10854 | + | |
| 10855 | + | |
| 10856 | + | |
| 10857 | + | |
| 10858 | + | |
10842 | 10859 | | |
10843 | 10860 | | |
10844 | 10861 | | |
| |||
10905 | 10922 | | |
10906 | 10923 | | |
10907 | 10924 | | |
10908 | | - | |
| 10925 | + | |
10909 | 10926 | | |
10910 | 10927 | | |
10911 | 10928 | | |
| |||
10926 | 10943 | | |
10927 | 10944 | | |
10928 | 10945 | | |
| 10946 | + | |
| 10947 | + | |
| 10948 | + | |
| 10949 | + | |
| 10950 | + | |
| 10951 | + | |
| 10952 | + | |
10929 | 10953 | | |
10930 | 10954 | | |
10931 | 10955 | | |
| |||
11791 | 11815 | | |
11792 | 11816 | | |
11793 | 11817 | | |
11794 | | - | |
| 11818 | + | |
| 11819 | + | |
| 11820 | + | |
| 11821 | + | |
| 11822 | + | |
| 11823 | + | |
| 11824 | + | |
| 11825 | + | |
| 11826 | + | |
| 11827 | + | |
11795 | 11828 | | |
11796 | 11829 | | |
11797 | 11830 | | |
| |||
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
| 143 | + | |
143 | 144 | | |
144 | 145 | | |
145 | 146 | | |
| |||
161 | 162 | | |
162 | 163 | | |
163 | 164 | | |
| 165 | + | |
| 166 | + | |
164 | 167 | | |
165 | 168 | | |
166 | 169 | | |
| |||
0 commit comments