Buy contract (BuyForwarderFactory)
BuyForwarderFactory bridges the USDC of a card purchase from the buyer’s own
wallet into the kUSDT vault on Ethereum, for the buyer’s Kaspa key. It has no owner, no
admin and no upgrade: once deployed, nobody can change it. Source: bridge/buy/contracts/src/ in the repository.
| Address (Ethereum) | 0x9d9D5d596d9157b00317FCa7faCcb885DD3fAa60 |
| Deployed | 26 November 2026, transaction 0x0758e4d8… |
| Source match | Sourcify, exact; creation bytecode keccak 0x88adf2b79fb2d69efc9b771f343b80b08d67911556b92950634e3bd26aae0bcb |
usdc |
0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 (USDC) |
usdt |
0xdAC17F958D2ee523a2206206994597C13D831ec7 (USDT) |
router, poolFee |
0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45 (Uniswap SwapRouter02), 100 (the 0.01% USDC/USDT pool) |
vault |
0xfa9869982542FB20baD929789B252b7b06EeE10e |
feeTo |
0xc1f8944a5136BBd7168634FBa9b5DBB07DA9187d (Trestly’s gas wallet) |
MAX_SLIPPAGE_BPS |
10 (the swap gives at least 99.9% of one for one) |
How it works
Section titled “How it works”Each buyer’s deposit address is a small BuyForwarder at a CREATE2 address made from the buyer’s Kaspa key, the
largest network fee and the largest bridge fee they accept (forwarderOf(ownerScheme, owner, maxFee, maxDepositFee)).
Only the factory can move tokens through it.
forwardFrom(buyer, amount, deadline, v, r, s, ownerScheme, owner, maxFee, maxDepositFee, fee, minMinted):
- USDC checks the buyer’s permit for
amountto that deposit address, here and now (signature, nonce, deadline). Nothing else moves the buyer’s USDC: an approval left by a permit sent some other way is never used. - A network fee of at most
maxFee, and only when the gas wallet (feeTo) sends, goes tofeeTo. A copy of the buyer’s permit sent by anyone else bridges with no fee. - Exactly
amount − feeUSDC is swapped to USDT and exactly that swap’s output is deposited into the vault for the buyer’s key (depositAtLeast), with a deposit fee of at mostmaxDepositFeeand at leastminMintedkUSDT minted. If any step fails, the whole call reverts and the USDC stays in the buyer’s wallet.
returnRefund(nonce): if the vault refunds a deposit made this way (it pays the deposit’s sender, the deposit
address), this sends the refund on to the buyer’s wallet. Anyone may call it; the money can only go to the buyer.
Limits
Section titled “Limits”- The deposit must be within the vault’s limits (10 to 8 000 USDT at the launch), or the call reverts.
- Anything sent to a deposit address directly, rather than through
forwardFrom, stays there. - If Tether ever switched on USDT’s transfer fee, the last refund at a shared deposit address could be stranded.