Workspace IndexKnowledge Notes › The budget is the wrong invariant

#4PoC

The budget is the wrong invariant

A spend cap constrains the amount, not the purchase. An agent that spends $50 of its $100 on the wrong thing passed every check — and on-chain there is no chargeback behind it.

Why a spend cap is the wrong thing to bound: an agent that spends $50 of its $100 on the wrong item passed every check, and on-chain there is no chargeback behind it. Designed as a hackathon entry (Google Cloud × Solana agentic commerce, 2026-08); the hostile-merchant case is the argument, not a step toward it.

Why

Autonomous payments are almost always secured with a spend cap, and the cap is the wrong invariant. An agent given $100 that spends $50 on the wrong item has violated nothing — the session key worked, the limit held, the signature verified. The failure that matters is not overspend but wrong spend inside the limit, and unlike a card payment there is no chargeback sitting behind it. So this card is a design for fixing the invariant rather than tightening the cap, written as if entering the Google Cloud × Solana agentic-commerce hackathon, where the stated theme (an agent that settles and signs without human approval inside a budget) all but guarantees that most entries demonstrate the happy path of exactly the mechanism this one argues is insufficient. The competition is not the point; the point is that the strongest form of this argument is a demo in which the audience watches a conventional agent pass every check and lose the money anyway.

How it works

Two mechanisms, and the second is the one that will draw fire. First: sign the intent, not the limit. Before the agent sees any merchant content, a commitment is issued to (item class, max unit price, max quantity, merchant allowlist, expiry), and the on-chain program checks settlement against that commitment rather than against a balance — so an agent whose context is poisoned after the commitment was made cannot settle a purchase that does not match what it committed to wanting. That is AP2's Intent Mandate / Cart Mandate split moved onto Solana; the AP2 card already builds the same separation, so the new part is enforcement at settlement rather than the mandate concept. Second: a veto window on settlement. Between authorization and final settlement sits a short interval — 30 to 60 seconds — in which a separate low-privilege watcher key can cancel, with the privileges deliberately disjoint: the agent cannot cancel its own payments and the watcher cannot spend. This is the the-settlement-instant card's claim about liquidations — an action that fires with zero delay removes the only interval in which a bad input could have been noticed — applied to payments instead of oracles. The demo runs the same agent twice against a merchant API carrying a prompt injection: on a plain session key the limit holds, the purchase is wrong and the money is gone; on these rails settlement fails on the intent mismatch rather than on the amount. Two questions get asked of every entry, so answer them in the design. Sub-second finality is what makes a 30-second veto window a product decision rather than an artifact of block time — on a slower chain that window is indistinguishable from ordinary confirmation latency, and the product does not exist. And the commitment issuer and the watcher have to live somewhere the agent cannot reach, which makes them a policy service with an audit log rather than anything on-chain: enforce on-chain, decide off-chain, the same split the CRE × Cloud card arrives at from the other direction. The objection to answer first, because a payments audience raises it immediately, is that no merchant wants to wait 30 seconds for finality — and the answer is that card networks already made this trade and gave it a name. Authorization is instant, capture is later. This is auth-and-capture rebuilt for agents rather than a new tradeoff, which is also where the rwa-multichain card lands coming the other way: authorize against a limit now, reconcile after. Scope if built: one Solana program (commitment check, timelocked settlement, watcher cancel), a deliberately hostile merchant API, and a Cloud Run policy service. No wallet UI, no multichain, no token — nothing that does not appear in the demo.

Where it lands in Jayverse

  • Rabbit: enforce intent mandates, not just spend caps, on session keys. A 7715 session key that only bounds an amount lets an agent pass every check while buying the wrong thing; Rabbit's mandate design should commit to (item/action class, max price, counterparty allowlist, expiry) and check settlement against that commitment.
  • Rabbit: add a low-privilege veto window between authorization and settlement. A separate watcher key that can cancel but not spend, given a short window before finality, is a concrete addition to Rabbit's mandate flow that catches a wrong-target action a spend cap alone would miss.
  • Verex: apply the same two-mechanism split to withdrawal or settlement automation. Any automated flow (agent-triggered settlement, auto-withdraw) should be checked against a signed intent rather than a balance limit, with enforcement on-chain and the policy decision off-chain.

