Altszn.com
  • Home
  • Crypto
    • Altcoins
    • Bitcoin
    • Ethereum
    • Monero
    • XRP
    • Zcash
  • Web3
  • DeFi
  • NFTs
No Result
View All Result
Altszn.com
  • Home
  • Crypto
    • Altcoins
    • Bitcoin
    • Ethereum
    • Monero
    • XRP
    • Zcash
  • Web3
  • DeFi
  • NFTs
No Result
View All Result
Altszn.com
No Result
View All Result

Account Abstraction in Ethereum: Part 1

Altszn.com by Altszn.com
February 20, 2025
in Web3
0
Account Abstraction in Ethereum: Part 1
399
SHARES
2.3k
VIEWS
Share on FacebookShare on Twitter


What is Account Abstraction?

 

Account abstraction is an innovative concept in blockchain that seeks to unify and enhance the functionality of user accounts within a decentralized system. In the Ethereum network, two types of accounts currently exist:

  • Externally Owned Accounts (EOAs): Controlled by private keys and usually belonging to individuals or entities.
  • Contract Accounts: Smart contracts that are executed based on specific logic written in their code.

Account abstraction seeks to unify the two types of Ethereum accounts—EOAs (Externally Owned Accounts) and smart contract accounts—into a single, more user-friendly model. This is done by allowing smart contracts to initiate and validate transactions.

In simple terms, this means that instead of relying solely on private keys (like with EOAs), smart contracts can now manage and execute transactions on behalf of users, offering greater flexibility and enabling new features such as customizable security models, automated and gasless transactions, meta-transactions, and enhanced privacy. These innovations simplify user interactions and expand the possibilities within the Ethereum ecosystem.

What are the problems we are facing? Why do we need it?

The Ethereum network’s current structure faces some limitations:

  1. User Experience: EOAs require private keys and gas fees in Ether, creating friction for new users who may find wallet security and gas concepts complex.
  2. Security Risks: The binary nature of private keys makes them susceptible to loss or theft, leading to irrevocable loss of funds.
  3. Limited Features: EOAs lack programmability, preventing the implementation of advanced features like multi-signature wallets or daily transaction limits.

Account abstraction aims to address these issues, improving the network’s usability, security, and functionality.

Approaches to Implement Account Abstraction: Pros and Cons

1. Protocol-Level Changes

Involves changing the Ethereum protocol to enable native smart contract wallets. This approach demands consensus across the entire Ethereum network.

  • Pros: Fully integrated and standardized solution, potentially highly efficient.
  • Cons: Slow adoption, requires hard forks, and poses compatibility issues.

2. Layer 2 Solutions

Layer 2 networks can implement custom transaction validation logic while offloading transaction processing.

  • Pros: Fast and flexible, allowing experimentation without altering the main Ethereum protocol.
  • Cons: Requires complex bridging and may not fully resolve core issues with EOAs.

Proposes an account abstraction implementation entirely at the application level without requiring protocol changes.

  • Pros: Backward-compatible, flexible, and leverages existing infrastructure.
  • Cons: Requires an additional bundler infrastructure and new transaction flow.

What Is ERC-4337 and Why Is It the Best Implementation?

ERC-4337 introduces a new model for handling transactions, known as UserOperation objects. Instead of sending transactions directly to the Ethereum blockchain, users sign UserOperation objects that bundlers aggregate and submit to the blockchain. This system allows smart contract wallets to securely initiate transactions without depending on the existing transaction flow.

Benefits:

  1. Programmability: Allows developers to implement custom validation logic, enabling features like social recovery and multi-signature wallets.
  2. Reduced Costs: Bundling transactions can lead to optimized gas usage.
  3. Backward Compatibility: Can operate alongside EOAs, offering a seamless transition.

Specs, Details and Architecture of ERC-4337

Components:

1. User:

      1. Off-chain: Creates and signs a UserOperation, which contains the transaction data.

2. UserOperations:

      1. Off-chain: Represents the transaction data, similar to the structure of a regular transaction.

