x402 · Algorand · facilitator verification

The x402 correctness layer.

A USENIX study found correctness violations in every major x402 facilitator tested. Ward checks whether yours actually holds up — against a real, self-hosted facilitator, not a mock.

Ward's own last run
8/8
invariants passed, real self-hosted facilitator
A missing piece of x402 infrastructure — a real correctness test suite. Read the docs →
8
Adversarial invariants
5
Must-have, zero tolerance
4
USENIX violation classes
15/15
Facilitators failed the study

Real facilitator, not mocks

Every check runs against a real, self-hosted facilitator.
Live TestNet transactions over the real x402-avm implementation — never a simulated stand-in.

Adversarial by design

Invariants come from a real security study, not guesswork.
Derived from the x402 protocol spec and a peer-reviewed USENIX study of real facilitator failures.

Chain-agnostic core

A second chain is a new adapter, not a rewrite.
Universal invariants never import Algorand-specific code — the boundary is enforced, not assumed.

The suite

Eight invariants, zero assumptions.

Every result ships reproducible evidence — request/response pairs, on-chain transaction IDs, and the exact source it's checking against.

ID Invariant Category Tier
U1
Verify/settle consistency
x402 protocol spec + USENIX — Free Shopping, Asset Theft
universal must-have
U2
Retry safety
USENIX — Free Shopping via naive retries
universal must-have
U3
Concurrent double-settle
USENIX — concurrency races
universal must-have
U4
Allowlist enforcement
x402 spec — /supported must be authoritative
universal must-have
A1
Atomic group integrity
Algorand atomic groups + verifyFeePayerTransaction — all four USENIX classes
algorand must-have
U5
Gas abuse resubmission
USENIX — Gas Abuse
universal stretch
A2
ASA opt-in precheck
Algorand ASA opt-in requirement
algorand stretch
A3
Rekey authorization
Algorand rekeying — settle() must not trust pre-rekey authority
algorand stretch
Get started

Two ways to run Ward.

Run it yourself

Open-source CLI. Boots a self-hosted facilitator, funds test accounts, and runs the full suite against it.

# clone, install, verify
npm install
ward init
ward test

Pay per check

A hosted, x402-gated endpoint: pay once in USDC, submit any facilitator URL, get a real pass/fail report back.

# $1.00 per full run
POST /verify-facilitator
{ "facilitatorUrl": "..." }