Key expressions

Words and phrases from this page worth keeping, with the Korean meaning and the sentence they come from.

Expression뜻 · 쓰이는 자리
spend cap지출 한도 · 금액만 제한할 뿐 무엇을 사는지는 못 막는 장치. "a spend cap is the wrong invariant"
chargeback지불 취소, 카드사가 대금을 되돌려주는 절차 · 온체인에는 이게 없다는 대조점. "on-chain there is no chargeback behind it"
veto window거부권 행사 구간 · 정산 전 잠깐 취소할 수 있는 시간. "a veto window on settlement"
draw fire비판을 받다, 공격의 대상이 되다 · 논쟁적인 설계 선택을 가리킬 때. "the second is the one that will draw fire"
disjoint겹치지 않는, 서로 분리된 · 권한을 일부러 나눠 한쪽이 남용 못 하게 할 때. "the privileges deliberately disjoint"
auth-and-capture승인-매입 분리 방식 · 카드결제처럼 먼저 승인하고 나중에 확정 처리하는 구조. "auth-and-capture rebuilt for agents"
reconcile after나중에 대조·정산하다 · 일단 한도 내에서 승인하고 사후에 맞춰볼 때. "authorize against a limit now, reconcile after"
all but guarantee사실상 보장하다 · 거의 확실하게 그렇게 될 것이라고 말할 때. "all but guarantees that most entries demonstrate"
poisoned (context)(입력이) 오염되다, 조작되다 · 악성 데이터가 에이전트의 판단을 흐릴 때. "an agent whose context is poisoned"
happy path정상 흐름, 문제 없는 이상적 시나리오 · 대부분의 참가작이 보여줄 뻔한 흐름. "the happy path of exactly the mechanism"
AP2에이전트 결제 프로토콜(Agent Payments Protocol) · 구글의 Intent Mandate/Cart Mandate 구조, 이 카드가 솔라나로 옮겨온 개념. "That is AP2's Intent Mandate / Cart Mandate split"
CRE체인링크 런타임 환경(Chainlink Runtime Environment) · 온체인 집행·오프체인 결정 분리 패턴을 다루는 다른 카드. "the same split the CRE × Cloud card arrives"
Cloud Run구글 클라우드의 서버리스 실행 서비스(Google Cloud Run) · 에이전트가 접근할 수 없는 곳에서 정책 서비스를 돌리는 위치. "a Cloud Run policy service"

← All Knowledge Notes · Workspace Index · Top ↑

한도는 틀린 불변식이다

한도는 금액을 제약하지 구매를 제약하지 않습니다. $100 중 $50을 엉뚱한 것에 쓴 에이전트는 모든 검사를 통과한 것이고, 온체인에는 그 뒤를 받칠 차지백이 없습니다.

왜 한도가 묶어야 할 대상이 아닌가 — 100달러 중 50달러를 엉뚱한 것에 쓴 에이전트는 모든 검사를 통과했고, 온체인에는 그 뒤를 받쳐 줄 지급거절이 없습니다. 해커톤 출품작을 가정해 설계했고(Google Cloud × Solana 에이전틱 커머스, 2026-08), 적대적 판매자 사례는 논증으로 가는 단계가 아니라 논증 그 자체입니다.

