Skip to content

Latest commit

 

History

History
9 lines (5 loc) · 845 Bytes

README.md

File metadata and controls

9 lines (5 loc) · 845 Bytes

libSTARKs

STARKs (Scalable Transparent Argument of Knowledge) is a relatively complex zero-knowledge proof algorithm, and it would require significant effort to implement it from scratch in C++. However, there are libraries available that provide implementations of STARKs that can be used in C++ code.

One such library is libSTARK, which is an open-source C++ library for building STARKs. Here's an example code snippet that demonstrates how to use the library to generate a proof for a simple arithmetic circuit.

src.cpp

This code defines a simple arithmetic circuit that adds two numbers together, generates a proof for that circuit using libSTARK's Prover class, and then verifies the proof using libSTARK's Verifier class. Note that this is just a simple example, and more complex circuits and proofs would require additional code.