A fully decentralized account abstracted, zk leveraged smart contract wallet

Introduction
We all know that to operate ERC-4337, a few centralized components are typically required. I’m here with a new approach to create a fully decentralized, abstracted account wallet.

This wallet can be made and accessed using just a username and password. Fund spending transactions can be initiated from any Externally Owned Account (EOA) as long as the correct username and password are used.

You can use anyone’s EOA to spends funds from your sc wallet and whosoever initiated the transaction, gets the gas fees paid by them in the same txn. If you don’t have EOA setup on your device, you can make transactions from the wallet using the backend service without compromising security. This way spending funds only requires username, password and internet.

The security of this wallet, including password verification and user operation validity, is supported by zk-SNARKs. Additional features include paying gas fees from the smart contract wallet and non-native gas payments.

1. Wallet creation

  • Users can create a wallet by providing a username and password. The password is hashed and then sent to the Factory smart contract along with the username. The hashed password is mapped to the username, and a Wallet contract is deployed with its address mapped with both the username and the hashed password. The Wallet contract is owned by the Factory and has only one function, multicall which can be accessed solely by the Factory contract.

2. Spend Funds

  • Whenever a user wishes to spend funds from the wallet, they need to provide their username, a zk proof confirming knowledge of the actual password, and the userOps generated in the frontend.

  • The zk proof generation requires three inputs: 1) password, 2) hashed password, and 3) userOps. The zk constraints check if the user knows the password(pre-image) corresponding to the hashed password. Additionally, the circuit verifies if the provided userOps match the user’s intentions, thereby eliminating the possibility of a front-running attack. After confirming these conditions, the zk proof is generated and can be verified on the chain.

  • The zk proof is generated in the frontend when the user selects their username, password, and userOps (such as swap, transfer tokens, mint NFTs, etc.). Following the generation of the zk proof, the “callWallet” function in the Factory contract is triggered.

  • This function verifies the zk proof, stores the hash of the proof to prevent reuse, and, upon successful verification, retrieves the address of the wallet contract associated with the hashed password. Subsequently, the “multicall” function of that wallet is executed, and the userOps are carried out.

One important aspect to consider is that the security of this wallet relies on the Poseidon Hash, which is used to create hash from the password and is snark-friendly. I would appreciate any feedback from the community and would welcome insights into the Poseidon Hash from community members.

Skip to main content
Fellowship of Ethereum Magicians

profile, messages, bookmarks and preferences

Hello :wave: Welcome to the Ethereum Magicians forum :sparkles:
Ethereum Magicians is a forum for the crypto community to have a place where anyone can join, create topic and discuss mainly about EIPs and technical difficulties of Ethereum ecosystem. Or in another words “Ethereum Magicians forum is a place on the internet where your voice will be heard and your contributions to the Ethereum will matter”. Ethereum Magicians is a group of individuals working and contributing to the Ethereum.

What to do on a forum?
Read and discuss about Ethereum
Create topic
Form a working group
Share prototype, code, graph and ask for feedback
Attend discussions and in-person meetings
First time on Ethereum Magicians forum?
If you’re the first time on the Ethereum Magicians forum, please check out our New Member Guide where are explained terms that we are using on this forum and will give you a lot of answers to questions regarding this forum and Ethereum Magicians in general.

History of Ethereum Magicians
Fellowship of Ethereum Magicians (FEM) was founded to solve problem of offline and online coordination in Ethereum. We started an open forum with a focus on improving Ethereum without unwanted noise (that social media like Twitter and Reddit provides). FEM is Fellowship of individuals with a common goal - Improve Ethereum.
If you’re interested in reading more of the history of FEM, read this Medium article from @pet3rpan

Feel free to introduce yourself in the Introduction thread

Read more about Ethereum Magicians
Ethereum Core Maintainers Medium article - explaining the difference between Ethereum Magicians, Ethereum Cat Herders and AllCore Devs

:sparkles: Feel free to share Ethereum Magicians posts on social media and tag us @EthMagicians :sparkles:

Categories

New Topic
EIPs
Ethereum Improvement Proposal all info 5d
9
@Limpisey77922321 5m
0
EVM Object Format (EOF) 11h
60
Core EIPs

Last Call
883 total
Tokens
ERC-6551: Non-fungible Token Bound Accounts 7m
208
Physical Backed Tokens 15h
19
EIP-6059: Parent-Governed Nestable Non-Fungible Tokens 6d
35
148 total
Happenings
RollCall #1 - In-Person At Devconnect Instanbul 2h
1
Join the 8th AllERCDevs tomorrow Aug 24
0
WalletUncon @ DEVConnect Istanbul Aug 9
0
Council Sessions

Regional Sessions

Presentations

Hackathons

