Free-Riding the Agentic Web: A Systematic Security Analysis of x402 Payments
Not on the map. Why?
Abstract (arXiv)
The x402 protocol has crossed from prototype to infrastructure for the agentic web, driving 130 million all-time transactions and embedded in Google Cloud, Cloudflare, and Stripe. Yet bridging synchronous HTTP requests with asynchronous blockchain finality creates state-synchronization challenges, and x402's security has so far been examined only in piecemeal vendor disclosures. It is moreover not one artefact but a stack of an HTTP semantic, per-chain schemes, and a long tail of SDK and deployment choices whose required guarantees prior work has not established. We perform a systematic security analysis organized around five invariants grounded in specifications, literature, and vendor expectations, resolving every violation to the responsible layer. We identify four flaw classes: cross-resource substitution, duplicate-settlement race (independently corroborated by subsequent third-party reports), allowance overdraft, and denial of settlement. Against official SDKs and a production deployment, these reach resource-leakage ratios up to 100%. For pay-per-token scheme we prove a structural limit: no output-only pricing can be both fair to honest users and bounded against inflation of the hidden "thinking" tokens, the price of fairness being a √1+Theta manipulation gap. We propose per-flaw mitigations and a defense triple with provable guarantees, cutting per-call reasoning cost by 47% and inverting attacker leverage from 8.7× to 0.9× at only 2.8% overhead. All findings have been disclosed.
Key facts. Cited by 5 papers in the map (data through 7 Oct 2026). First posted on arXiv 29 May 2026.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2026: 5.
5 papers.
- 2026Can Trustless Agents Be Trusted? An Empirical Study of the ERC-8004 Decentralized AI Agent Ecosystemcited by 2
- 2026How Agentic Is Agentic Commerce? A Population-Scale Measurement of x402 Adoption and Authenticitycited by 2
- 2026Protocol-Level Attacks on Agentic Commerce Platforms: A Cross-Platform Taxonomy, AIP-Bench, and Unified Defensecited by 1
- 2026A Formal Analysis of Agent Payment Protocolscited by 0
- 2026SoK: Decentralized Agent Economic Infrastructurecited by 0
- 2026SoK: Decentralized Agent Economic Infrastructure1 Oct 2026
- 2026A Formal Analysis of Agent Payment Protocols30 Aug 2026
- 2026Protocol-Level Attacks on Agentic Commerce Platforms: A Cross-Platform Taxonomy, AIP-Bench, and Unified Defense23 Jul 2026
- 2026How Agentic Is Agentic Commerce? A Population-Scale Measurement of x402 Adoption and Authenticity14 Jul 2026
- 2026Can Trustless Agents Be Trusted? An Empirical Study of the ERC-8004 Decentralized AI Agent Ecosystem24 Jun 2026
Similar, not cited
Close in wording, no citation either way
- 2026Five Attacks on x402 Agentic Payment Protocol
- 2026A402: Binding Cryptocurrency Payments to Service Execution for Agentic Commerce
- 2026Beyond the Mandate: A Systematic Security Analysis of the Agent Payments Protocol (AP2)
- 2026The Web4 Agent Economy: A Large-Scale Empirical Study of the Landscape, Challenges, and Opportunities ↗
- 2026Hardening x402: PII-Safe Agentic Payments via Pre-Execution Metadata Filtering
- 2026Zero-Trust Runtime Verification for Agentic Payment Protocols: Mitigating Replay and Context-Binding Failures in AP2
- 2026When Agents Act on Web3: An Attack-Surface Survey of MCP, Skills, and Tool Calling
- 2025Towards Multi-Agent Economies: Enhancing the A2A Protocol with Ledger-Anchored Identities and x402 Micropayments for AI Agents