DEV Community

Johnson Chidera
Johnson Chidera

Posted on

Zero Knowledge Proofs vs. Fraud Proofs

Introduction

Proofs are an important aspect in cryptography. In this article, I will explain two of the most popular proofs: validity proofs that utilizes zero knowledge cryptography and fraud proofs. What makes each of them unique and their various use cases.

What are zero knowledge proofs

Zero knowledge proofs or zk proofs are ways of telling a verifier that you know some piece of information without actually revealing the information that you (the prover) knows. Privacy and security are achieved on public blockchains with zero knowledge proofs.

A zero knowledge proof must satisfy the following requirements:

  • Completeness: For a proof to be complete, the verifier must be able to determine that the prover is in possession of a particular piece of information.

  • Soundness: For a proof to be sound, the verifier cannot be convinced that the prover has a particular piece of information when in actuality, the prover does not possess such information.

  • Zero knowledge: For a proof to be zero knowledge, the verifier must not know anything regarding the information the prover has except whether such information is true or false.

Types of zero knowledge proofs

There are two types of zk proofs:

  • Interactive zk proofs: For interactive zk proofs, the prover and verifier interact with one another several times. The prover completes challenges issued by the verifier in order for the prover to gain the trust of the verifier and for the verifier to be sure that the information the prover has, exists and is valid.

  • Non-interactive zk proofs: For non-interactive proof, the prover and verifier do not interact at all. Instead an automated system is used to verify the prover's claims. By using an automated system, Non-interactive zk proofs require additional software and computational power.

Some examples of zero knowledge technologies:

  • Zero knowledge succinct non-interactive argument of knowledge (zk SNARK): An example of a cryptocurrency that uses Zk SNARK is Zcash. Zcash uses zk SNARK to better protect the privacy of it's users.

  • Zero knowledge scalable transparent argument of knowledge (zk STARK): An example of a decentralized finance that uses zk STARK is DeversiFi

Real world applications of zero knowledge proofs

Zero knowledge proofs can be used in a wide range of scenarios where data privacy and security are paramount. Such scenarios may include:

  • Blockchains
  • User Verification
  • Finance
  • Machine learning

Limitations of zero knowledge proofs

  • zk proofs require lots of time and computational power.
  • zk proofs cannot give 100% certainty that a claim exists and is valid. It basically minimizes the probability of a claim being false.

What are fraud proofs

Fraud proofs use a Dispute Time Delay (DTD) system. If a fraud proof is submitted within the DTD and has incorrect state transitions, changes made to the state are reverted and validators are penalized. If no fraud proof is submitted within the DTD, the state transition is considered correct.

Fraud proofs use Optimistic rollups that reduces costs and latency levels for decentralized applications on a blockchain network.

The main advantage of fraud proof is that they are not needed for every state transaction which means fewer computational resources are used and this promotes scalability.

The main disadvantage of fraud proof is that fraud proofs cause interactions between different parties. Thereby creating a space for these parties to commit fraud.

Closing remarks

Validity proofs are needed for each transaction and they ensure that nothing other than correct state transitions are accepted while in the case of fraud proofs, they are only needed when there are incorrect state transitions.
Both validity proofs and fraud proofs are different ways of proving the validity of information and are both tools used in Layer-2 scalability solutions. Each with it's own advantages and disadvantages.

Further reading

Below is a curated list of articles I believe are worth having a look at:

  1. Zero knowledge EVM

  2. Zero knowledge rollups

  3. Snarks vs Starks

  4. Polygon zk rollups

  5. Ethereum scaling solutions

Top comments (1)

Collapse
 
marvelous007 profile image
marvelous-007

Great article! very informative ,
fraud proofs cause interactions between different parties, can you elaborate?.