Introduction

Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.

I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.

I also build and publish a variety of tools, libraries, and open-source projects.

Private transfers in v1

Consider a sender paying 100 zUSDC and a recipient receiving it at their own address. In an ordinary ERC20 transfer, the sender specifies that recipient directly, allowing anyone to inspect the public history and determine who sent how much to whom. zERC20 v1 separates transfers to one-time destinations from proof-based redemption, avoiding a direct onchain record of the link between the sender and the final recipient.

The sender uses the ordinary transfer function from a wallet. However, the destination is a burn address derived from secret information rather than the final recipient's address. The recipient uses that information to prove a payment exists in the transfer history and redeems it through the Verifier contract.

The original figures in this article retain their Japanese labels.

Overview of v1 separating ordinary transfers from proof-based redemption

The information that is primarily concealed is the link between the two addresses. The 100 zUSDC transfer amount and timestamp remain public. If a redemption of the same amount occurs around the same time, observers can still infer a possible connection.

New wraps and private transfers in v1 were discontinued on November 4, 2026. Withdrawals from the old version are advertised as available until April 30, 2027. Understanding this redemption-based design also helps explain what changed in v2's private balance update mechanism.

One-time destinations

A burn address is computed from the final receiving address and secret information. It is not generated through the ordinary account derivation process of deriving a public key and address from a private key. Instead of signing a transaction with the burn address's private key, the recipient proves knowledge of the information from which that address is derived.

An ERC20 contract records balances keyed by address. A balance can be credited to an address even if nobody knows a corresponding private key. v1 uses this property to separate the public transfer destination from the final recipient bound to the proof.

Deriving a burn address from the final receiving address and secret information

Even when the recipient later redeems the payment, there is no ordinary transfer of funds from that address. After the Verifier contract checks the proof, the authorized issuance operation issues z-tokens to the final receiving address. A burn address is therefore not a relay account that forwards funds.

The recipient value and secret information

The value bound to the final receiving address is constructed in two stages. First, combine the destination chain identifier, address, and a per-transfer adjustment value. The result is recipient, which fixes the redemption destination in the proof.

python
recipient = Poseidon3(chain_id, withdrawal_address, tweak)
burn_hash = Poseidon3(field_encode("burn"), recipient, secret)
burn_address = truncate_160(burn_hash)

Poseidon is a hash function designed to be efficient to compute inside zero-knowledge proof circuits. The inputs serve the following purposes.

Value Role
withdrawal_address Final receiving address
tweak Adjustment value that changes the computation for each transfer
secret Secret number used in the redemption proof

The recipient line binds the destination chain and address to the adjustment value. The burn_hash line hashes that result with the secret number, separating this computation from other uses. The last line extracts the 160 bits used for the address. The field_encode("burn") value distinguishes this hash computation from hashes for other purposes.

Even if 100 zUSDC is sent twice to the same recipient, different values of tweak and secret allow distinct burn addresses to be created. Because the proof reproduces the same computation, simply knowing the final receiving address is insufficient for redemption. The per-transfer secret information and actual transfer history are required.

The 16-bit search condition

In v1, besides using 160 bits of the hash as the address, the next 16 bits must be zero. This corresponds to the bit range [160,176). The client varies candidate values of secret and tweak until it finds a combination satisfying the condition.

This is proof of work (PoW): a repeated search for values satisfying a given condition. Unlike mining for block production, its purpose is to satisfy the burn address generation condition. The official proof specification also checks this condition inside the redemption circuit.

Storing and discovering encrypted announcements

If a transfer event does not contain the final recipient's address, the recipient cannot find the payment by searching events for their own address. The sender's client therefore encrypts the information needed to construct the proof and stores it as a notification for the recipient. This notification is called an announcement.

ICP, or Internet Computer Protocol, is the execution platform used to store announcements. A Storage Canister on ICP stores encrypted notifications, and a separate Key Manager Canister handles decryption key retrieval. Token transfers and proof verification occur on the EVM side; funds are not deposited into the announcement storage system.

Key retrieval, paginated discovery, local decryption, and transfer reconciliation

The recipient's client proceeds through authorization, key retrieval, candidate retrieval, decryption, and transfer matching. Retrieving an announcement does not complete redemption. The client must match the decrypted information to an actual transfer and proceed to proof verification.

Two stages of announcement encryption

The plaintext announcement data is called StealthPayload. It contains the information necessary to reproduce the redemption computation.

Information in the announcement Purpose for the recipient
Destination chain Identify the chain on which to redeem
Final receiving address Identify the issuance destination
tweak Reproduce the per-transfer computation
secret Derive the destination and construct the redemption proof
burn_address Look up the actual transfer

The recipient uses these values to reproduce the destination computation and construct a proof.

The client generates a random AES key and encrypts the StealthPayload using AES-256-GCM. It then encrypts that AES key using identity-based encryption (IBE) corresponding to the recipient's address. IBE allows ciphertext to be decrypted using a key corresponding to the recipient's identity.

The stored announcement contains both the encrypted payload and encrypted AES key. The recipient uses a view key to recover the AES key, then uses that key to decrypt the payload. Decryption occurs on the recipient's device; the Storage Canister holds ciphertext.

Encrypting the payload does not necessarily conceal when the announcement was stored or how it is looked up. The announcement.recipient field is the recipient address used for discovery. This lookup address is distinct from the hash that fixes the redemption destination in the proof.

Signatures and recipient-generated payment requests

The recipient signs a key retrieval message using their EVM address. A key retrieval request containing this signature uses the following information to protect authorization and key delivery.

Request information Role
EVM signature Demonstrate that the requester controls the recipient address
nonce Limit reuse of the same authorization
TTL Specify the authorization validity period
transport key Protect the returned key for the recipient's device

The Key Manager Canister returns an encrypted view key, which the recipient's device decrypts with the corresponding key.

The client then specifies the recipient address and page when requesting candidate announcements from the Storage Canister. For each candidate, it decrypts the AES key and payload in turn and queries the Indexer, the service used to search transfer history, for the recovered burn address. Only candidates matching actual transfers become inputs to the redemption proof.

The key retrieval signature is separate from a signature authorizing a token transfer transaction. The sender's SDK also provides a deriveSeed function that derives a stable seed from a signature for deriving per-payment secret information. The secret numbers derived from that signature are used to compute addresses.

Another option is for the recipient to prepare signed payment request information in advance and give the burn address to the payer. With recipient-generated addresses, payment can be requested without revealing the final receiving address to the payer. When the sender generates the address, however, the sender knows the final recipient even if it is not disclosed to onchain observers.

Transfer history and redemption proofs

Recovering a secret from an announcement does not establish that the advertised 100 zUSDC was actually sent. The recipient must therefore prove both knowledge of the secret information and inclusion of the corresponding transfer in a verified history. Redemption is permitted only when both conditions are met.

A zero-knowledge proof lets the recipient reveal the public values needed for verification while keeping the computation's private inputs hidden. The recipient does not have to reveal the secret itself or disclose directly which transfer was selected. However, the history root referenced by the proof must be tied to the correct transfer history.

Knowledge of secret information and inclusion in finalized history as redemption conditions

Transfer recording, history finalization, and redemption proof verification are separate operations. A transfer visible in the Indexer is also distinct from history that is verifiable in the Verifier contract. This distinction helps identify whether redemption is waiting because of a missing announcement, incomplete synchronization, or an unfinalized root.

Finalizing transfer history

For each transfer, the zERC20 contract emits an IndexedTransfer event in addition to the standard Transfer event. IndexedTransfer records the transfer order and contents.

Event value Contents
index Transfer sequence number
from Sender address
to Destination burn address
value Transfer amount

Event logs provide the source data synchronized by the Indexer and are recorded separately from balances and cumulative values held in the contract.

At the same time, the contract updates hashChain using the previous cumulative value and the current transfer. The Indexer consumes the same events in the same order and constructs a Transfer Merkle Tree whose leaves represent transfers. This Merkle tree commits the transfer history to a single root hash.

Committing the same transfer sequence to a SHA256 cumulative value and a Poseidon Merkle tree

The two computations are separated so that updating the Merkle tree can occur offchain rather than updating the entire tree in the contract for every transfer. In return, Verifier.proveTransferRoot verifies a proof that the Merkle tree was constructed from the history corresponding to the cumulative value. Verification of this proof is required before the root is accepted.

Inclusion paths and storage locations

