Skip to content
QORECHAIN
Register

Post-Quantum AI Agents

Attenua

Post-quantum capability rules for AI agent treasury swarms.

Share on X

About

Attenua is an institutional treasury dashboard and post-quantum smart-contract system for autonomous AI agent swarms on QoreChain (qorechain-diana, EVM Chain ID 9800). Production AI teams rely on an Orchestrator spawning specialized sub-agents (Allocator, Payables, Research). Under QoreChain MsgExecuteEVM, linked authenticators share the parent account's 0x origin—meaning a single shared key lets a prompt-injected sub-agent drain the vault, while requiring cold human ML-DSA-87 signatures per task breaks autonomy. Attenua solves this with hierarchical capability attenuation: every child agent holds strictly less authority than its parent on chain across five monotonic invariants—budget conservation, narrowed ERC-4626 liquidity bands, action bitmasks, expiry, and depth—with zero msg.sender trust and fail-closed ML-DSA-87 verification (0x...0a02 key status + 0x...0a01 signature verification). Live on qorechain-diana: • 4 Hallmark-verified contracts (full match, PQ-guarded): AttenuaVault v1.1, renounced QoreChainHybridHolderGuard, LiquidityVault, and ReserveVault. • Dual x/abstractaccount isolation: Owner AA #1 (Just-in-Time 10 fUSD/tx cap, zero standing ERC-20 allowance) and isolated Monitor AA #2 (0 fUSD, freeze() only). • 3-sub-agent swarm: oracle-free ERC-4626 Allocator, 3-signature atomic ML-DSA-87 Payables, and zero-budget Research prompt-injection screener via MCP. • 9/9 security invariants held, 9/9 happy-path transactions verified (H1–H7), and 10/10 live attacks refused on chain (A1–A10), reproducible keyless with `cd agent && npm run verify` (19/19 PASS) and `npm test` (7/7 PASS, 200 fuzz runs).

How it's made

We built Attenua using an empirical, spike-first workflow driven by a human-directed dual-model adversarial loop (documented with 16 caught mistakes in AI_USAGE.md and docs/ai/). 1. Step 0 Empirical Testnet Spike (S1–S8) Before freezing the spec, we deployed SpikeProbe on qorechain-diana (block 10513230) to test 8 live protocol assumptions. Probing directly on chain proved MsgExecuteEVM msg.sender aliasing (S1), denom_limits ERC-20 capping (S2), allowed_evm_calls selector filtering (S3), inactive precompile empty returns (S4), live 1x/2x/3x ML-DSA-87 gas costs (249k / 430k / 630k, S5), and that @qorechain/sdk v0.14.0 shares account-wide rules across linked keys (S8). That last discovery shaped our dual-account design: isolating Monitor onto dedicated AA #2 (0 fUSD, locked to AttenuaVault.freeze()) and restricting Owner AA #1 to a single Orchestrator authenticator. 2. Contracts, Kits & Network Features • Solidity (solc 0.8.28, viaIR, cancun): Built AttenuaVault.sol (zero msg.sender / onlyOwner checks, monotonic capability lattice, O(1) revokeRootEpoch() kill-switch) and fail-closed PqcVerifier.sol calling pqcKeyStatus (0x...0a02, requiring possessionProven == true) and pqcVerify (0x...0a01). • @qorechain/asset-kit (Apache-2.0 only): Vendored QoreChainHybridHolderGuard (exempted AttenuaVault and renounced ownership to 0x0 inside a scoped EVM window to close the Ownable2Step classical-key gap) and dual ERC-4626 QoreChainRwaVault sleeves (LiquidityVault + ReserveVault), computing weights on chain via convertToAssets() with zero external oracle. • Agent Runtime & MCP: Built deployment, live H1–H7 + A1–A10 runner, 19-check keyless verifier, and 200-run fuzz suite using @qorechain/sdk, @qorechain/evm, @qorechain/pqc, and @qorechain/qoresign, plus a read-only Node.js MCP server (@modelcontextprotocol/sdk) powering the zero-budget Research prompt-injection screener. • Source Verification & Dashboard: Claimed all 4 contracts on HallmarkRegistry inside a tightly closed scoped EVM window (full match) and built a read-only React + Vite + viem dashboard with live RPC telemetry, Attack Theatre inspector, and keyless QoreX/HolderGuard wallet posture checker. 3. What Was Hard • EIP-7623 Calldata Floor & Spend-Probe Gas: Three 4,627-byte ML-DSA-87 signatures (~14 KB calldata) hit a ~582k EVM calldata floor; early A3/A5/A6 reverts failed at floor gas (0 gas used) before reaching vault guards. Raising evmGasLimit to 1,200,000, adding +700k Cosmos gas buffer for x/abstractaccount's ERC-20 spend probe, and asserting non-zero EVM gas in npm run verify ensured every attack refusal is genuine. • Zero-Context Blind Security Audit: Running an isolated blind red-team audit on v1.0 uncovered three High issues—self-delegated zero-budget Research clearance bypass (H-01), parent reclaim with open descendants (H-02), and an immutable monitor freeze trap (H-03). All three were patched in AttenuaVault v1.1 and proven live with Attack A10. • Browser RPC Resilience: Concurrent 6-call browser eth_call bursts triggered HTTP 503 rate limits on evm-testnet.qore.host, resolved with pairwise request throttling and short-lived caching in web/src/lib/chain.ts.

Timeline

AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 6167981 docs: polish README, strengthen AI_USAGE for AI-Native award, harden gitignore · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 1a7d853 fix(web): type runInPairs cleanly for tsc build · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • bda98f8 fix(web): throttle EVM RPC reads to avoid testnet 503 bursts · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 655bacb docs: add Built on QoreChain and Hallmark badges to README · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • c68b5b5 feat: verify and claim all 4 Attenua contracts on Hallmark · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 0cfa684 fix(web): align tree/timeline connectors, upgrade EIP-6963 wallet UX, drop failing REST fetches · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • bec7d73 feat: add adaptive favicon and Figma-built 16:9 cover image · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • c438cd0 feat(security,tests,web): harden AttenuaVault v1.1 after blind audit, fix live SDK RPC, add test suite, agent session & 16:9 cover · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 79d02c4 feat(web): turn Connect QoreX button into live PQC & HolderGuard posture inspector · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 3085dff feat(web): implement Figma design system with motion micro-interactions & update AI model attribution · agvswira
AttenuaPost-Quantum AI Agents

Pushed 2 commits to main

  • 683ee4f chore: use canonical GitHub Apache-2.0 LICENSE text for automatic detection · agvswira
  • 0aaa528 feat: initialize Attenua with Step 0 Diana spike (8/8 pass), post-spike SPEC, and compiled AttenuaVault + asset-kit contracts · agvswira
AttenuaPost-Quantum AI Agents

Pushed 1 commit to main

  • 7cc5915 feat: live qorechain-diana deployment, 9-attack suite, keyless verifier, web dashboard & threat model · agvswira
AttenuaPost-Quantum AI Agents

New project.

Comments and questions

  • No comments yet.