Skip to content

Conversation

@satoshiotomakan
Copy link
Collaborator

Description

When UserOperation is generated by an EOA through EIP-7702, we should use Biz.execute4337Op() and Biz.execute4337Ops() instead of SimpleAccount.execute() and SimpleAccount.executeBatch().

How to test

Run Rust tests

Types of changes

Add Ethereum.Proto.SigningInput.userOperationMode enum. Applied if only TxMode::UserOp.

Checklist

  • Create pull request as draft initially, unless its complete.
  • Add tests to cover changes as needed.
  • Update documentation as needed.
  • If there is a related Issue, mention it in the description.

If you're adding a new blockchain

  • I have read the guidelines for adding a new blockchain.

@satoshiotomakan satoshiotomakan requested a review from gupnik as a code owner March 20, 2025 21:15
@github-actions
Copy link

github-actions bot commented Mar 20, 2025

Binary size comparison

➡️ aarch64-apple-ios:

- 13.88 MB
+ 13.90 MB 	 +20 KB

➡️ aarch64-apple-ios-sim:

- 13.88 MB
+ 13.90 MB 	 +20 KB

➡️ aarch64-linux-android:

- 18.29 MB
+ 18.31 MB 	 +24 KB

➡️ armv7-linux-androideabi:

- 15.31 MB
+ 15.33 MB 	 +20 KB

➡️ wasm32-unknown-emscripten:

- 13.01 MB
+ 13.03 MB 	 +19 KB

gupnik
gupnik previously approved these changes Mar 21, 2025
Copy link
Collaborator

@gupnik gupnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One minor comment. Looks good otherwise!

