Skip to content

Commit

Permalink
Update ERC-7579: specify fallback authorization control
Browse files Browse the repository at this point in the history
Merged by EIP-Bot.
  • Loading branch information
kopy-kat committed Aug 13, 2024
1 parent 5c95af4 commit f9fdd10
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions ERCS/erc-7579.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ To comply with this standard, smart accounts MUST implement the execution interf
interface IExecution {
/**
* @dev Executes a transaction on behalf of the account.
* @param mode The encoded execution mode of the transaction. See ModeLib.sol for details
* @param executionCalldata The encoded execution call data
* @param mode The encoded execution mode of the transaction.
* @param executionCalldata The encoded execution call data.
*
* MUST ensure adequate authorization control: e.g. onlyEntryPointOrSelf if used with ERC-4337
* If a mode is requested that is not supported by the Account, it MUST revert
Expand All @@ -65,8 +65,8 @@ interface IExecution {
/**
* @dev Executes a transaction on behalf of the account.
* This function is intended to be called by Executor Modules
* @param mode The encoded execution mode of the transaction. See ModeLib.sol for details
* @param executionCalldata The encoded execution call data
* @param mode The encoded execution mode of the transaction.
* @param executionCalldata The encoded execution call data.
*
* MUST ensure adequate authorization control: i.e. onlyExecutorModule
* If a mode is requested that is not supported by the Account, it MUST revert
Expand Down Expand Up @@ -218,10 +218,10 @@ Smart accounts MAY implement a fallback function that forwards the call to a fal

If the smart account has a fallback handler installed, it:

- MUST implement authorization control
- MUST use `call` to invoke the fallback handler
- MUST use `call` or `staticcall` to invoke the fallback handler
- MUST utilize [ERC-2771](./eip-2771.md) to add the original `msg.sender` to the `calldata` sent to the fallback handler
- MUST route to fallback handlers based on the function selector of the calldata
- MAY implement authorization control, which SHOULD be done via hooks

#### ERC-165

Expand Down Expand Up @@ -305,7 +305,7 @@ Executors MUST implement the `IModule` interface and have module type id: `2`.

Fallback handlers MUST implement the `IModule` interface and have module type id: `3`.

Fallback handlers that implement authorization control, MUST NOT rely on `msg.sender` for authorization control but MUST use ERC-2771 `_msgSender()` instead.
Fallback handlers MAY implement authorization control. Fallback handlers that do implement authorization control, MUST NOT rely on `msg.sender` for authorization control but MUST use ERC-2771 `_msgSender()` instead.

#### Hooks

Expand Down

0 comments on commit f9fdd10

Please sign in to comment.