zkAttest

Private
Attestations.

Commit to claims off-chain. Prove them on-chain. Credit bands, KYC booleans, score ranges — verified without revealing the underlying data.

Next: zkScore →

Claim types.

credit_band

Credit Band

Prove your credit tier — Bronze, Silver, or Gold — without revealing your raw score.

{ kind: "credit_band", band: "gold" }
kyc_bool

KYC Boolean

Prove you have been verified by a KYC provider without revealing who the provider is or what data was checked.

{ kind: "kyc_bool", verified: true }
score_range

Score Range

Prove your score falls within a range — e.g. 700-749 — without revealing the exact number.

{ kind: "score_range", min: 700, max: 749 }

How it works.

The issuer computes a Poseidon hash of the claim data and stores it as the commitment. The commitment root is registered on-chain. When the subject wants to prove a claim, they generate a Groth16 proof from the commitment — without revealing the raw claim.

Anyone can verify the proof against the on-chain commitment root. The verifier learns only that the claim is valid — not the claim itself.

zkattest.ts
// Issuer: commit to a claim
const { commitment, nullifier } =
  await cloak.zkAttest.commit({
    subject: wallet.address,
    claimType: { kind: "credit_band", band: "gold" },
    issuer: issuer.address
  })

// Subject: prove the claim
const { proof, publicSignals } =
  await cloak.zkAttest.verify({
    commitId: commitment.id,
    proof: zkProof,
    publicSignals
  })

// Anyone: verify on-chain
const valid =
  await AttestationRegistry.isValid(proof.commitId)

Features.

Poseidon Hashing

All commitments use the Poseidon hash function — ZK-friendly, resistant to ASIC/GPUs, ideal for Merkle trees and accumulators.

Groth16 Proofs

Efficient on-chain verification. The Groth16 verifier runs in ~200k gas on Ethereum — cheap enough for every settlement.

ERC-8183 Aligned

Attestation schema follows the ERC-8183 reputation attestation standard. Compatible with the broader Ethereum identity ecosystem.

Nullifier Anti-Replay

Each attestation has a unique nullifier. The same attestation cannot be verified twice — prevents replay attacks.

Issuer Authorization

Only authorized issuers can commit attestations. The issuer field is part of the commitment — cannot be swapped.

On-Chain Registry

The AttestationRegistry contract stores commitment roots. Anyone can verify a proof against a registered root.