Core Devs Meeting Notes
172 total
Primordial Soup
Trustless EIP-2771 10h
7
Keyless contract deployment with CREATE3 1d
5
EIP-DRAFT: Proof of Solvency Standard for Centralized Exchanges 4d
7
232 total
Interfaces
ERC 4337: Account Abstraction via Entry Point Contract specification 11h
119
ERC-5189: Account abstraction via Endorsed Operations 8d
13
EIP-6963: Multi Injected Provider Discovery 16d
29
16 total
Wallets
A fully decentralized account abstracted, zk leveraged smart contract wallet 17h
0
ERC draft: Password recovery for Account Abstraction Wallet Aug 26
2
Token asset management interface with smart contract wallet Jun 21
0
69 total
Process Improvement
Wizard web recovery cryptocurrency expert 1d
5
Responsible Disclosure Guidelines Sep 11
19
EIP-5069: EIP Editor Handbook Aug 23
1
101 total
Uncategorized
Welcome! Please README first! 13d
8
EIP-7540: Asynchronous ERC-4626 Tokenized Vaults 2d
5
Join the 12th AllERCDevs 5d
0
232 total
Cryptography
EIP-7503: Zero-Knowledge Wormholes - Private Proof of Burn (PPoB) 5d
18
EIP-XXX: Ed25519 Signature Verification Sep 21
3
Discussion: Removal of RIPEMD-160 and blake2f Precompiles Aug 30
19
7 total
User Experience
Trustless userop signing via browser? 12d
0
User initiation problem Aug 25
1
Building a library of Web3 Design Patterns for Devs and Designers Nov '22
0
26 total
Governance
ERC-4824 Decentralized Autonomous Organizations May 14
43
[Draft] EIP Meta: Permit to Link Apr 7
0
EIP Draft: Multi-chain Governance Jun '22
27
7 total
Working Groups
Proposal for adding blockTimestamp to logs object returned by eth_getLogs and related requests 25d
5
A case to study: proposed Constantinople-related fork on Ropsten Aug 3
2
Sepolia deposit smart contract source code Jun 14
0
Provider Ring

Data Ring

Signaling Ring

The Merge

Product Management Ring

Security Ring

Ethereum 1.x Ring

Education Ring

Ethereum Architects

Integrity Ring

Mobile Ring

Fund Recovery Ring
164 total
Tooling
Solidity Mathematical Expression Interpreter Library 26d
0
P2P exchanges parsers Sep 10
0
Introducing: eth2-package - a tool for spinning up private testnets in a single command Aug 9
0
25 total
Site Feedback
Confuse about revert error Sep 22
0
Updating Ethereum Magicians Categories - 2021 Sep 15
14
Updating Ethereum Magicians Categories - Late 2022 Nov '22
1
29 total
Announcements
OpenZeppelin Adopts Diamond Storage for Upgradeable Smart Contracts Sep 15
0
Support GetBlock in Driving the Growth of Web3 Community with an Ethereum Testnet Faucet Apr 20
0
Installed “Discourse Math Plugin” for using LaTeX in comments Dec '22
3
24 total
Proof of Stake
ETH2 withdraws with lost mnemonics Jun 22
5
Geth node status Jan 17
0
An ice age in PoS - merits and potential implementation Aug '22
11
6 total
Transactions
Why can’t the miners pay for my transaction fee? Feb 9
3
How ethererum transaction works? Nov '22
2
Push batch payments using selfdestruct opcode for reentrancy immunity, lower gas costs and untraceable transactions from recipient address Jun '21
0
6 total
Sharding
How can zk-rollups with danksharding fix fractured/fractional liquidity Jan 6
2
Why not just use AR or filecoin to solve data aviliability issue? Sep '22
2
Sharding-format blob-carrying transactions Feb '22
1
5 total
Networking
What do you receive from the community? What does the community gives to Ethereum? Sep '22
1
Gossipsub Tests Nov '19
0
Forming a new Ring: ETH2.0 Networking Ring Apr '19
3
3 total
State Management
“Impromptu technical AMA on history expiry” - reddit post Nov '21
0
State Management Review Jul '21
3
Quadratic Mempool Service Apr '21
0
3 total
Proof of Work
Today is a proud day for Ethereum Aug '21
1
ETH PoW : Whats next ?:slight_smile: Apr '21
36
Inflation, stakers profits, the real reasons behind EIP-1559 Mar '21
2
4 total
Light Clients
Wire protocol post blockchain validation Apr '19
0
A cross-protocol, cross-implementation standard for server capacity management and flow control Apr '19
0
BlockQuick - Secure super light client for Ethereum May '19
0
12 total
Address Space Extension
0 total
A fully decentralized account abstracted, zk leveraged smart contract wallet

One important aspect to consider is that the security of this wallet relies on the Poseidon Hash, which is used to create hash from the password and is snark-friendly. I would appreciate any feedback from the community and would welcome insights into the Poseidon Hash from community members.

Reply

Hey I would like to work on this with you can you share a repo if you have created