@satoshiotomakan satoshiotomakan changed the title feat(eip7702): Add Erc7703Eoa Smart Wallet Type feat(eip7702): Add Biz Smart Contract Account Type Mar 21, 2025
@satoshiotomakan satoshiotomakan merged commit b8c1fab into master Mar 21, 2025
14 checks passed
@satoshiotomakan satoshiotomakan deleted the s/user-operation-mode branch March 21, 2025 12:43
satoshiotomakan added a commit that referenced this pull request Mar 28, 2025
* feat(eip7702): Add Biz Smart Contract Account Type (#4319)

* fix(eip7702): Add `UserOperationMode`

* Add `erc4337.biz_account.abi.json` ABI

* fix(eip7702): Add `test_barz_transfer_erc7702_eoa` test

* fix(eip7702): Fix `Biz.execute4337Ops()`

* fix(eip7702): Minor changes

* fix(eip7702): Rename `UserOperationMode` to `SCAccountType`

* fix: tron message sign (#4326)

* Adds ability to specify the curve while constructing Private Key (#4324)

* Adds ability to specify the curve while constructing Private Key

* Adds signing functions without a curve

* Migrates to new API

* Use TWCoinTypeCurve

* Adds Curve

* Adds FFI Tests for Private Key V2 APIs

* Migrates Swift tests to new API

* Migrates Kotlin tests to V2 API

* Migrates WASM tests

* Migrates C++ tests to V2 APIs

* Removes deprecated APIs and migrates all to new ones

---------

Co-authored-by: Sergei Boiko <[email protected]>
Co-authored-by: Yeferson Licet <[email protected]>
satoshiotomakan added a commit that referenced this pull request Mar 28, 2025
* feat(eip7702): Add Biz Smart Contract Account Type (#4319)

* fix(eip7702): Add `UserOperationMode`

* Add `erc4337.biz_account.abi.json` ABI

* fix(eip7702): Add `test_barz_transfer_erc7702_eoa` test

* fix(eip7702): Fix `Biz.execute4337Ops()`

* fix(eip7702): Minor changes

* fix(eip7702): Rename `UserOperationMode` to `SCAccountType`

* fix: tron message sign (#4326)

* Adds ability to specify the curve while constructing Private Key (#4324)

* Adds ability to specify the curve while constructing Private Key

* Adds signing functions without a curve

* Migrates to new API

* Use TWCoinTypeCurve

* Adds Curve

---------

Co-authored-by: Sergei Boiko <[email protected]>
Co-authored-by: Yeferson Licet <[email protected]>
satoshiotomakan added a commit that referenced this pull request Apr 2, 2025
* feat(eip7702): Add Biz Smart Contract Account Type (#4319)

* fix(eip7702): Add `UserOperationMode`

* Add `erc4337.biz_account.abi.json` ABI

* fix(eip7702): Add `test_barz_transfer_erc7702_eoa` test

* fix(eip7702): Fix `Biz.execute4337Ops()`

* fix(eip7702): Minor changes

* fix(eip7702): Rename `UserOperationMode` to `SCAccountType`

* fix: tron message sign (#4326)

* Adds ability to specify the curve while constructing Private Key (#4324)

* Adds ability to specify the curve while constructing Private Key

* Adds signing functions without a curve

* Migrates to new API

* Use TWCoinTypeCurve

* Adds Curve

* feat(eip7702): Add `SetCode` transaction type (#4336)

* fix(eip7702): Add `SetCode` transaction type

* fix(eip7702): Add `Biz.executeBatch` function call

* Add `AuthorizationSigner`

* fix(eip7702): Fix Authorization list RLP encoding

* fix(eip7702): Add `Biz.execute` and `Biz.executeBatch` tests

* fix(eip7702): Add android test

* [CI] Trigger CI

* feat(biz): Adjust `Barz.getEncodedHash` according to the latest changes in Biz contract (#4342)

* fix(biz): Adjust `Barz.getEncodedHash` according to the latest Biz changes

* fix(biz): Adjust Android test

* chore(dependencies): Update `gtest` to 1.16.0 (#4343)

* [ETH]: Makes factory and paymaster optional while serialising UserOpV07 (#4345)

* Uses updated API

---------

Co-authored-by: Sergei Boiko <[email protected]>
Co-authored-by: Yeferson Licet <[email protected]>
satoshiotomakan added a commit that referenced this pull request Apr 9, 2025
* feat(eip7702): Add Biz Smart Contract Account Type (#4319)

* fix(eip7702): Add `UserOperationMode`

* Add `erc4337.biz_account.abi.json` ABI

* fix(eip7702): Add `test_barz_transfer_erc7702_eoa` test

* fix(eip7702): Fix `Biz.execute4337Ops()`

* fix(eip7702): Minor changes

* fix(eip7702): Rename `UserOperationMode` to `SCAccountType`

* fix: tron message sign (#4326)

* Adds ability to specify the curve while constructing Private Key (#4324)

* Adds ability to specify the curve while constructing Private Key

* Adds signing functions without a curve

* Migrates to new API

* Use TWCoinTypeCurve

* Adds Curve

* feat(eip7702): Add `SetCode` transaction type (#4336)

* fix(eip7702): Add `SetCode` transaction type

* fix(eip7702): Add `Biz.executeBatch` function call

* Add `AuthorizationSigner`

* fix(eip7702): Fix Authorization list RLP encoding

* fix(eip7702): Add `Biz.execute` and `Biz.executeBatch` tests

* fix(eip7702): Add android test

* [CI] Trigger CI

* feat(biz): Adjust `Barz.getEncodedHash` according to the latest changes in Biz contract (#4342)

* fix(biz): Adjust `Barz.getEncodedHash` according to the latest Biz changes

* fix(biz): Adjust Android test

* chore(dependencies): Update `gtest` to 1.16.0 (#4343)

* [ETH]: Makes factory and paymaster optional while serialising UserOpV07 (#4345)

* feat(biz): Allow to call `Biz.execute` when EOA is delegated already (#4351)

* fix(biz): Allow to call `Biz.execute` when EOA is delegated already

* feature(biz): Adopt C++ tests

* feat(biz): Add and fix android tests

* feat(biz): Fix ios tests

* chore(aa): Rename `Execute` and `Batch` to `AAExecute` and `AABatch` correspondingly

* chore(scw): Rename `AABatch` and `AAExecute` to `SCWalletBatch` and `SCWalletExecute`

* chore(uov7): Serialize UserOperation numbers as hex 0x prefixed (#4353)

---------

Co-authored-by: Sergei Boiko <[email protected]>
Co-authored-by: Yeferson Licet <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants