spec: add shielded EVM payments for exact scheme (privacy pools)#1951
Open
mmchougule wants to merge 2 commits intox402-foundation:mainfrom
Open
spec: add shielded EVM payments for exact scheme (privacy pools)#1951mmchougule wants to merge 2 commits intox402-foundation:mainfrom
mmchougule wants to merge 2 commits intox402-foundation:mainfrom
Conversation
Adds `specs/schemes/exact/scheme_exact_evm_shielded.md` — the specification for a new `assetTransferMethod: "shielded"` under the existing `exact` scheme on EVM chains. This enables privacy-preserving x402 payments where the payer's identity is hidden behind a ZK proof verified by an on-chain privacy pool (e.g., Railgun). The facilitator verifies payments by inspecting the standard ERC-20 Transfer event emitted during unshield — no viewing keys or trial decryption required. Key properties: - Settlement: Client-driven (unshield on-chain before verification) - Verification: ERC-20 Transfer event from registered pool contract - Privacy: Sender hidden via ZK proof; amount visible to facilitator - Token: Any ERC-20 supported by the privacy pool (USDC, USDT, DAI) - Gas: Client pays, or gasless via ERC-4337 This is designed to be general — works with any privacy pool that emits standard ERC-20 Transfer events, not tied to a specific implementation. Relates to x402-foundation#1633
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
specs/schemes/exact/scheme_exact_evm_shielded.md— a newassetTransferMethod: "shielded"for theexactscheme on EVM chains.Enables privacy-preserving x402 payments where the payer's wallet address is hidden behind a ZK proof verified on-chain by the privacy pool contract. The facilitator confirms the resulting ERC-20 Transfer event matches the payment requirements.
How it works
On-chain (privacy pool contract handles):
Facilitator verification:
txHashinPAYMENT-SIGNATUREheaderfromis registered pool contract,tomatchespayTo,value>= requiredDesign decisions
exactscheme as a newassetTransferMethod— same payment semantics as EIP-3009/Permit2/ERC-7710, different transfer mechanismCloses #1953