자율 결제는 거의 항상 지출 한도로 보호되는데, 한도는 틀린 불변식입니다. $100을 받은 에이전트가 엉뚱한 물건에 $50을 썼다면 위반한 것이 하나도 없습니다 — 세션키는 동작했고, 한도는 지켜졌고, 서명은 검증됐습니다. 중요한 실패는 초과지출이 아니라 한도 안에서의 잘못된 지출이고, 카드 결제와 달리 그 뒤에는 차지백이 없습니다. 그래서 이 카드는 한도를 더 조이는 대신 불변식을 갈아 끼우는 설계이고, Google Cloud × Solana 에이전틱 커머스 해커톤에 출품한다는 가정으로 썼습니다. 그 대회의 주제(예산 안에서 사람 승인 없이 정산·서명하는 에이전트) 자체가, 대부분의 출품작이 바로 이 카드가 불충분하다고 주장하는 메커니즘의 해피패스를 시연하게 만들기 때문입니다. 대회가 요점은 아닙니다. 요점은 이 논증의 가장 강한 형태가 관객이 평범한 에이전트가 모든 검사를 통과하고도 돈을 잃는 것을 지켜보는 데모라는 것입니다.

동작 방식

메커니즘은 둘이고, 공격을 받을 쪽은 두 번째입니다. 첫째, 한도가 아니라 의도에 서명합니다. 에이전트가 판매자 콘텐츠를 보기 전에 (품목 클래스, 최대 단가, 최대 수량, 판매자 allowlist, 만료) 커밋을 발행하고, 온체인 프로그램은 정산을 잔고가 아니라 그 커밋과 대조합니다 — 커밋 이후에 컨텍스트가 오염된 에이전트는 자기가 원한다고 커밋한 것과 다른 구매를 정산할 수 없습니다. 이것은 AP2의 Intent Mandate / Cart Mandate 분리를 솔라나로 옮긴 것입니다. AP2 카드가 이미 같은 분리를 만들고 있으므로 새로운 부분은 만다트 개념이 아니라 정산 시점의 강제입니다. 둘째, 정산에 거부권 창을 둡니다. 승인과 최종 정산 사이에 30~60초의 짧은 구간을 두고 그 안에서 별도의 저권한 감시 키가 취소할 수 있게 하되, 권한을 의도적으로 서로소로 나눕니다 — 에이전트는 자기 결제를 취소하지 못하고, 감시자는 지출하지 못합니다. 이것은 the-settlement-instant 카드가 청산에 대해 한 주장(지연 0으로 발사되는 동작은 잘못된 입력을 알아챌 수 있었던 유일한 구간을 없앤다)을 오라클이 아니라 결제에 적용한 것입니다. 데모는 프롬프트 인젝션이 실린 판매자 API에 대고 같은 에이전트를 두 번 돌립니다: 평범한 세션키에서는 한도가 지켜지고 구매는 틀렸고 돈은 사라지며, 이 레일 위에서는 금액이 아니라 의도 불일치로 정산이 실패합니다. 모든 출품작이 받는 질문 둘은 설계 안에서 답해 둡니다. 서브초 파이널리티가 30초 거부권 창을 블록타임의 부산물이 아니라 제품 결정으로 만듭니다 — 느린 체인에서는 그 창이 평범한 확정 지연과 구분되지 않고, 그러면 제품이 성립하지 않습니다. 그리고 커밋 발행자와 감시자는 에이전트가 닿을 수 없는 곳에 있어야 하므로 온체인이 아니라 감사 로그를 가진 정책 서비스가 됩니다 — 강제는 온체인, 판단은 오프체인. CRE × Cloud 카드가 반대 방향에서 도달한 그 분리입니다. 결제 쪽 청중이 즉시 제기하므로 먼저 답해야 할 반론은 "어느 판매자가 파이널리티를 30초 기다리느냐"이고, 답은 카드망이 이미 이 거래를 했고 이름까지 붙여 두었다는 것입니다. 승인은 즉시, 매입은 나중. 이것은 새로운 트레이드오프가 아니라 auth/capture를 에이전트용으로 다시 만든 것이고, rwa-multichain 카드가 반대편에서 도달한 지점이기도 합니다(지금 한도에 대해 승인하고 나중에 대사). 만든다면 범위는: 솔라나 프로그램 하나(커밋 대조 + 타임락 정산 + 감시자 취소), 의도적으로 적대적인 판매자 API, Cloud Run 정책 서비스. 지갑 UI도, 멀티체인도, 토큰도 없습니다 — 데모에 나오지 않는 것은 전부 만들지 않습니다.

