docs: Qash EVM migration technical plan - #304
Open
Huygon764 wants to merge 1 commit into
Open
Conversation
Plan for forking the Qash monorepo and replacing its Miden chain layer with PolyPay's EVM stack (zkVerify signer privacy + relayer + MetaMultiSigWallet on Base). Covers target architecture, identity/auth design (Para session, passkey PRF secret custody, commitment-bound Noir circuit), schema changes to the three multisig tables, Phase 1 scope (end-to-end batch bill payment on Base Sepolia), workstream breakdown, and risks.
Huygon764
force-pushed
the
docs/qash-evm-migration-plan
branch
from
July 14, 2026 09:42
9c24bc5 to
cfc6df5
Compare
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.
Technical plan for the PolyPay to Qash EVM migration.
Decision
Fork the Qash monorepo and replace its Miden chain layer with PolyPay's EVM stack — not the other way round. Qash's backend already has every business model we need (Company, TeamMember, Employee, Invoice, Bill, Payroll, Proposal); PolyPay's has none of them. Both are NestJS 11 + Prisma 7 + Postgres, so the transplant is mechanical rather than architectural.
What the plan covers
Two findings worth review
The transaction circuit's ECDSA check currently constrains nothing.
pub_key_x/pub_key_yare private inputs recovered from the prover's own signature, and nothing binds them tosecretorcommitment— the contract stores only commitments. A prover holdingsecretcan generate a throwaway keypair, sign with it, and pass. The check costs most of the proving time and buys no security. The plan fixes this by bindingcommitment = poseidon2(secret, hash(pubkey)), which makes the intended two-factor property real. This applies to PolyPay today, not only to Qash EVM.PolyPay's secret derivation cannot work with Para.
secret = keccak256(sign("noir-identity"))assumes deterministic ECDSA. Para is a 2-of-2 MPC wallet: no party holds the full private key, so RFC 6979 is mathematically unavailable and every signature differs. Hence the passkey-based custody design.Plan document: QASH-EVM-PLAN.md