Back
workshop

23rd January 2024

17:45 UTC

Workshop host:

In this video, Brian Retford shares details about RISC Zero and its ZKVM before answering the (many!) questions from ZK Hack IV audience. Dr. Iryna Tsimashenka then dives into the intricacies of how the ZKVM works and provides a walkthrough explaining how to get started with building a ZK app. In the last part of the workshop, Hans Martin covers how to use ZK on-chain to enable trustless verifiable authentication, and presents a demo of RISC Zero's Bonsai Pay.


Click the link for Dr. Iryna Tsimashenka's slides: Get Rusty with RISC Zero: Build your ZK Rust Application

Video summary

This workshop aimed to introduce ZK Hack audience to RISC Zero's products, namely their ZKVM (zero-knowledge virtual machine) and Bonsai, and to provide hands-on guidance for building ZK applications using Rust.

The session started with Brian Retford, RISC Zero's CEO, sharing about their mission to revolutionize the Internet by empowering web3 developers worldwide with ZK software infrastructure. He emphasized the company's journey from its inception in 2020, highlighting the adoption of the open-source RISC-V microarchitecture to simplify ZK programming, and how it impacts RISC Zero's ZKVM architecture. Brian stressed the importance of the general-purpose ZKVM to allow developers to focus on building programs rather than managing complex circuits, and how its versatility enables a wide range of applications, from blockchain to embedded systems. He also mentioned some key challenges such as memory access verification or efficiency trade-offs.
Then throughout a lively Q&A session, Brian and the online participants engaged in a long discussion covering topics such as ZK machine learning, technical details of proofs' generation, privacy-preserving apps, ZKVM performance benchmarking, or integrating ZK with off-chain execution. As in the previous session, it was quite a delight to witness such an engaged audience!

In the second part of the workshop, Dr. Iryna Tsimashenka first clarified the terminology used within RISC Zero and delved into the different steps of the ZKVM architecture to prove and validate the execution of Rust code. She also explained how RISC Zero's proof system architecture supports parallel proof generation and scalability, featuring a recursive mechanism to aggregate multiple proofs into a single STARK proof.
Iryna demonstrated how the quick start guide facilitates ZKVM usage, allowing developers to easily create projects with Rust and host components. She also showed the participants how developers can test code in developer mode before switching to production mode for proof generation.

And in the last segment, Hans Martin transitioned to discussing Bonsai, a recent addition to RISC Zero's ecosystem. Its purpose is to leverage on how ZK can be used for privacy, security, and interoperability, minimizing trust in the process – like Google or Apple logins, but made more secure and private using ZK techniques. Hans focused on the most common internet login setups: OAuth2 and OpenID Connect. His question: How to hack ZK into this setup, tying traditional authentication protocols with ZK for on-chain applications? His answer: User-held signing keys, typically an Ethereum account, tightly coupled with OpenID Connect. He explained how adding Ethereum addresses to authentication payloads enables a trustless link between web2 and web3, with SNARK-powered on-chain verification. As he mentionned, this opens the door to traditional login methods on blockchains and smart contract wallets – and this is what the Bonsai Pay demo illustrated.
After a last invitation to explore the repos and dive into the docs, this was the end of RISC Zero's workshop!