The leaf corresponding to a 100 zUSDC transfer is constructed from the transfer contents in the preceding table, excluding its sequence number. The recipient obtains the leaf position and the sibling nodes needed to compute the root from the Indexer. This sequence of sibling nodes is the Merkle path used to establish inclusion in the Merkle tree.

At each level, the order of hash inputs depends on whether the target node is on the left or right. If it is on the left, compute Hash(target, sibling); if it is on the right, compute Hash(sibling, target). The redemption proof checks that repeating this computation to the top yields the verified root.

Data Where it is recorded or held Use in redemption
IndexedTransfer EVM event logs Actual transfer history
Merkle tree and inclusion paths Indexer Inputs to proof construction
hashChain zERC20 contract Cumulative value of the ordered history
Verified root Verifier contract History a proof may reference

The contract receives the proof and public inputs, so the recipient does not submit the entire Merkle tree. The client constructing the proof, however, needs the target leaf and its path.

Updating hashChain and the root

The contract concatenates the previous cumulative value with the current transfer and updates the value using SHA-256. The official specification truncates the result to 248 bits. In the pseudocode, concat concatenates the inputs and take248 extracts 248 bits.

javascript
hashChain_new = take248(SHA256(concat(hashChain_old, from, to, value)))

The inputs correspond to the transfer event as follows.

Input Value used
hashChain_old Previous cumulative value
from Sender of the current transfer
to Destination of the current transfer
value Current transfer amount

Because the previous cumulative value is included, ordering the same transfers differently changes the resulting value. The root update proof connects this ordered history with updates to the Poseidon-based Merkle tree.

Repeated updates use Nova to prove multiple computation steps together. Each step checks that the correct leaf is added to an empty position and that the transfer is incorporated into the cumulative value. An offchain Decider Prover finalizes the folded proof in a form verifiable by the contract.

Redemption and amounts already issued

The recipient constructs a proof from the decrypted secret information and the transfer inclusion path obtained from the Indexer. Single redemptions have a Groth16 path, while aggregated redemptions have a Nova path. These proofs are submitted to Verifier.singleTeleport and Verifier.teleport, respectively.

Even a valid proof must not allow the same transfer to be used for issuance repeatedly. The Verifier contract therefore records the cumulative amount issued for the recipient information in totalTeleported. It compares the redeemable amount established by the proof with the amount already issued to prevent overlapping redemptions.

Comparing redeemable and already-issued amounts to prevent duplicate issuance

For example, once redemption backed by a 100 zUSDC transfer has completed, presenting another proof backed by that same transfer cannot issue an additional 100 zUSDC. v1 tracks the amount already issued against the recipient information. This differs from v2's approach of attaching spent tags to individual records.

Ordinary transfers and teleport

The proof's public inputs fix the referenced history and redemption conditions.

Public value Role in verification
History root Identify verified history containing the transfer
recipient Bind the redemption destination in the proof
Redeemable amount Specify the amount eligible for issuance

The secret and information corresponding to the selected transfer are private proof inputs. The Verifier contract validates the public inputs and proof. If the conditions are met, it issues tokens to the final receiving address through zERC20.teleport.

Even after this issuance, the transferred balance remains at the burn address. The announcement delivers the secret needed for redemption, the transfer history provides the backing for issuance, and cumulative issuance accounting prevents repeated redemption. Checking these separately prevents issuance based on fabricated announcements or repeated use of the same history.

When supporting services stop

If the Indexer has not synchronized, the transfer or inclusion path may be unavailable even if the announcement has arrived. Even after inclusion in the Merkle tree, the redemption proof lacks a usable reference if the root proof covering that range has not been finalized. Aggregated redemption may also wait for finalization by the Decider Prover.

The path for constructing a single proof locally differs from the one in which a server finalizes the proof. Track announcement decryption, history confirmation, proof construction, and transaction execution as separate stages.

Sharing roots across chains and exchanging underlying assets

v1 also supports proving and redeeming z-tokens on a different chain from the original transfer. Roots are relayed and shared so that the destination Verifier contract can reference the source chain's history. Returning to the underlying asset adds a separate condition: liquidity on the receiving side.

Root relaying transports information needed to verify history. Issuing z-tokens on the redemption side and exchanging them for underlying assets are separate operations performed by their respective contracts. This distinction explains the existence of separate Hub and LiquidityManager contracts.

Separate paths for relaying history and exchanging the underlying asset on the receiving side

Local and shared roots

For same-chain redemption, the Verifier contract can reference a transfer root verified on that chain. For cross-chain redemption, the root is first finalized in the source chain's Verifier contract. An offchain Cross-chain Job then calls relayTransferRoot and sends the root to the Hub contract through LayerZero.

The Hub contract aggregates roots from multiple chains to construct a shared global root. When the Cross-chain Job calls Hub.broadcast, the aggregated result is distributed to destination Verifier contracts. The recipient proves inclusion of the transfer on the other chain against this shared root.

Aggregating roots in the Hub and distributing them to destination chains

The Hub is an onchain aggregation contract, distinct from the Cross-chain Job that submits calls. If root relaying, aggregation, or distribution is delayed, the history may be visible on the source chain but not yet referenceable on the destination. Cross-chain redemption therefore has an additional stage in which arrival of the shared root must be confirmed.

Underlying asset exchange and gas

The LiquidityManager contract exchanges z-tokens for their underlying assets. The wrap function deposits underlying assets and returns z-tokens; the unwrap function burns z-tokens and returns underlying assets. This exchange is distinct from issuing z-tokens to a redemption destination using a proof.

v1's exchange mechanism uses fees and rewards based on liquidity targets. If the underlying asset balance is below target, it incentivizes deposits and charges fees on withdrawals. An offchain Fee Manager computes targets from balances on each chain and updates parameters using its assigned authority. The cost of returning to the underlying asset depends on the exchange chain's liquidity and fee settings.

Separating proof-based issuance, underlying asset exchange, and gas-token swaps

The Adaptor contract's exit path, which uses liquidity on another chain, can also be configured to use Stargate. Whereas teleport issues z-tokens based on a shared root, this path obtains underlying assets from liquidity on another chain.

For recipients without gas assets, there is a path using transaction submission on their behalf by a Relay Node. Get Gas, by contrast, swaps z-tokens for native tokens through the SwapHelper contract. Relaying a redemption transaction and obtaining gas assets for later use are different operations.

Public information and the end of v1

Observers can identify transfer addresses and amounts from public history.

Public information What can be observed
Sender Address that sent the tokens
burn address Public transfer destination
Amount Token amount of the transfer
Time When the transfer was recorded

Even if the final receiving address is absent from the transfer event, distinctive amounts or redemptions close in time can provide clues about the connection. When the sender generates the burn address, the sender also knows the final recipient.

Different visibility of transfer relationships for onchain observers, senders, and recipients

Querying an external Indexer for a burn address can provide a clue linking the lookup target to the recipient's access. Running one's own Indexer reduces information disclosed to that query service. Public amounts and timestamps remain observable even with a self-hosted search service.

Contract administration and encrypted announcement key management also involve trust assumptions. The Contract Owner can change contract implementations or verification destinations; the Blocklist Owner can add or remove addresses restricted from transferring or receiving issuance. ICP key derivation relies on threshold keys involving multiple nodes in a subnet and should not be described as unconditional privacy from the storage infrastructure.

Ordinary token operations check the relevant addresses using an onchain Blocklist contract. Separately, an offchain verification called Proof of Innocence demonstrates that the originating address of a received transfer is not on a specified sanctions list. It uses Nova to prove both transfer inclusion and list non-inclusion and is checked through a CLI (command-line interface). It is separate from the mandatory inputs of ordinary teleport.

Demonstrating absence from a list does not prove the complete prior history or legality of the funds. Separating information concealed from observers, information supplied to services, and conditions that administrators can change makes the design's trust assumptions clear.

According to the official migration notice, withdrawals from the old version remain available until April 30, 2027. Because v1 and v2 operate through different contracts, balances are not carried over automatically. Users withdraw from v1 to their own wallets, check supported networks and assets, and deposit again into v2.

Conclusion

zERC20 v1 combined ordinary token transfers, encrypted announcements, and history inclusion proofs to support redemption without directly publishing the link between a sender and the final recipient. Announcement discovery, root finalization, proof verification, and accounting for already-issued amounts serve distinct roles. Cross-chain redemption adds root sharing and liquidity requirements. The current v2 replaces this redemption-based approach with a mechanism that updates records of private balances.

The legacy official documentation describes the old mechanism and its components.

The official migration notice describes the shutdown and migration path.