-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Description
Objective
I aim to enable gasless transactions for users without requiring smart contract modifications, allowing willing parties to sponsor transaction gas fees (base fee and tip) on behalf of users.
Key Benefits
- Enhance user adoption by removing gas fee barriers
- Provide flexibility for businesses to subsidize specific transaction types
- Maintain EVM equivalence while offering a unique feature
Use Cases
- Stablecoin issuers can subsidize fees for token transfers, boosting adoption
- Game developers can cover fees for in-game transactions, improving user experience
Feature Description
I propose adding a new transaction type called "Sponsored Transaction" that allows a sponsor to pay for an original transaction's gas fees. The sponsored transaction references a pending original transaction from the mempool or received directly from the user.
Key Aspects
- Sponsor provides equal or higher base fee and tip values compared to the original transaction
- Blockchain executes the original transaction, respecting its gas limit and data
- 'msg.sender' remains the original transaction's sender address
- Gas fees are deducted from the sponsor's account
- Original transaction sender's nonce is incremented; sponsor's nonce is ignored
- Additional gas overhead applied to sponsored transactions
Implementation Details
- Allow zero-price original transactions in the mempool for a few minutes
- Introduce a sequence ID for sponsored transactions to manage replacements
- Implement mempool management to prioritize highest-paying sponsored transactions
- Ensure proper nonce management to prevent attacks on sponsors
Unrelated to Account Abstraction
This feature focuses on enabling EOAs to sponsor other EOAs' transactions, distinct from smart contract-based account abstraction proposals like EIP 4337 or EIP 7702.
Why Taiko Should Implement This Feature
- Differentiation: Offer a unique feature that sets Taiko apart from other L2 solutions
- Partnerships: Facilitate collaborations with stablecoin issuers and game developers
- User Growth: Lower barriers to entry for new users, driving adoption
- EVM Compatibility: Maintain EVM equivalence while adding valuable functionality
- Flexibility: Easy to deprecate if needed, minimizing long-term risks
Next Steps
- Conduct a security analysis to identify potential vulnerabilities
- Develop a detailed technical specification
- Implement a prototype for testing and benchmarking
- Gather feedback from potential partners and the community
- Refine the implementation based on feedback and testing results
By implementing sponsored transactions, I believe Taiko can offer a powerful tool for ecosystem growth while maintaining its core principles of EVM equivalence and scalability.
Spam policy
- I verify that this issue is NOT SPAM and understand SPAM issues will be closed and reported to GitHub, resulting in ACCOUNT TERMINATION.