non-crypto users? When you ask them to install a wallet software, they often say… •Is this software trustworthy? •Installing a new software is troublesome! •Why don’t you set up a wallet for me? Users cannot manage their crypto assets only with existing familiar tools!
a transaction simply by sending an email without new software installation or key management. • Security: The user’s crypto assets are secure as long as existing sender domain servers (SDS), e.g., Gmail, are honest. • Functionality: The users can not only transfer their assets but also manipulate them on-chain in arbitrary manners by changing the message format.
6TFS 4FOEFS%PNBJO 4FSWFS 4%4 "UUBDIFE ;,1 1SPPG &UIFSFVN #MPDLDIBJO #SPBEDBTU Domain servers that support the DKIM protocol, e.g., Gmail, attach RSA digital signatures to ensure that the sender and content of the email are not forged. A smart contract can securely authenticate the sender and content of the email by verifying the RSA digital signature and the contents in the email with zero-knowledge proof (ZKP), as long as the sender domain server (SDS) does not forge the user’s email [1,2].
wallet contract stores each user’s email address and balance per currency unit. A user can transfer the user’s crypto assets deposited to the contract wallet by sending an email with the message “Transfer X ETH to [email protected]”. A user can exchange the user’s ETH to DAI via Uniswap by sending an email with the message “Swap X ETH to DAI via Uniswap”. Transfer X ETH to [email protected] om Swap X ETH to DAI via Uniswap Example 1 Example 2 [email protected][email protected][email protected][email protected][email protected]
our system, i.e., proof generation and interaction with the wallet contract. Developer Aggregator SDS User Contract Distribute a ZKP circuit Deploy a contract %FWFMPQN FOUQIBTF 0QBSBUJPO QIBTF Send an email to the aggregator’s email address. Attach a digital signature. (DKIM) Generate a proof and submit it to the wallet contract. • Users do not need to install new software or access new web pages. • Existing SDSs that adopt the DKIM protocol can be used without modification.
sending an email to the aggregator’s email address with the message “Transfer 0.005 ETH to [email protected]”. Bob exchanges 0.005 ETH for DAI via Uniswap by sending an email to the aggregator’s email address with the message “Swap 0.005 ETH to DAI via Uniswap”. Transfer 0.005 ETH to emaiwallet.bob @gmail.com Swap 0.005 ETH to DAI via Uniswap Scenario 1 Scenario 2 Alice Alice deposits 0.01 ETH to the wallet contract before the demo scenario. Alice Bob Bob Bob
the Ethereum mainnet • Sender Domain Server: Gmail (@gmail.com) • Decentralized Exchange: Uniswap V3 Development libraries used in the demo implementation • ZKP library: PSE’s fork of halo2 https://github.com/privacy-scaling-explorations/halo2 • A library to generate a halo2 verifier smart contract: Axiom’s fork of snark-verifier https://github.com/axiom-crypto/snark-verifier • A library of ZK-Email: halo2-zk-email (Sora Suegami is one of the main contributors of this library.) https://github.com/zkemail/halo2-zk-email
for message formats in email defined for each manipulation method. Variable-regex mapping (VRM) allows the developer to define a new manipulation method without writing any ZKP circuit! Developer Aggregator SDS User Contract Distribute a ZKP circuit Deploy a contract %FWFMPQN FOUQIBTF However, it is not easy for many developers to write a ZKP circuit by theirselves. Variable-Regex Mapping (VRM)
0OFFYBNQMFFNBJMXIPTF NFTTBHFTBUJT fi FTUIFSFHFY "4PMJEJUZJNQMFNFOUBUJPOPGB QSPDFTTGVODUJPOUIBUEF fi OFT IPXUPNBOJQVMBUFUIFVTFS`T DSZQUPBTTFUTBGUFSUIFFNBJM WFSJ fi DBUJPO "EFWFMPQFSPOMZOFFEUPQSFQBSFGPMMPXJOHUISFFUIJOHTUPEF fi OFBOFXNBOJQVMBUJPONFUIPE The VRM automatically generates a new ZKP circuit to verify the specified regex and the Solidity code of its verifier contract.
to operate their crypto assets simply by sending emails to an aggregator’s email address. • The user only needs to trust existing SDS, e.g., Gmail, without managing any private key. • The user can specify how to manipulate their crypto assets by changing the message format in the email. • We built a demo of the email wallet and confirmed that users can transfer their deposited ETH and exchange them for DAI just by sending emails. • We also built VRM, which allows developers to build a new manipulation method without writing any ZKP circuits.