voltrevo
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    1
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # BLSWallet & 4337 ## [1. Fully embrace 4337](https://hackmd.io/6_rTYV--SimB3lTlLVFOmg?both) - Drop support for directly calling `VerificationGateway` for ordinary transactions and pivot to only using the 4337 `EntryPoint` contract - Use the 4337 fee/gas mechanism - Stop developing the model where the wallet adds an explicit `tx.origin` payment - Continue to explore/promote an ecosystem where dApps can pay `tx.origin`, allowing us to set the 4337 fee fields to zero when this is available (relying on mev/etc to identify these opportunities) This seems by far the best option. We can still promote an ecosystem where dApps pay `tx.origin` and enable us to set the 4337 fee fields to zero. This will always be a (perhaps rather small) subset of dApps, so we need to primarily support a payment mechanism that is universal, so dApps paying `tx.origin` is secondary. I also believe we should not pursue a model where the user simply includes an extra `tx.origin` payment. It diverges from the 4337 ecosystem without benefit. At the very least, these `tx.origin` payments should be tied to `BASEFEE` for stability, but... that's just 4337. Let's just do that. I think we might be overestimating the inertia of the current system. Most of the work we have done is really about bringing all these pieces together and assembling a team that deeply understands the idea. Pivoting to 4337 from this point is totally achievable, and trying to support a hybrid seems to be mostly a headache with little benefit. ## 2. Support 4337 in parallel Like (1), but: - Retain direct calls to `VerificationGateway` - Always set 4337 fee fields to zero (or have different kinds of payment for each system?) - Rely on wallets adding explicit `tx.origin` payments for all dApps that haven't integrated these kinds of payments This option might cause less disruption to our current plans. It avoids new development to support the 4337 fee mechanism but depends on a separate `tx.origin` payment ecosystem emerging and relies on incomplete work to support wallets adding `tx.origin` payments. It's also possible we could use the 4337 fee fields when using 4337, and separately use `tx.origin` payments when not using 4337. Unless there is already a lot of momentum with third parties wishing to integrate the current system, I see it as an unnecessary fragmentation and source of confusion for BLSWallet. ## 2a. Support 4337 in parallel using extra contracts to avoid existing contract changes In (2), the idea is to add the necessary 4337 mechanisms to `VerificationGateway` and `BLSWallet`. [There is a prototype for this](https://github.com/voltrevo/account-abstraction/tree/21b72dd/contracts/samples/BLSWallet). There's been some discussion about using additional contracts to avoid any changes to the existing contracts, which may reduce our auditing costs. However, this is currently incompatible with signature aggregation. The 4337 `EntryPoint` contract makes separate calls for signature verification and contract wallet calls. The only way to make our contract wallet do anything is to go via `VerificationGateway#processBundle`, which requires a valid signature. Because the 4337 `EntryPoint` makes a separate call for each operation, each operation would then need to have an individual signature for `VerificationGateway#processBundle` to accept it. Conceivably the 4337 `EntryPoint` could be changed, but 4337 wants to measure the gas used by each operation to enable fee payment tied to those measurements according to the actual on-chain execution. It's not possible to do this without carving out another new 4337 flow specifically for our model which sets 4337 fees to zero (relying on paying `tx.origin` in other ways). Instead, we should simply change `BLSWallet.sol` to trust calls from the 4337 `EntryPoint` or another proxy contract. This still allows us to avoid changing `VerificationGateway`, and instead have `BLSWallet.sol` or its proxy contract point to another place for aggregate signature verification. "Proxy contract"s above would allow us to avoid adding `validateUserOp()` and `getAggregator()` to `BLSWallet.sol`. However, since these are simple, and we're modifying this contract anyway, I believe it makes a lot more sense to simply add these to `BLSWallet.sol` in addition to trusting another caller. Proxy contracts would also mean the `sender` field in the 4337 `UserOperation` would need to be these proxy contracts instead of the actual contract wallets (`BLSWallet.sol`), resulting in additional confusion for wallet implementers, users, block explorers, etc. To summarize: - Can avoid changing `VerificationGateway` - Can't realistically avoid changing `BLSWallet.sol` - May reduce auditing overhead because `VerificationGateway` is unchanged, but introduces a new contract to audit (the 'Aggregator' indicated by `getAggregator()`, which verifies aggregate signatures for 4337 calls) ## Contract wallet creation / 1st tx For (2) and (2a) there's ambiguity about how the contract wallet (`BLSWallet.sol`) is created. 4337 supports contract wallet creation using the `initCode` field, which could be used, but creates confusion for the blskey <=> address relationship (now different depending on whether you use the 4337 `EntryPoint` or `VerificationGateway`). It also requires an extra contract interaction to configure the `VerificationGateway`, and might mean additional changes to `VerificationGateway` (relevant for (2a)). Alternatively, we can rely on `VerificationGateway` for contract wallet creation, but it means users targeting 4337 will need to explicitly create their wallet. ## 3. Abandon all 4337 interop plans Maybe it's possible that it's too important to keep things the way they are and 4337 isn't getting any traction anytime soon anyway. If these things are true it's conceivable we could just forget about 4337 and continue without it. A related and more realistic point is that we could finalize V1 without any relationship to 4337 and focus on V2 as a 4337 wallet.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully