Comprehensive 16-week execution roadmap breaking down the protocol rollout across 5 parallel engineering tracks. Translates the 30-cycle audit spec into verifiable deliverables, CI/CD quality gates, and go-to-market milestones.
DATA POINTS VETTED & RECONCILED- βConfirmed 5 parallel workstreams across monorepo packages (contracts, crypto-core-wasm, sdk, web-dapp)
- βReconciled zero-custody model: relies on NEAR Intents native vaults, eliminating custom foreign bridge code
- βProgrammatic $COTI buyback keeper pipeline on Ethereum L1 verified
- βApple App Store Guideline 3.1.5 compliance strategy for iOS mobile app verified
- βMulti-phase security audit schedule and mainnet dry-run checklist confirmed
CORE ARCHITECTURAL TAKEAWAYS- β‘Phase 0β5 structured timeline: Bootstrap -> NEAR Intents -> WASM SDK -> COTI L2 -> DApp -> Mainnet
- β‘Monorepo architecture using Turborepo + pnpm with strict CI/CD linting, clippy, and slither gates
- β‘Automated $COTI spot buyback flywheel converting $0.20 micro-fees into permanent token buy pressure
- β‘Mobile client strategy incorporating zero-payload silent push notifications for Apple/Google privacy
Interphase Protocol β Detailed Technical Implementation Roadmap
Project Name: Interphase (patchhaystacks/interphase)
Brand & Domains: Primary: interphase.fi | Censorship-Resistant Mirror: interphase.eth.limo
Document Version: 1.0.0
Target Release: Q1βQ2 2027
Master Architecture Reference: spec.md (v3.0.0, Post-30-Cycle Enterprise Audit)
Execution Model: 16-Week Multi-Track Engineering Sprint to Mainnet & App Store Release
#Executive Summary & Engineering Philosophy
This roadmap translates the 30-cycle hardened architectural specification (spec.md) into an actionable, rigorous, 16-week software engineering execution plan.
The protocol delivers omnichain wallet unlinkability (e.g. Ethereum → Solana) from Day 1 by operating as a Pure Cryptographic Privacy & Routing Overlay. By fully leveraging NEAR Intents' existing, battle-tested multichain deposit vaults, Chain Signatures, and solver orderbooks across all chains, Interphase completely eliminates the need to develop, deploy, and audit custom asset custody escrowsβdrastically shrinking smart contract hack risk, regulatory exposure, and time to market.
SYSTEM TOPOLOGY ARCHITECTURE 16-WEEK HIGH-LEVEL TIMELINE
W1-W2 W3-W5 W6-W8 W9-W11 W12-W14 W15-W16
[Phase 0] ββΊ [Phase 1] ββΊ [Phase 2] ββΊ [Phase 3] ββΊ [Phase 4] ββΊ [Phase 5]
Setup & NEAR Intents Client WASM COTI L2 & Frontend & Audits, Dry-Run
Bootstrap & Buyback Crypto SDK NEAR Solvers Mobile Apps & Mainnet Launch
#1. Workstream Overview & Team Topography
Execution is divided across 5 parallel, synchronized engineering workstreams:
SYSTEM TOPOLOGY ARCHITECTUREβββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β 5 PARALLEL ENGINEERING WORKSTREAMS β
βββββββββββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββββββββ€
β Workstream A: Protocol & β NEAR Intents (Defuse) multichain adapters, β
β Treasury Infra β Uniswap L1 COTI buyback keeper, reference β
β β PrivacyRouterEscrow.sol for private deploy β
βββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββββ€
β Workstream B: Client Crypto β Rust compiled to WASM32 + TypeScript SDK β
β & SDK β HKDF zeroize, Dual-Curve Stealth, ML-KEM-768β
βββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββββ€
β Workstream C: Infrastructure, β COTI Garbled Circuits, Paymasters, SMT, β
β Oracles & Solversβ NEAR Intents solver daemon, Pyth oracles β
βββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββββ€
β Workstream D: Applications & β Next.js Web3 DApp (Cloudflare + IPFS/ENS), β
β Mobile Apps β React Native iOS/Android (Apple 3.1.5) β
βββββββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββββββββββββββββββββ€
β Workstream E: Security, Audit β Fuzzing, symbolic execution, external auditsβ
β & Compliance β OpenVASP/TRISA, TRM Labs integration β
βββββββββββββββββββββββββββββββββ΄ββββββββββββββββββββββββββββββββββββββββββββββ
#2. Phase-by-Phase Technical Deliverables
Objective: Establish monorepo structure, toolchains, continuous integration, testnet node infrastructure, and baseline contracts.
Deliverables & Tasks
- Monorepo Architecture:
- Initialize a unified monorepo using Turborepo + pnpm:
packages/contracts-evm: Foundry workspace for EVM smart contracts.
packages/contracts-solana: Anchor workspace for Solana settlement programs.
packages/crypto-core-wasm: Rust library compiled to wasm32-unknown-unknown via wasm-pack.
packages/sdk: TypeScript SDK wrapping WASM core and @coti-io/coti-ethers.
packages/solver-daemon: Node.js / Rust backend worker for NEAR Intents solvers.
packages/web-dapp: Next.js web application.
packages/mobile-app: React Native / Expo mobile application.
- Infrastructure & Network Endpoints:
- Configure RPC endpoints and developer accounts across:
- COTI V2 Testnet (L2 Garbled Circuits).
- Ethereum Sepolia, Base Sepolia, Arbitrum Sepolia, Avalanche Fuji.
- Solana Devnet.
- NEAR Testnet (Chain Signatures MPC contract).
- CI/CD Quality Gates:
- GitHub Actions workflow enforcing:
cargo clippy --all-targets --all-features -- -D warnings
cargo audit (vulnerability checking for Rust crates)
forge test --gas-report (100% line coverage for critical contract paths)
slither . (static security analysis on contracts)
prettier and eslint formatting checks.
#Phase 1: NEAR Intents Protocol Integration & Treasury Buyback Engine (Weeks 3β5)
Objective: Integrate natively with NEAR Intents (Defuse) multichain deposit vaults, configure fee routing, implement the automated Uniswap L1 COTI buyback keeper, and maintain PrivacyRouterEscrow.sol as a standalone reference implementation.
Deliverables & Tasks
- NEAR Intents Multichain Deposit Vault Integration:
- Integrate directly with NEAR Intents / Defuse multichain deposit contracts & MPC accounts:
- Omnichain Ingestion: Support deposits across EVM (Ethereum, Base, Arbitrum), Solana, Bitcoin, Sui, and NEAR.
- Zero Custody Risk: Eliminate custom bridge hack surface area by inheriting NEAR's threshold cryptography (Chain Signatures).
- Fee-Split Hook: Configure the
appFee parameter routing the $0.20 Confidential Routing Fee + optional protocol spread directly to the Interphase Treasury wallet at settlement.
- Programmatic $COTI Buyback Keeper (
packages/contracts-evm):
- Implement automated treasury keeper contract on Ethereum L1:
- Aggregates collected USDC fees until reaching the $$1,000$ threshold.
- Executes programmatic spot market buys on Uniswap V3 (Ethereum L1) from USDC to COTI ERC-20.
- Bridges acquired tokens via canonical COTI Native Bridge (
bridge.coti.io) to COTI L2.
- Refills the Gasless Paymaster contract with native
$COTI gas.
- Reference Escrow & Sweeper Suite (Preserved for Standalone Deployments):
- Maintain
PrivacyRouterEscrow.sol:
- Preserved in codebase for enterprise private deployments requiring sovereign on-chain contract escrows.
- Includes Zero-Allowance Invariants, balance-delta accounting, and 3-Minute Auto-Refund Guard.
- Testing & End-to-End Simulation:
- Test intent generation, MPC signature verification, and automated fee splits on NEAR Testnet and Base Sepolia.
#Phase 2: Client Cryptography & Ingestion SDK (Weeks 6β8)
Objective: Build high-performance, memory-safe cryptographic primitives in Rust/WASM and bundle them into the universal TypeScript SDK.
Deliverables & Tasks
- Rust Cryptographic Core (
packages/crypto-core-wasm):
- Memory Zeroing: Utilize
zeroize::Zeroize and std::ptr::write_volatile across all private scalar buffers.
- Ephemeral Key Derivation:
HKDF-SHA256 single-use session key expansion.
- Dual-Curve Stealth Derivation:
- EVM: ERC-5564 secp256k1 point multiplication ($P_{stealth} = S_B + Hash(r \cdot V_B) \cdot G$).
- Solana: Ed25519 / Ristretto255 Diffie-Hellman scalar multiplication.
- Dual-Tier View-Tag Generator:
- $ViewTag1 = Hash(S{shared})[0]$
- $ViewTag4 = Hash(S{shared})[1..4]$
- Hybrid Post-Quantum KEM: Implement NIST FIPS 203 ML-KEM-768 (Kyber) dual-encapsulation alongside classical ECDH.
- TypeScript SDK Wrapper (
packages/sdk):
- Wrap WebAssembly binary with clean async TypeScript APIs:
generateIntent(sourceParams, destParams)
encryptPayload(intent, wasmModule)
scanTransactions(blockStream, viewKey) (accelerated mobile scanning)
deriveStealthPrivateKey(ephemeralPubkey, spendingKey)
- Direct integration with
@coti-io/coti-ethers for COTI L2 encryption.
- WebCrypto Session Storage: Encrypt in-flight states into IndexedDB using non-extractable keys (
{ extractable: false }).
- Oblivious HTTP (OHTTP) Relay Client:
- Implement RFC 9458 client encapsulation stripping source IP headers before forwarding JSON-RPC requests to COTI L2.
#Phase 3: COTI L2 Policy Engine & NEAR Solver Marketplace (Weeks 9β11)
Objective: Deploy confidential compliance circuits on COTI L2 and operationalize the NEAR Intents solver auction daemon.
Deliverables & Tasks
- COTI L2 Garbled Circuit Policy Engine:
- Deploy
ICotiPoDPolicyEngine.sol on COTI V2:
- Evaluate encrypted intent amounts, recipient stealth addresses, and gas drops inside MPC.
- Verify zero-knowledge sanctions proofs ($\pi_{sanctions}$).
- Track 24-hour rolling volume accumulators per source wallet, enforcing Tier 1/2/3 escalation.
- Update 256-level Sparse Merkle Tree (SMT) of sanctions nullifiers.
- Deposit-Verified Gasless Paymaster:
- Deploy EIP-4337 Paymaster on COTI L2:
- Validate source chain deposit Merkle inclusion proofs before sponsoring gas.
- Reconcile gas reimbursement from winning solver settlement spread.
- Optimistic Sequencer Lockout Service:
- Redis-backed gateway checking
Nullifier = Keccak256(...) in $<1ms$ to eliminate redundant Garbled Circuit compute.
- NEAR Intents Solver Daemon (
packages/solver-daemon):
- Real-time WebSocket listener on NEAR auction channels.
- Automated quotation engine calculating dynamic volatility-scaled bonds.
- Pyth high-frequency oracle monitor ($<400ms$) triggering fair-market aborts during $>5%$ flash crashes.
- Destination execution bot on Solana (SPL transfer + atomic gas drop + memo view-tags).
- Cross-chain settlement claimer submitting NEAR MPC state proofs back to source escrows.
- Circle CCTP automated rebalancer clearing solver macro inventory.
- Reorg Underwriting Pool (RUP):
- Deploy the 2 bps mutual insurance vault backing 5-second instant retail trades ($<$5,000$) on Base and Arbitrum.
#Phase 4: Frontend, Mobile Client & App Store Submission (Weeks 12β14)
Objective: Deliver polished web and mobile applications with zero telemetry tracking and achieve Apple App Store approval under Guideline 3.1.5.
Deliverables & Tasks
- Web DApp (
packages/web-dapp):
- Build using Next.js with Vanilla CSS design system:
- Sleek, high-converting dark-mode interface with glassmorphism aesthetics.
- Real-time swap progress tracker via blinded WebSocket handles (
TrackingToken).
- Tax receipt exporter: W3C / EIP-712 Verifiable Credential download.
- Dual-hosting deployment:
- Primary Domain (
privacyrouter.io): Cloudflare with strict no-logs policy + TRM Labs wallet screening API.
- Censorship-Resistant Mirror (
privacyrouter.eth.limo): Deterministic IPFS build pinned on Arweave.
- Mobile Apps for iOS & Android (
packages/mobile-app):
- Implement in React Native / Expo:
- Hardware keystore integration (iOS Secure Enclave / Android KeyStore).
- Non-custodial wallet routing strictly to NEAR Intents solvers (Zodl blueprint).
- Background scanning daemon utilizing Dual-Tier View-Tags ($99.61%$ stream discard + memo check, $<0.001%$ CPU load).
- Zero-Payload Silent Push:
- Blinded wake-up signals (
{"wake": 1}) via APNs and Google FCM.
- Local on-device decryption of status updates without leaking metadata to Apple/Google.
- Apple App Store Review Submission:
- Package submission under Apple Guideline 3.1.5 (Cryptocurrencies):
- Self-custodial architecture certification.
- No omnibus mixer pools.
- Geographic geofencing disabling distribution in sanctioned territories.
#Phase 5: External Audits, Testnet Dry-Run & Mainnet Launch (Weeks 15β16)
Objective: Complete third-party security audits, execute public incentivized testnet, and initiate phased mainnet liquidity rollout.
Deliverables & Tasks
- Independent Security Audits:
- Commission 2 independent Tier-1 auditing firms (e.g. Trail of Bits, OpenZeppelin, Omniscia):
- Smart contract audit (EVM + Solana).
- Cryptographic review of WASM core, view-tags, and Garbled Circuit policies.
- Public Incentivized Testnet:
- 14-day public testnet campaign across Ethereum Sepolia, Base Sepolia, and Solana Devnet.
- Launch $150,000 Immunefi bug bounty for critical vulnerabilities.
- Mainnet Liquidity & Solver Onboarding:
- Deploy final contract addresses on Ethereum, Base, Arbitrum, Avalanche, and Solana.
- Onboard initial cohort of 5 professional market maker solvers on NEAR Intents.
- Fund initial Reorg Underwriting Pool with seed liquidity.
- Production Cutover:
- DNS cutover for
privacyrouter.io.
- Public release of mobile apps on App Store and Google Play.
- Publication of genesis W3C master public key.
#3. Critical Path & Dependency Gantt Matrix
SYSTEM TOPOLOGY ARCHITECTUREWeek 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
[Phase 0] Setup & CI ββββ
[Phase 1] Smart Contracts ββββββ
[Phase 2] Client WASM Core ββββββ
[Phase 3] COTI MPC & Solvers ββββββ
[Phase 4] Web & Mobile Apps ββββββ
[Phase 5] Audits & Launch ββββββ
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Critical Path: Smart Contracts βββΊ WASM SDK βββΊ COTI L2 Circuits βββΊ Audits
#4. Testing, Verification & Quality Assurance Gates
Every milestone must satisfy automated quality gates before progression:
| Quality Gate |
Minimum Requirement |
Enforcement Mechanism |
| Solidity Unit Coverage |
$\ge 98%$ branch coverage |
forge coverage --report lcov |
| Fuzz & Invariant Testing |
$>100,000$ runs with zero invariant violations |
Foundry forge test --fuzz-runs 100000 |
| Rust WASM Safety |
0 memory leaks, explicit volatile memory wipe |
cargo test + Valgrind / Miri memory sanitizer |
| Static Security Analysis |
0 High/Medium findings |
Slither & Mythril in CI pipeline |
| Mobile Performance |
$<0.05%$ battery consumption per 24 hours |
iOS Instruments & Android Profiler benchmarks |
| Cross-Chain Reorg Safety |
100% loss recovery in simulated sequencer equivocation |
Local Anvil/Solana testbench reorg simulation |
#5. Risk Register & Mitigation Playbook
| Risk Category |
Threat / Failure Mode |
Likelihood |
Impact |
Architectural Mitigation Protocol |
| Infrastructure |
Solana or L2 sequencer temporary halt |
Medium |
High |
Section 6.2: 3-minute fast-fail + NEAR signed Non-Settlement Proofs. |
| Market Risk |
Sudden stablecoin depeg (e.g. SVB event) |
Low |
Critical |
Section 6.7: Anti-depeg TWAP dislocation circuit breaker freezing execution at $\pm 2.5%$. |
| Regulatory |
App Store rejection under Guideline 3.1.5 |
Medium |
High |
Section 11.3: Zodl compliance blueprint; strictly self-custodial client routing to independent solvers. |
| Liquidity |
Directional drain (EVM → SOL exhaustion) |
High |
Medium |
Section 6.10: Asymmetric negative fee rebates paying cash back to reverse-flow arbitrageurs. |
| Compliance |
User sanctioned while deposit in transit |
Low |
High |
Section 7.6: Dynamic SMT routing in-flight deposits to SanctionsQuarantineVault.sol. |
| Cryptographic |
Post-quantum "Harvest Now, Decrypt Later" |
Low (near-term) |
Critical |
Section 5.10: Hybrid ML-KEM-768 (Kyber) lattice key encapsulation. |
#6. Definition of Done (DoD) for Mainnet Launch
The protocol is considered ready for production mainnet launch when:
- All 30 patches from spec.md have 100% test coverage in CI.
- Two independent smart contract and cryptographic audits are completed with all critical and high findings resolved.
- Testnet dry-run completes 10,000 continuous test swaps with zero stuck assets or state desynchronizations.
- Mobile apps pass initial App Store Connect and Google Play review without guideline rejection.
- Reorg Underwriting Pool is capitalized with at least $100,000 in seed liquidity.
- Verification receipts pass W3C Verifiable Credential standard tests for tax authority admissibility.