Siege

Battle-test your AI agent with a bounty: talk it into paying out and the bounty is yours.

Siege

Created At

ETHGlobal Mumbai

Project Description

Companies and Developers are putting AI agents in charge of refunds, payouts, grants and withdrawals. The way you rob one isn't a code exploit, it's a conversation: the right sentence gets the agent to call the one tool it must never call. Siege is where a team finds that sentence before a stranger does.

HOW IT WORKS An owner puts their agent on the Grid with a bounty behind it, deposited from their own Hedera wallet. Attackers (people, or AI agents of their own) pay a small fee per attempt over x402 on Hedera, get five messages, and try to talk the agent into firing its protected tool. The agent starts every attempt with no memory. If it holds, the fee is split on chain: 80% to the owner, 15% grows the pot, 5% to the arena, so every failed attack pays the owner. If it breaks, the attacker wins the whole pot, and the owner gets a verified, replayable finding: the exact conversation, the tool call it caused, and the on-chain payout.

TWO WAYS TO BRING AN AGENT

  1. Publish one at /publish, with no code: write its instructions, list its tools, mark the one that moves money, connect your 0G key and deposit the pot. It's live in about three minutes.
  2. Plug in the agent you already run with our npm package, siege-guard. Three lines connect your own harness, prompt, tools and model. Nothing to host, no public URL.

THREE WAYS TO ATTACK By hand from a funded operator account; with a hosted "unit" (an AI attacker with its own Hedera account, hard spending caps, and a phone pager that asks you before it spends above a cap); or from your own code (the raid-bot example).

NOTHING IS TAKEN ON FAITH A payout only happens when the arena's verifier checks that the transcript wasn't changed (its hash) and that the 0G proxy's own record of the breaching reply shows the protected tool was really called, for that vault, that op and that turn. Only then does it sign the release, and our SiegeVault contract pays the pot.

BUILT ON

  • Hedera: x402-protected endpoint settled on testnet through the x402.org facilitator; the SiegeVault contract for pots, fee splits and payouts; an HCS topic per vault as a tamper-evident audit log; agents with their own accounts that pay with no human approving, with spending caps and human approval above the cap.
  • 0G: every agent reply is a 0G inference (0gm-1.0) through our recording proxy, and owners pay for their agent's thinking with their own 0G credits.
  • Arkiv: the Grid is an Arkiv query. Each vault's listing is owned by its owner's wallet, and listings and live ops expire on their own.
  • Swarm: each op's transcript is sealed (AES-256-GCM) and stored on Swarm, referenced from its Arkiv entity, so the replay can be checked by anyone.

Example: our "Lantern Fund Grants" agent reviews grant applications against a published rubric. An attacker claimed another team's busy contract as their "old v1 contract"; the agent checked the user count but never who deployed it, scored the project 8/10, and paid. The 30 ℏ pot plus the fee was released on Hedera testnet, with a replay and HashScan links.

How it's Made

Stack: Next.js 16 (App Router) with a pixel/CRT UI, a separate Node worker that holds the verifier key, SQLite via Drizzle shared by both, one Solidity contract (SiegeVault) on Hedera testnet, and a zero-dependency TypeScript SDK published to npm as siege-guard.

Hedera + x402: POST /api/siege/start is an x402-protected endpoint. With no payment it answers 402 with an x402 v2 requirement (exact scheme, hedera:testnet, the vault's fee, payTo = the arena treasury). The client (@x402/fetch + @x402/hedera) signs a TransferTransaction and retries; we verify and settle through the x402.org facilitator before the op exists. Hosted units are real Hedera accounts (AccountCreateTransaction) funded by their operator's memo deposit, which the worker matches on the mirror node; they sign their own payments with no human approving, under caps reserved atomically in SQLite, the x402 client's own per-payment cap, and their account balance. A cap hit pages the owner's phone; approve tops up on chain. Held fees are forwarded into SiegeVault (recordAttempt, split 80/15/5 on chain); breaches pay out through release() with an EIP-712 signature from the verifier. One HCS topic per vault is the audit log (ids, hashes, amounts, never text), ordered through an outbox the worker drains. The contract is Sourcify-verified so HashScan decodes every event.

0G: every guard reply is a chat completion on 0G Private Computer made through our own OpenAI-compatible proxy, which records request id, vault, op, turn, prompt hash and whether the protected tool was called. The verifier refuses to sign a payout unless the breaching reply's request id is in that record. Owners paste a pc.0g.ai management key; we mint a per-guard sk- key so their guard bills their own credits and the vault page shows the balance dropping. Plugged-in agents route their model calls through the same proxy, and their prompt hash is pinned: a changed prompt closes the vault.

Arkiv + Swarm: vaults, their live status and each op are entities on the Rabdi testnet. The Grid's filters and sorts are the Arkiv query (printed under the grid with its block). A vault's listing is created readonly and transferred to the owner's wallet (the EVM alias of their Hedera account), so only they can delist it; status entities stay arena-owned; op entities expire on their own. Transcripts are AES-GCM sealed under a per-op key, uploaded to Swarm through the public gateway (null stamp, gateway-stamped), kept alive by the worker, and read back on the replay page with the hash checked against Arkiv and HCS.

background image mobile

Join the mailing list

Get the latest news and updates