Self-hosted native Aztec transaction proving for browsers and dApps.
This repo packages Aztec Accelerator’s headless accelerator-server (runs native bb) behind a tiny Go edge proxy, with Docker and a Helm chart for k3s/Kubernetes.
It is the deployable counterpart to pointing Dark Forest Aztec (or any Accelerator-enabled dApp) at a local prover URL.
Not a classic Dark Forest snarker.
DF Aztec does not use Circom/snarkjs. Proving is Aztec PXE + nativebbvia Accelerator.
| Approach | Speed | Notes |
|---|---|---|
| Browser WASM proving | Slow | Default fallback when no accelerator |
| Accelerator on laptop | Fast | Great UX, machine must be on |
| aztec-prover on NUC/k3s | Fast + always-on | This repo |
Native bb is already the fast path. This project does not reimplement the prover in Go/TS. It:
- Runs official
accelerator-server(Rust) + cachedbb - Adds a Go proxy so Kubernetes can reach a process that binds loopback
- Ships Docker + Helm for one-command deploys
Browser dApp (e.g. https://aztec.dfpunk.xyz)
│ POST /prove (Accelerator SDK)
▼
SSH tunnel / port-forward / private ingress
│ http://127.0.0.1:59833 (or Service via proxy)
▼
┌──────────────────────────────────────────┐
│ Pod: aztec-prover │
│ │
│ :8080 Go edge proxy │
│ │ rewrites Host → 127.0.0.1 │
│ ▼ │
│ :59833 accelerator-server (loopback) │
│ │ │
│ ▼ │
│ bb 5.x (native, multi-thread) │
└──────────────────────────────────────────┘
accelerator-server binds 127.0.0.1 only and rejects non-loopback Host headers (anti DNS-rebinding). That is correct for desktop use, but a Kubernetes Service dials the pod IP, so probes//prove never hit the process.
The Go proxy listens on 0.0.0.0:8080, forwards to 127.0.0.1:59833, and sets Host: 127.0.0.1:59833. Proving stays native; only the edge is Go.
docker build -t aztec-prover:local .
docker run --rm -p 8080:8080 \
-e ALLOWED_ORIGINS='https://aztec.dfpunk.xyz,http://127.0.0.1:5173' \
-e AZTEC_VERSION=5.0.1 \
-e ACCELERATOR_VERSION=1.0.7 \
aztec-prover:localHealth:
curl -sS http://127.0.0.1:8080/healthz
curl -sS http://127.0.0.1:8080/readyz
curl -sS -H 'Host: 127.0.0.1:59833' http://127.0.0.1:8080/healthBrowser clients talk to whatever URL you tunnel/port-forward as
http://127.0.0.1:59833because the Accelerator JS SDK requires a loopback host. Use SSH/kubectl port-forwardon the client machine, not a public0.0.0.0bind in the browser config.
- Deploy this chart on your NUC/k3s (or run Docker on a always-on box).
- On the machine running the browser:
# example: port-forward Service to local 59833 kubectl -n aztec-prover port-forward svc/aztec-prover 59833:8080 # or SSH tunnel to the node ssh -N -L 59833:127.0.0.1:30080 user@nuc
- In DF Connection settings → Accelerator / prover URL:
http://127.0.0.1:59833 - Send a tx. Confirm in pod logs:
Received /prove→Starting bb prove→Proving succeeded.
helm upgrade --install aztec-prover ./charts/aztec-prover \
--namespace aztec-prover --create-namespace \
--set allowedOrigins='https://aztec.dfpunk.xyz,http://127.0.0.1:5173' \
--set resources.requests.cpu=4 \
--set resources.requests.memory=8Gi \
--set resources.limits.cpu=8 \
--set resources.limits.memory=16GiKey values (charts/aztec-prover/values.yaml):
| Value | Default | Purpose |
|---|---|---|
allowedOrigins |
DF + localhost | Browser origins allowed by accelerator |
aztecVersion |
5.0.1 |
bb version to pre-cache / request |
acceleratorVersion |
1.0.7 |
Headless server release |
persistence.enabled |
true |
PVC for ~/.aztec-accelerator bb cache |
resources |
CPU/mem heavy | bb is multi-threaded CPU |
service.type |
ClusterIP |
Prefer tunnel/port-forward; avoid public LB |
proxy.authToken |
"" |
Optional bearer for non-browser callers |
- Give it real CPU —
bbscales with cores; 4–8+ cores recommended. - Persist the bb cache PVC — avoid re-downloading on every pod restart.
- Pin
aztecVersionto the dApp SDK line (DF Aztec uses5.0.1today). - One busy prover per node first; horizontal scale only after measuring queueing.
- Keep witnesses off the public internet — ClusterIP + SSH/
port-forward/Tailscale.
- Accelerator still enforces loopback
Host(proxy rewrites it on the internal hop). ALLOWED_ORIGINSdeny-by-default for browserOrigins.- Optional
PROXY_AUTH_TOKENon the edge for non-browser callers. - Do not put this on a public LoadBalancer without TLS + auth + threat review.
/provecarries private witness material — treat like a secret-handling service.
cmd/proxy/ Go edge proxy
Dockerfile Multi-stage: build proxy + fetch accelerator + bb
docker-entrypoint.sh Start accelerator then proxy
charts/aztec-prover Helm chart
scripts/ Helper scripts (download, kind smoke)
| Component | Language | Why |
|---|---|---|
| Prover | Official Accelerator + bb (Rust/C++) |
Fastest correct path; don’t rewrite |
| Edge proxy | Go | Tiny static binary, great for k8s sidecars/edges |
| Packaging | Docker + Helm | k3s-native deploy |
Rewriting the prover in TypeScript would be slower (WASM). A from-scratch Rust prover duplicates Accelerator without benefit.
Pod / container logs should look like:
Received /prove request
Requested Aztec version version=5.0.1
Starting bb prove ...
Proving succeeded
Browser console (DF) should show Accelerator phases ending in Phase: proved without fallback.
- This repo: MIT
- Aztec Accelerator: AGPL-3.0 (upstream binary downloaded at image build/runtime — comply with upstream terms when distributing images that bundle it)
bb/ Aztec packages: see AztecProtocol/aztec-packages