Jayverse에서의 위치

  • Rabbit: 세션 키에 지출 한도가 아니라 의도 위임(intent mandate)을 강제한다. 금액만 제한하는 7715 세션 키는 에이전트가 엉뚱한 것을 사도 모든 검사를 통과하게 둔다. Rabbit의 위임 설계는 (항목/행동 분류, 최대 가격, 상대방 허용목록, 만료)를 커밋하고 정산을 그 커밋과 대조해야 한다.
  • Rabbit: 승인과 정산 사이에 낮은 권한의 거부 윈도우를 둔다. 지출은 못 하지만 취소는 할 수 있는 별도의 워처 키를, 파이널리티 전 짧은 윈도우와 함께 Rabbit의 위임 흐름에 추가하면 지출 한도만으로는 못 잡는 잘못된 대상 행동을 잡아낸다.
  • Verex: 정산이나 출금 자동화에 같은 이원 메커니즘을 적용한다. 자동화된 흐름(에이전트가 트리거하는 정산, 자동 출금)은 잔액 한도가 아니라 서명된 의도와 대조해 검사하고, 온체인에서는 집행, 오프체인에서는 정책 결정으로 나눈다.

핵심 표현

이 페이지의 영어 본문에서 배울 만한 단어와 표현, 뜻과 나온 자리.

Expression뜻 · 쓰이는 자리
spend cap지출 한도 · 금액만 제한할 뿐 무엇을 사는지는 못 막는 장치. "a spend cap is the wrong invariant"
chargeback지불 취소, 카드사가 대금을 되돌려주는 절차 · 온체인에는 이게 없다는 대조점. "on-chain there is no chargeback behind it"
veto window거부권 행사 구간 · 정산 전 잠깐 취소할 수 있는 시간. "a veto window on settlement"
draw fire비판을 받다, 공격의 대상이 되다 · 논쟁적인 설계 선택을 가리킬 때. "the second is the one that will draw fire"
disjoint겹치지 않는, 서로 분리된 · 권한을 일부러 나눠 한쪽이 남용 못 하게 할 때. "the privileges deliberately disjoint"
auth-and-capture승인-매입 분리 방식 · 카드결제처럼 먼저 승인하고 나중에 확정 처리하는 구조. "auth-and-capture rebuilt for agents"
reconcile after나중에 대조·정산하다 · 일단 한도 내에서 승인하고 사후에 맞춰볼 때. "authorize against a limit now, reconcile after"
all but guarantee사실상 보장하다 · 거의 확실하게 그렇게 될 것이라고 말할 때. "all but guarantees that most entries demonstrate"
poisoned (context)(입력이) 오염되다, 조작되다 · 악성 데이터가 에이전트의 판단을 흐릴 때. "an agent whose context is poisoned"
happy path정상 흐름, 문제 없는 이상적 시나리오 · 대부분의 참가작이 보여줄 뻔한 흐름. "the happy path of exactly the mechanism"
AP2에이전트 결제 프로토콜(Agent Payments Protocol) · 구글의 Intent Mandate/Cart Mandate 구조, 이 카드가 솔라나로 옮겨온 개념. "That is AP2's Intent Mandate / Cart Mandate split"
CRE체인링크 런타임 환경(Chainlink Runtime Environment) · 온체인 집행·오프체인 결정 분리 패턴을 다루는 다른 카드. "the same split the CRE × Cloud card arrives"
Cloud Run구글 클라우드의 서버리스 실행 서비스(Google Cloud Run) · 에이전트가 접근할 수 없는 곳에서 정책 서비스를 돌리는 위치. "a Cloud Run policy service"

← 전체 기술 노트 · 워크스페이스 인덱스 · 맨 위 ↑