3. Bundler:

      1. Off-chain: Collects multiple UserOperations.
      2. On-chain: Packages them into a batch transaction and submits it to the EntryPoint contract.

4. EntryPoint Contract:

      1. On-chain: Manages the execution of UserOperations and ensures consistency across the transactions.

5. Paymaster:

      1. On-chain: Can sponsor transaction fees by paying for gas on behalf of users.

Workflow:

      1. A user creates a UserOperation off-chain and then signs it.
      2. The bundler collects UserOperations from different users and submits them to the EntryPoint contract.
      3. The EntryPoint contract verifies and executes each UserOperation, deducting gas fees appropriately.

What Are Bundlers in Detail?

Bundlers are specialized actors in the ERC-4337 architecture. Their responsibilities include:

      1. Aggregation: Collects multiple UserOperations and aggregates them into a single batch transaction.
      2. Submission: Sends the aggregated transaction to the EntryPoint contract for execution.
      3. Fee Collection: Takes care of gas fees by deducting them from UserOperations or through external sponsorship mechanisms.

Eth Infinitism Bundler

Eth Infinitism is a reference implementation of a bundler designed to work with the ERC-4337 account abstraction standard. It provides developers with a tool to bundle transactions in a production-ready environment.

Github: https://github.com/eth-infinitism/account-abstraction 

Steps on How to Run Eth Infinitism Bundler with Geth

Steps:

1. Start Geth docker container using this command:

docker run --rm -ti --name geth -p 8545:8545 ethereum/client-go:v1.10.26 \   --miner.gaslimit 12000000 \   --http --http.api personal,eth,net,web3,debug \   --http.vhosts '*,localhost,host.docker.internal' --http.addr "0.0.0.0" \   --ignore-legacy-receipts --allow-insecure-unlock --rpc.allow-unprotected-txs \   --dev \   --verbosity 2 \   --nodiscover --maxpeers 0 --mine --miner.threads 1 \   --networkid 1337 

 2. Clone Eth-Infinitism Guthib repo – https://github.com/eth-infinitism/bundler

3. Change directory and run 

cd bundler yarn && yarn preprocess

4. Now we will deploy contracts that came with bundler using hardhat –yarn hardhat-deploy --network localhost

5. We will start the bundler –

yarn run bundler (or yarn run bundler --unsafe, if working with "hardhat node")

Now your bundler is active on local url http://localhost:3000/rpc

6. To run a simple test, do – yarn run runop --deployFactory --network
http://localhost:8545/ --entryPoint
0x0000000071727De22E5E9d8BAf0edAc6f37da032

The runop script:

  • deploys a wallet deployer (if not already there)
  • creates a random signer (owner for wallet)
  • determines the wallet address, and funds it
  • sends a transaction (which also creates the wallet)
  • sends another transaction, on this existing wallet
  • (uses account[0] or mnemonic file for funding, and creating deployer if needed)

Conclusion

In this article, we delved into the concept of account abstraction in Ethereum, an innovative approach designed to enhance blockchain functionality by merging externally owned accounts (EOAs) with contract accounts. We examined the limitations of the current Ethereum account model, explored various implementation strategies including the prominent ERC-4337 standard, and discussed the significant roles of bundlers like the Eth Infinitism Bundler in optimizing transaction processes. 

This exploration provided a comprehensive understanding of how account abstraction can facilitate more secure, user-friendly, and programmable interactions within the Ethereum ecosystem, alongside practical insights on implementing these concepts using Eth-Infinitism bundler with Geth.



Read More: blog.web3labs.com

Tags: AbstractionaccountEthereumPartweb 3.0Web3
ADVERTISEMENT

Recent

Danger signs for Bitcoin as retail abandons it to institutions: Sky Wee

Danger signs for Bitcoin as retail abandons it to institutions: Sky Wee

May 14, 2025
Crypto VC deals drop in Q1, but funding more than doubles: PitchBook

Crypto VC deals drop in Q1, but funding more than doubles: PitchBook

