Skip to main content

Circuit internals

OpenAC’s reference implementation uses Circom circuits compiled via circomkit scripts in wallet-unit-poc/circom/scripts/compile.shnot Noir.

Named circuits

From compile.sh usage string:

NameRole
jwtDefault-size JWT / ES256 prepare path
jwt_1kjwt_8kPayload-size variants for benchmarks
showDevice binding + generalized predicates
ecdsaECDSA helper / building block
mdocExperimental mdoc path

All circuits in this repository are written in Circom + Spartan2; the project does not ship any Noir circuits.

Base vs OpenAC layer

  • Prepare (jwt_*): signature verification, parsing, claim extraction — issuer trust anchor.
  • Show (show): binds device signature on verifier challenge + evaluates predicates over normalized claims — policy layer.

Rust ecdsa-spartan2 links compiled C++ witness generators from wallet-unit-poc/circom/build/cpp/ for proving performance.

Tests

yarn test under wallet-unit-poc/circom/ runs Mocha suites (tests/**/*.test.ts) including expression / utility coverage.