Images

General overview and information about the concept of images in Fermah.

Image

Users are free to create their own Docker images, where program binaries, zkVM-specific code, input files, and output files are all self-contained.

These images are expected to be hosted somewhere public and accessible to our network's nodes to be able to be fetched when the proofs are being computed. Usually a CDN with an HTTP download URL like Amazon S3 or Cloudflare R2.

Fermah processes two kinds of images: Prover images and Verifier images. You can either submit Proof Requests for existing images or create your own. When creating your own Prover and Verifier images, it is important to separate your program's proving and verifying logic.

To find out how images are specified in the proof request, see Configuration.

Prover Image

A Prover image is a Docker image that contains everything needed to generate proof for a specific program. It typically includes:

  • Guest code (the program to be proven) or binary (usually in ELF format).

  • Host code (instructions for generating keys and public parameters).

  • A zkVM (zero-knowledge virtual machine) and its dependencies.

  • Input arguments or setup parameters.

  • Serialized output to a state file.

The contents of a Prover image depend on the program and zkVM used, and you must ensure it captures the correct logic. Most zkVMs offer a “development mode” to test execution without generating a full proof. A hash of the Prover image, along with hardware requirements, is included in the Proof Request payload sent to Fermah’s network. For more information on the Proof Request payload and submission process, refer to Submission.

Verifier Image

A Verifier image is a Docker image that contains everything needed to verify a proof generated by the corresponding Prover image. It typically includes:

  • A verification key.

  • Shared setup parameters.

  • Any public outputs of the program.

Unlike a Prover, a Verifier does not generate a proof but instead loads the proof file and runs verification. The output is either exit code 0 (success) or an error code/message indicating failure.

Last updated

Logo

© 2024 Fermah