Three Critical Flaws, Fixed in August, Disclosed in October

Security firm V12 disclosed on October 22 that the x402 SDKs contain three critical vulnerabilities, one of which could let a malicious API make an AI agent sign a payment for the entire balance of a supported token.
- Disclosure: V12, October 22, 2026
- Scope: 25 bugs found in x402 code, three rated critical
- Affected: agents that sign payments automatically and whose apps set no payment policy
- Fixed in: releases dated August 18, 2026
- Latest versions as of October 23: 2.28.0 for @x402/core, @x402/svm, @x402/extensions, @x402/fetch and @x402/axios; Go module v2.28.0; Python package 2.25.0
- Advisory: none published; changelogs list the fixes without calling them security fixes
- Exploitation: neither V12 nor the foundation has publicly reported attacks
x402 is an open standard Coinbase created and handed to the x402 Foundation this year, a Linux Foundation project whose members include Visa and Mastercard; Coinbase holds the most senior seat on its technical steering committee. It lets software, including AI agents, pay for an API call inside the web request without a person approving each payment: a server answers with HTTP 402 Payment Required and lists payment options with amount, token and recipient, and the client picks one, signs, and resends.
What the Three Flaws Do
The first flaw sits in the default client, which took the first option on the list and, before the fix, set no limit on the amount. A hostile API could use an earlier small payment to learn the wallet address and look up its balance, then turn a routine data request into a demand for the full balance; with an automatic signer and no app-level policy the client would sign it, and for tokens that support signed transfers the attacker could submit the payment and collect. The August 18 releases added spend controls to the TypeScript, Python and Go clients, capping each payment at $1 by default and allowing only recognized dollar stablecoins such as USDC.
The second flaw is confined to the TypeScript SDK’s Solana support. The facilitator — the service that checks payments, submits them on-chain and pays the Solana transaction fee — confirmed the payment called an allowed token program, then read it as a transfer without checking the instruction type. A token approval, which lets another account spend tokens later but moves none itself, differs from a transfer only in its first byte. In V12’s local test the facilitator accepted such an approval as a valid payment; no live transaction was sent. A merchant would deliver the paid resource and receive nothing, which V12 called a complete payment bypass. The attacker needed a token account but no balance, and the facilitator paid the fee each time. Every published @x402/svm release from 2.0.0 to 2.22.0 lacks the check; 2.23.0 and later have it.
The third flaw is in the SIWx (Sign-In-With-X) extension, which lets an agent log in by signing a short message with its wallet, for example to prove an earlier payment instead of paying again. On Ethereum the message names the website, the wallet address and a one-time code, but the automated client signed without verifying that the named site was the one it had contacted. A malicious server could fetch a fresh login message from another site, pass it to the agent, and use the signature to log in to that site as the agent’s wallet, gaining whatever access the login allowed.
Two Months of Silence From Advisories and Scanners
All three were fixed on August 18, but only became public with V12’s October 22 disclosure. The foundation has published no security advisory, and its changelogs list the fixes without labelling them as security fixes. As of October 23, npm audit returned no advisories for the last TypeScript releases before the fixes, and PyPI listed no vulnerabilities for the last Python release before them — so developers who rely on those checks got no signal to upgrade.
| Item | Before the fix | August 18 and later |
|---|---|---|
| Default per-payment cap | None | $1 |
| Default allowed tokens | Unrestricted | Recognized dollar stablecoins (e.g. USDC) |
| Solana instruction-type check (TypeScript) | Missing (@x402/svm 2.0.0–2.22.0) | Added (2.23.0+) |
| SIWx site validation | None | Refuses to sign on mismatch |
| Advisory / scanner alert | None | Still none |
Who Should Upgrade Now
Apps whose agents pay through x402 should move to @x402/fetch or @x402/axios 2.23.0 or later, which pull in the matching @x402/core; those using SIWx also need @x402/extensions 2.23.0+, and facilitators checking Solana payments need @x402/svm 2.23.0+. Going straight to 2.28.0 also brings a September fix for a separate payment bypass in @x402/core 2.27.0.
Teams that cannot upgrade yet can register a payment policy that drops options above a set amount — registerPolicy in TypeScript and Go, register_policy in Python, which ships a ready-made max_amount policy. After upgrading, clients cap each payment at $1 and restrict tokens to recognized stablecoins unless the app sets its own controls; passing spendControls: false turns all of them off. V12 also advises checking that a SIWx login message names the site being contacted, setting per-payment and total budgets, and limiting tokens, networks and recipients.
Final Word
Three critical flaws were quietly patched two months before anyone outside the project knew they existed, and the absence of an advisory is what kept automated scanners silent. For teams letting agents spend money on their own, a default cap and an explicit payment policy are not optional features — they are the last mechanical switch on the wallet.