May 14, 2025
Ether Nears $2.7K, Dogecoin Zooms 9% to Keep Cheery Mood Ongoing

Ether Nears $2.7K, Dogecoin Zooms 9% to Keep Cheery Mood Ongoing

May 14, 2025

Categories

  • Bitcoin (4,858)
  • Blockchain (11,412)
  • Crypto (9,352)
  • Dark Web (549)
  • DeFi (8,397)
  • Ethereum (4,905)
  • Metaverse (7,530)
  • Monero (290)
  • NFT (1,481)
  • Solana (5,047)
  • Web3 (20,703)
  • Zcash (509)

Category

Select Category

    Advertise

    Advertise your site, company or product to millions of web3, NFT and cryptocurrency enthusiasts. Learn more

    Useful Links

    Advertise
    DMCA
    Contact Us
    Privacy Policy
    Shipping & Returns
    Terms of Use

    Resources

    Exchanges
    Changelly
    Web3 Jobs

    Recent News

    Danger signs for Bitcoin as retail abandons it to institutions: Sky Wee

    Danger signs for Bitcoin as retail abandons it to institutions: Sky Wee

    May 14, 2025
    Crypto VC deals drop in Q1, but funding more than doubles: PitchBook

    Crypto VC deals drop in Q1, but funding more than doubles: PitchBook

    May 14, 2025

    © 2022 Altszn.com. All Rights Reserved.

    No Result
    View All Result
    • Home
      • Home – Layout 1
      • Home – Layout 2
      • Home – Layout 3

    © Altszn.com. All Rights Reserved.

    • bitcoinBitcoin (BTC) $ 102,880.00
    • ethereumEthereum (ETH) $ 2,588.18
    • tetherTether (USDT) $ 1.00
    • xrpXRP (XRP) $ 2.53
    • bnbBNB (BNB) $ 650.38
    • solanaSolana (SOL) $ 174.82
    • usd-coinUSDC (USDC) $ 0.999940
    • dogecoinDogecoin (DOGE) $ 0.234207
    • cardanoCardano (ADA) $ 0.794133
    • tronTRON (TRX) $ 0.273025
    • staked-etherLido Staked Ether (STETH) $ 2,584.81
    • wrapped-bitcoinWrapped Bitcoin (WBTC) $ 102,753.00
    • suiSui (SUI) $ 3.87
    • chainlinkChainlink (LINK) $ 16.77
    • wrapped-stethWrapped stETH (WSTETH) $ 3,100.90
    • avalanche-2Avalanche (AVAX) $ 24.55
    • stellarStellar (XLM) $ 0.304232
    • shiba-inuShiba Inu (SHIB) $ 0.000016
    • hedera-hashgraphHedera (HBAR) $ 0.204501
    • hyperliquidHyperliquid (HYPE) $ 25.00
    • leo-tokenLEO Token (LEO) $ 8.89
    • the-open-networkToncoin (TON) $ 3.24
    • bitcoin-cashBitcoin Cash (BCH) $ 399.10
    • litecoinLitecoin (LTC) $ 99.98
    • polkadotPolkadot (DOT) $ 4.92
    • usdsUSDS (USDS) $ 0.999837
    • wethWETH (WETH) $ 2,586.92
    • moneroMonero (XMR) $ 345.96
    • pi-networkPi Network (PI) $ 0.878105
    • wrapped-eethWrapped eETH (WEETH) $ 2,761.98
    • pepePepe (PEPE) $ 0.000014
    • bitget-tokenBitget Token (BGB) $ 4.73
    • binance-bridged-usdt-bnb-smart-chainBinance Bridged USDT (BNB Smart Chain) (BSC-USD) $ 1.00
    • ethena-usdeEthena USDe (USDE) $ 1.00
    • coinbase-wrapped-btcCoinbase Wrapped BTC (CBBTC) $ 102,834.00
    • whitebitWhiteBIT Coin (WBT) $ 30.29
    • uniswapUniswap (UNI) $ 6.63
    • bittensorBittensor (TAO) $ 444.01
    • nearNEAR Protocol (NEAR) $ 3.01
    • daiDai (DAI) $ 0.999822
    • aptosAptos (APT) $ 5.77
    • aaveAave (AAVE) $ 228.35
    • okbOKB (OKB) $ 54.33
    • ondo-financeOndo (ONDO) $ 1.01
    • kaspaKaspa (KAS) $ 0.120002
    • jito-staked-solJito Staked SOL (JITOSOL) $ 210.15
    • ethereum-classicEthereum Classic (ETC) $ 19.70
    • internet-computerInternet Computer (ICP) $ 5.57
    • tokenize-xchangeTokenize Xchange (TKX) $ 36.16
    • crypto-com-chainCronos (CRO) $ 0.101001
    • bitcoinBitcoin (BTC) $ 102,880.00
    • ethereumEthereum (ETH) $ 2,588.18
    • tetherTether (USDT) $ 1.00
    • xrpXRP (XRP) $ 2.53
    • bnbBNB (BNB) $ 650.38
    • solanaSolana (SOL) $ 174.82
    • usd-coinUSDC (USDC) $ 0.999940
    • dogecoinDogecoin (DOGE) $ 0.234207
    • cardanoCardano (ADA) $ 0.794133
    • tronTRON (TRX) $ 0.273025
    • staked-etherLido Staked Ether (STETH) $ 2,584.81
    • wrapped-bitcoinWrapped Bitcoin (WBTC) $ 102,753.00
    • suiSui (SUI) $ 3.87
    • chainlinkChainlink (LINK) $ 16.77
    • wrapped-stethWrapped stETH (WSTETH) $ 3,100.90
    • avalanche-2Avalanche (AVAX) $ 24.55
    • stellarStellar (XLM) $ 0.304232
    • shiba-inuShiba Inu (SHIB) $ 0.000016
    • hedera-hashgraphHedera (HBAR) $ 0.204501
    • hyperliquidHyperliquid (HYPE) $ 25.00
    • leo-tokenLEO Token (LEO) $ 8.89
    • the-open-networkToncoin (TON) $ 3.24
    • bitcoin-cashBitcoin Cash (BCH) $ 399.10
    • litecoinLitecoin (LTC) $ 99.98
    • polkadotPolkadot (DOT) $ 4.92
    • usdsUSDS (USDS) $ 0.999837
    • wethWETH (WETH) $ 2,586.92
    • moneroMonero (XMR) $ 345.96
    • pi-networkPi Network (PI) $ 0.878105
    • wrapped-eethWrapped eETH (WEETH) $ 2,761.98
    • pepePepe (PEPE) $ 0.000014
    • bitget-tokenBitget Token (BGB) $ 4.73
    • binance-bridged-usdt-bnb-smart-chainBinance Bridged USDT (BNB Smart Chain) (BSC-USD) $ 1.00
    • ethena-usdeEthena USDe (USDE) $ 1.00
    • coinbase-wrapped-btcCoinbase Wrapped BTC (CBBTC) $ 102,834.00
    • whitebitWhiteBIT Coin (WBT) $ 30.29
    • uniswapUniswap (UNI) $ 6.63
    • bittensorBittensor (TAO) $ 444.01
    • nearNEAR Protocol (NEAR) $ 3.01
    • daiDai (DAI) $ 0.999822
    • aptosAptos (APT) $ 5.77
    • aaveAave (AAVE) $ 228.35
    • okbOKB (OKB) $ 54.33
    • ondo-financeOndo (ONDO) $ 1.01
    • kaspaKaspa (KAS) $ 0.120002
    • jito-staked-solJito Staked SOL (JITOSOL) $ 210.15
    • ethereum-classicEthereum Classic (ETC) $ 19.70
    • internet-computerInternet Computer (ICP) $ 5.57
    • tokenize-xchangeTokenize Xchange (TKX) $ 36.16
    • crypto-com-chainCronos (CRO) $ 0.101001