Skip to content

primus-labs/aztec-demo

Repository files navigation

aztec-demo

Overview

Origin README.

Prove and verify that your spot wallet balance on Binance exceeds 10 USDT.

Installation

Follow the documentation here to install the nodejs (v22+) and enable yarn.

Follow the documentation here to install the sandbox.

IMPORTANT! Using the Aztec Sandbox version 3.0.0-nightly20251016:

aztec-up 3.0.0-nightly.20251016
docker tag aztecprotocol/aztec:3.0.0-nightly.20251016 aztecprotocol/aztec:latest

Checking by aztec --version will output 3.0.0-nightly.20251016.

Quick Start

  1. Start an Aztec sandbox
PXE_PROVER_ENABLED=1 aztec start --sandbox
  1. Compile att_verifier and real_business_program
# in current folder
bash ./compile_verifier_and_program.sh

If you have modified att_verifier or real_business_program, please rerun this command.

  1. Prepare the client environment
# inside dvc_client/
npm install

# inside js_test/
yarn
  1. Deploy contracts on Aztec chain.
# inside js_test/
# deploy contracts (could be deployed once)
yarn start:deploy

If you have modified att_verifier or real_business_program, please rerun this command.

  1. Configure .env inside dvc_client/.
  • Copy .env.example to .env.
  • Set your PRIVATE_KEY start with 0x.
  • Set your BINANCE_API_KEY and BINANCE_API_SECRET.
  • Switch the CHAIN_ID and RPC_URL if you want to run on different chain. (The default is Base Sepolia)

The previous steps are all preparatory.

  1. Run zktls to generate attestation.

For convenience: This step and the next step can be combined into one step (See 8).

# inside dvc_client/
node src/demo_binance.js

This will generate a binance-attestation.json file if successed.

  1. Verify on Aztec chain.
# inside js_test/
yarn start:verify ../dvc_client/binance-attestation.json
  1. Combine step 6 and step 7.
bash ./run_zktls_and_verify_on_aztec.sh

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors