Unveiling ZK in Blockchain: A Comprehensive Overview of ZKEVM and Innovative Projects
ZK Rollup is the star of Layer 2 projects, and its difficulty is also exceptionally high. The basic idea is to utilize zk technology to submit the execution results of Layer 2 along with a proof to Layer 1, which then verifies and puts it on-chain.
In Layer 2, a virtual machine (VM) is required to execute bundled transactions. This type of VM based on zk technology is called zkVM. If this virtual machine is compatible with Ethereum smart contracts, it is referred to as zkEVM.
EVM
First, let’s understand the execution process of an EVM contract: The contract is compiled into bytecode, and then the bytecode is executed through the EVM.
What is zkEVM?
zkEVM is a virtual machine that supports the execution of Solidity contracts through zk technology.
According to Vitalik’s classification, there are four types of zkEVM:
Vitalik’s four classifications are viewed from a product perspective. From an implementation perspective, there are generally two approaches to implementing zkEVM:
Zero-knowledge proof algorithms
Currently, there are two mainstream zero-knowledge proof (zkp) algorithms.
Among them, ZK-SNARK has a trusted setup process, which involves precomputing a set of parameters using secret information. If this secret information is leaked, it can potentially compromise the security of the system. Therefore, this secret information is also referred to as “toxic waste,” as it poses a security risk.
For ZK-STARK, one of its design goals is to eliminate the need for a trusted setup. It utilizes advanced mathematical techniques such as polynomial interpolation and low-degree pseudo-random functions. These techniques make the process of constructing STARK parameters more transparent, decentralized, and independent of toxic waste. This advantage of STARK in terms of verifiability and scalability provides higher security and trustworthiness in the deployment and usage of the system.
What is the relationship between zkp and zkEVM?
Related projects to zkEVM
Applied ZKP
The Ethereum Foundation’s zk project, aiming for Type 1 zkEVM implementation, which means achieving full Ethereum compatibility.
Open-source repository:?https://github.com/privacy-scaling-explorations/zkevm-specs
领英推荐
Polygon zkEVM
Polygon zkEVM is a result of Polygon’s acquisition and integration of a ZKR (Zero-Knowledge Rollup) project called Hermez. It operates by implementing EVM opcodes through circuits.
Open-source repository:?https://github.com/orgs/0xPolygonHermez/repositories
Currently, Polygon zkEVM is classified as Type 3, but the ultimate goal is to achieve Type 2 to Type 2.5 compatibility.
Scroll
Scroll is also open-source and can be found at?https://github.com/scroll-tech
Similar to Polygon, Scroll operates by implementing EVM opcodes through circuits.
Currently, Scroll is categorized as Type 3, but the ultimate goal is to achieve Type 2 to Type 2.5 compatibility.
Taiko
Taiko’s goal is also to achieve Type 1 compatibility, which means aiming for full Ethereum compatibility in their implementation.
Open-source repository:?https://github.com/taikoxyz
zkSync
zkSync belongs to Type 4. Currently, it is open-source. Thanks for Porter Adams’ reminder.?@porteradams12
zkSync is the collective term for the entire zkRollup protocol developed by Matter Labs.
zkSync Era is a chain that runs zkVM.
The approach of zkSync involves using its own LLVM compiler to compile contract code, such as Solidity code, into the desired bytecode format (instead of EVM opcodes). This compiled bytecode is then passed to zkVM for execution.
Starkware
StarkWare is an Israeli technology company that specializes in building scalable solutions based on zkSTARK (Zero-Knowledge Scalable Transparent Argument of Knowledge).
StarkNet is the blockchain operated by StarkWare.
SNVM (StarkNet Virtual Machine) is the contract virtual machine running on StarkNet. The SNVM virtual machine utilizes zkSTARK technology to enable smart contract execution.
Cairo is the programming language used to write smart contracts that run on StarkNet.
Originally, StarkNet and zkEVM were not directly related, as StarkNet primarily focused on zkVM. However, Nethermind’s Warp project provides a compiler that can compile Solidity code into Cairo, effectively transforming StarkWare’s StarkNet into a Type 4 implementation.
Below is a comparison of various products:
The further to the right, the better the EVM compatibility, but also the greater the implementation difficulty.
Ref