diff --git a/accounts/safe7579/test/mocks/MockExecutor.sol b/accounts/safe7579/test/mocks/MockExecutor.sol index 38d311c7..99f13092 100644 --- a/accounts/safe7579/test/mocks/MockExecutor.sol +++ b/accounts/safe7579/test/mocks/MockExecutor.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { IExecutor, EncodedModuleTypes } from "erc7579/interfaces/IERC7579Module.sol"; +import { IExecutor } from "erc7579/interfaces/IERC7579Module.sol"; import { IERC7579Account, Execution } from "erc7579/interfaces/IERC7579Account.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; @@ -41,8 +41,6 @@ contract MockExecutor is IExecutor { return typeID == 2; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return false; } diff --git a/accounts/safe7579/test/mocks/MockFallback.sol b/accounts/safe7579/test/mocks/MockFallback.sol index 82dd8aa4..b5ec2fd2 100644 --- a/accounts/safe7579/test/mocks/MockFallback.sol +++ b/accounts/safe7579/test/mocks/MockFallback.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { IFallback, EncodedModuleTypes } from "erc7579/interfaces/IERC7579Module.sol"; +import { IFallback } from "erc7579/interfaces/IERC7579Module.sol"; import { IERC7579Account, Execution } from "erc7579/interfaces/IERC7579Account.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; @@ -25,8 +25,6 @@ contract MockFallback is IFallback, HandlerContext { return typeID == 3; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return false; } diff --git a/accounts/safe7579/test/mocks/MockHook.sol b/accounts/safe7579/test/mocks/MockHook.sol index 47e424e7..87c02555 100644 --- a/accounts/safe7579/test/mocks/MockHook.sol +++ b/accounts/safe7579/test/mocks/MockHook.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { IHook, EncodedModuleTypes } from "erc7579/interfaces/IERC7579Module.sol"; +import { IHook } from "erc7579/interfaces/IERC7579Module.sol"; contract MockHook is IHook { function onInstall(bytes calldata data) external override { } @@ -21,8 +21,6 @@ contract MockHook is IHook { return typeID == 4; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return false; } diff --git a/accounts/safe7579/test/mocks/MockValidator.sol b/accounts/safe7579/test/mocks/MockValidator.sol index 16530216..d9be70ac 100644 --- a/accounts/safe7579/test/mocks/MockValidator.sol +++ b/accounts/safe7579/test/mocks/MockValidator.sol @@ -4,8 +4,7 @@ pragma solidity ^0.8.23; import { IValidator, PackedUserOperation, - VALIDATION_SUCCESS, - EncodedModuleTypes + VALIDATION_SUCCESS } from "erc7579/interfaces/IERC7579Module.sol"; contract MockValidator is IValidator { @@ -41,8 +40,6 @@ contract MockValidator is IValidator { return typeID == 1; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return false; } diff --git a/examples/src/ColdStorage-SubAccount/ColdStorageExecutor.sol b/examples/src/ColdStorage-SubAccount/ColdStorageExecutor.sol index a6b9d3fd..5b8b1cf4 100644 --- a/examples/src/ColdStorage-SubAccount/ColdStorageExecutor.sol +++ b/examples/src/ColdStorage-SubAccount/ColdStorageExecutor.sol @@ -5,7 +5,6 @@ import { IERC7579Account } from "@rhinestone/modulekit/src/Accounts.sol"; import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract ColdStorageExecutor is ERC7579ExecutorBase { error UnauthorizedAccess(); @@ -33,8 +32,6 @@ contract ColdStorageExecutor is ERC7579ExecutorBase { return typeID == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return _subAccountOwner[smartAccount] != address(0); } diff --git a/examples/src/ColdStorage-SubAccount/ColdStorageHook.sol b/examples/src/ColdStorage-SubAccount/ColdStorageHook.sol index 27f8a0e1..109d3d9e 100644 --- a/examples/src/ColdStorage-SubAccount/ColdStorageHook.sol +++ b/examples/src/ColdStorage-SubAccount/ColdStorageHook.sol @@ -8,7 +8,6 @@ import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { EnumerableMap } from "@openzeppelin/contracts/utils/structs/EnumerableMap.sol"; import { ERC7579HookDestruct } from "@rhinestone/modulekit/src/modules/ERC7579HookDestruct.sol"; import { Execution } from "@rhinestone/modulekit/src/Accounts.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract ColdStorageHook is ERC7579HookDestruct { error UnsupportedExecution(); @@ -210,7 +209,8 @@ contract ColdStorageHook is ERC7579HookDestruct { if (target == address(this) && functionSig == this.requestTimelockedExecution.selector) { return abi.encode(this.requestTimelockedExecution.selector); } else { - bytes32 executionHash = _execDigestMemory(target, value, callData); + bytes32 executionHash = + _execDigestMemory(target, value, callData[0:callData.length - 8]); (bool success, bytes32 entry) = executions[msg.sender].tryGet(executionHash); if (!success) revert InvalidExecutionHash(executionHash); @@ -280,7 +280,5 @@ contract ColdStorageHook is ERC7579HookDestruct { return isType == TYPE_HOOK; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } } diff --git a/examples/src/ColdStorage-SubAccount/FlashloanCallback.sol b/examples/src/ColdStorage-SubAccount/FlashloanCallback.sol index 11c8eb59..d5d79382 100644 --- a/examples/src/ColdStorage-SubAccount/FlashloanCallback.sol +++ b/examples/src/ColdStorage-SubAccount/FlashloanCallback.sol @@ -5,7 +5,6 @@ import { IFallbackMethod } from "@rhinestone/modulekit/src/core/ExtensibleFallba import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; import "./interfaces/Flashloan.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract FlashloanCallback is IFallbackMethod, ERC7579ExecutorBase { address immutable FALLBACK_HANDLER; @@ -90,7 +89,5 @@ contract FlashloanCallback is IFallbackMethod, ERC7579ExecutorBase { return isType == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } } diff --git a/examples/src/ColdStorage-SubAccount/FlashloanLender.sol b/examples/src/ColdStorage-SubAccount/FlashloanLender.sol index f9363acc..a7da4aab 100644 --- a/examples/src/ColdStorage-SubAccount/FlashloanLender.sol +++ b/examples/src/ColdStorage-SubAccount/FlashloanLender.sol @@ -4,7 +4,6 @@ import "forge-std/interfaces/IERC721.sol"; import { IFallbackMethod } from "@rhinestone/modulekit/src/core/ExtensibleFallbackHandler.sol"; import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; import "./interfaces/Flashloan.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; pragma solidity ^0.8.20; @@ -183,7 +182,5 @@ contract FlashloanLender is IFallbackMethod, ERC7579ExecutorBase { return isType == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } } diff --git a/examples/src/DollarCostAverage/DollarCostAverage.sol b/examples/src/DollarCostAverage/DollarCostAverage.sol index 1815cd2b..a5fc7888 100644 --- a/examples/src/DollarCostAverage/DollarCostAverage.sol +++ b/examples/src/DollarCostAverage/DollarCostAverage.sol @@ -1,16 +1,14 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { UniswapV3Integration } from "@rhinestone/modulekit/src/integrations/uniswap/v3/Uniswap.sol"; import { Execution, IERC7579Account } from "@rhinestone/modulekit/src/Accounts.sol"; -import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; +import { ERC7579ExecutorBase, SessionKeyBase } from "@rhinestone/modulekit/src/Modules.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; -contract DollarCostAverage is ERC7579ExecutorBase, ISessionValidationModule { +contract DollarCostAverage is ERC7579ExecutorBase, SessionKeyBase { struct ScopedAccess { address sessionKeySigner; address onlyTokenIn; @@ -29,11 +27,6 @@ contract DollarCostAverage is ERC7579ExecutorBase, ISessionValidationModule { uint128 amount; } - error InvalidMethod(bytes4); - error InvalidValue(); - error InvalidAmount(); - error InvalidTarget(); - error InvalidRecipient(); error InvalidParams(); mapping(address account => mapping(address token => SpentLog)) internal _log; @@ -91,21 +84,6 @@ contract DollarCostAverage is ERC7579ExecutorBase, ISessionValidationModule { function onUninstall(bytes calldata data) external override { } - modifier onlyThis(address destinationContract) { - if (destinationContract != address(this)) revert InvalidTarget(); - _; - } - - modifier onlyFunctionSig(bytes4 allowed, bytes4 received) { - if (allowed != received) revert InvalidMethod(received); - _; - } - - modifier onlyZeroValue(uint256 callValue) { - if (callValue != 0) revert InvalidValue(); - _; - } - function encode(ScopedAccess memory transaction) public pure returns (bytes memory) { return abi.encode(transaction); } @@ -118,8 +96,6 @@ contract DollarCostAverage is ERC7579ExecutorBase, ISessionValidationModule { return typeID == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } function name() external pure virtual returns (string memory) { diff --git a/examples/src/SmartActions/ScheduledOrders.sol b/examples/src/SmartActions/ScheduledOrders.sol index 16e078ce..3310da84 100644 --- a/examples/src/SmartActions/ScheduledOrders.sol +++ b/examples/src/SmartActions/ScheduledOrders.sol @@ -8,7 +8,7 @@ import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; -abstract contract ScheduledOrders is SchedulingBase { +contract ScheduledOrders is SchedulingBase { function executeOrder(uint256 jobId) external override canExecute(jobId) { ExecutionConfig storage executionConfig = _executionLog[msg.sender][jobId]; diff --git a/examples/src/SmartActions/ScheduledTransfers.sol b/examples/src/SmartActions/ScheduledTransfers.sol index 7cd8fabf..40b8f8f4 100644 --- a/examples/src/SmartActions/ScheduledTransfers.sol +++ b/examples/src/SmartActions/ScheduledTransfers.sol @@ -6,7 +6,7 @@ import { SchedulingBase } from "./SchedulingBase.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; -abstract contract ScheduledTransfers is SchedulingBase { +contract ScheduledTransfers is SchedulingBase { function executeOrder(uint256 jobId) external override canExecute(jobId) { ExecutionConfig storage executionConfig = _executionLog[msg.sender][jobId]; diff --git a/examples/src/SmartActions/SchedulingBase.sol b/examples/src/SmartActions/SchedulingBase.sol index 95eafcc7..22c2cc31 100644 --- a/examples/src/SmartActions/SchedulingBase.sol +++ b/examples/src/SmartActions/SchedulingBase.sol @@ -3,27 +3,17 @@ pragma solidity ^0.8.23; import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { IERC7579Account } from "@rhinestone/modulekit/src/Accounts.sol"; -import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; -import { EncodedModuleTypes } from "erc7579/lib/ModuleTypeLib.sol"; +import { ERC7579ExecutorBase, SessionKeyBase } from "@rhinestone/modulekit/src/Modules.sol"; -abstract contract SchedulingBase is ERC7579ExecutorBase, ISessionValidationModule { +abstract contract SchedulingBase is ERC7579ExecutorBase, SessionKeyBase { error InvalidExecution(); - error InvalidMethod(bytes4); - error InvalidValue(); - error InvalidAmount(); - error InvalidTarget(); - error InvalidRecipient(); - error InvalidInstall(); - error InvalidJob(); event ExecutionAdded(address indexed smartAccount, uint256 indexed jobId); - event ExecutionTriggered(address indexed smartAccount, uint256 indexed jobId); - event ExecutionStatusUpdated(address indexed smartAccount, uint256 indexed jobId); + event ExecutionsCancelled(address indexed smartAccount); mapping(address smartAccount => mapping(uint256 jobId => ExecutionConfig)) internal _executionLog; @@ -140,7 +130,12 @@ abstract contract SchedulingBase is ERC7579ExecutorBase, ISessionValidationModul revert InvalidInstall(); } - ExecutionConfig memory executionConfig = abi.decode(data, (ExecutionConfig)); + ( + uint48 executeInterval, + uint16 numberOfExecutions, + uint48 startDate, + bytes memory executionData + ) = abi.decode(data, (uint48, uint16, uint48, bytes)); uint256 jobId = _accountJobCount[msg.sender] + 1; _accountJobCount[msg.sender]++; @@ -149,11 +144,13 @@ abstract contract SchedulingBase is ERC7579ExecutorBase, ISessionValidationModul numberOfExecutionsCompleted: 0, isEnabled: true, lastExecutionTime: 0, - executeInterval: executionConfig.executeInterval, - numberOfExecutions: executionConfig.numberOfExecutions, - startDate: executionConfig.startDate, - executionData: executionConfig.executionData + executeInterval: executeInterval, + numberOfExecutions: numberOfExecutions, + startDate: startDate, + executionData: executionData }); + + emit ExecutionAdded(msg.sender, jobId); } function getAccountJobDetails( @@ -167,20 +164,24 @@ abstract contract SchedulingBase is ERC7579ExecutorBase, ISessionValidationModul return _executionLog[smartAccount][jobId]; } - function onUninstall() external { + function getAccountJobCount(address smartAccount) external view returns (uint256) { + return _accountJobCount[smartAccount]; + } + + function onUninstall(bytes calldata) external { uint256 count = _accountJobCount[msg.sender]; for (uint256 i = 1; i <= count; i++) { delete _executionLog[msg.sender][i]; } _accountJobCount[msg.sender] = 0; + + emit ExecutionsCancelled(msg.sender); } function isModuleType(uint256 typeID) external pure override returns (bool) { return typeID == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return _accountJobCount[smartAccount] != 0; } diff --git a/examples/src/AutoSaving/AutoSavings.sol b/examples/src/auto-savings/AutoSavings.sol similarity index 94% rename from examples/src/AutoSaving/AutoSavings.sol rename to examples/src/auto-savings/AutoSavings.sol index d9584ade..19c2e45e 100644 --- a/examples/src/AutoSaving/AutoSavings.sol +++ b/examples/src/auto-savings/AutoSavings.sol @@ -1,16 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { - ERC20Integration, - ERC4626Integration, - UniswapV3Integration -} from "@rhinestone/modulekit/src/Integrations.sol"; +import { ERC20Integration, ERC4626Integration } from "@rhinestone/modulekit/src/Integrations.sol"; import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { IERC4626 } from "forge-std/interfaces/IERC4626.sol"; +import { UniswapV3Integration } from "@rhinestone/modulekit/src/Integrations.sol"; import { Execution } from "@rhinestone/modulekit/src/Accounts.sol"; import { ERC7579ExecutorBase, SessionKeyBase } from "@rhinestone/modulekit/src/Modules.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; import "forge-std/console2.sol"; @@ -141,8 +137,6 @@ contract AutoSavingToVault is ERC7579ExecutorBase, SessionKeyBase { return typeID == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } function name() external pure virtual returns (string memory) { diff --git a/examples/src/DeadManSwitch/DeadmanSwitch.sol b/examples/src/deadman-switch/DeadmanSwitch.sol similarity index 94% rename from examples/src/DeadManSwitch/DeadmanSwitch.sol rename to examples/src/deadman-switch/DeadmanSwitch.sol index dcbaf7a1..0eeee9b2 100644 --- a/examples/src/DeadManSwitch/DeadmanSwitch.sol +++ b/examples/src/deadman-switch/DeadmanSwitch.sol @@ -5,7 +5,6 @@ import { ERC7579ValidatorBase, ERC7579HookBase } from "@rhinestone/modulekit/src import { PackedUserOperation } from "@rhinestone/modulekit/src/ModuleKit.sol"; import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { ECDSA } from "solady/src/utils/ECDSA.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract DeadmanSwitch is ERC7579HookBase, ERC7579ValidatorBase { using SignatureCheckerLib for address; @@ -52,8 +51,6 @@ contract DeadmanSwitch is ERC7579HookBase, ERC7579ValidatorBase { return typeID == TYPE_HOOK; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } function preCheck(address, bytes calldata) external returns (bytes memory) { diff --git a/examples/src/erc1271-prehash/ERC1271PrehashValidator.sol b/examples/src/erc1271-prehash/ERC1271PrehashValidator.sol new file mode 100644 index 00000000..6f505ce9 --- /dev/null +++ b/examples/src/erc1271-prehash/ERC1271PrehashValidator.sol @@ -0,0 +1,81 @@ +// SPDX-License-Identifier: MIT + +pragma solidity ^0.8.19; + +import { ERC7579ValidatorBase } from "@rhinestone/modulekit/src/modules/ERC7579ValidatorBase.sol"; +import { EnumerableSet } from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; +import { PackedUserOperation } from "@rhinestone/modulekit/src/external/ERC4337.sol"; + +contract ERC1271PrehashValidator is ERC7579ValidatorBase { + using EnumerableSet for EnumerableSet.Bytes32Set; + + mapping(address account => EnumerableSet.Bytes32Set) internal _validHashes; + + function addHash(bytes32 _hash) external { + _validHashes[msg.sender].add(_hash); + } + + function removeHash(bytes32 _hash) external { + _validHashes[msg.sender].remove(_hash); + } + + function isHash(address account, bytes32 _hash) public view returns (bool) { + return _validHashes[account].contains(_hash); + } + + function validateUserOp( + PackedUserOperation calldata userOp, + bytes32 userOpHash + ) + external + virtual + override + returns (ValidationData) + { + return VALIDATION_FAILED; + } + + function isValidSignatureWithSender( + address sender, + bytes32 hash, + bytes calldata data + ) + external + view + virtual + override + returns (bytes4) + { + if (keccak256(data) != hash) return EIP1271_FAILED; + if (isHash(sender, hash)) { + return EIP1271_SUCCESS; + } else { + return EIP1271_FAILED; + } + } + + function version() external pure virtual returns (string memory) { + return "1.0.0"; + } + + function name() external pure virtual returns (string memory) { + return "ERC1271PrehashValidator"; + } + + function isModuleType(uint256 isType) external pure virtual override returns (bool) { + return isType == TYPE_VALIDATOR; + } + + function isInitialized(address smartAccount) external view returns (bool) { } + + function onInstall(bytes calldata data) external override { + if (data.length == 0) return; + + bytes32[] memory hashes = abi.decode(data, (bytes32[])); + for (uint256 i; i < hashes.length; i++) { + _validHashes[msg.sender].add(hashes[i]); + } + } + + function onUninstall(bytes calldata data) external override { } +} diff --git a/examples/src/AutoSend/AutoSend.sol b/examples/src/erc20-autosend/AutoSend.sol similarity index 86% rename from examples/src/AutoSend/AutoSend.sol rename to examples/src/erc20-autosend/AutoSend.sol index add0051c..a517bd4f 100644 --- a/examples/src/AutoSend/AutoSend.sol +++ b/examples/src/erc20-autosend/AutoSend.sol @@ -1,15 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { IERC7579Account } from "@rhinestone/modulekit/src/Accounts.sol"; -import { ERC7579ExecutorBase } from "@rhinestone/modulekit/src/Modules.sol"; +import { ERC7579ExecutorBase, SessionKeyBase } from "@rhinestone/modulekit/src/Modules.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; -contract AutoSendSessionKey is ERC7579ExecutorBase, ISessionValidationModule { +contract AutoSendSessionKey is ERC7579ExecutorBase, SessionKeyBase { struct ExecutorAccess { address sessionKeySigner; address token; @@ -27,12 +25,6 @@ contract AutoSendSessionKey is ERC7579ExecutorBase, ISessionValidationModule { uint128 amount; } - error InvalidMethod(bytes4); - error InvalidValue(); - error InvalidAmount(); - error InvalidTarget(); - error InvalidRecipient(); - mapping(address account => mapping(address token => SpentLog)) internal _log; function encode(ExecutorAccess memory transaction) public pure returns (bytes memory) { @@ -115,8 +107,6 @@ contract AutoSendSessionKey is ERC7579ExecutorBase, ISessionValidationModule { return typeID == TYPE_EXECUTOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } function name() external pure virtual returns (string memory) { diff --git a/examples/src/MultiFactorValidator/ECDSAFactor.sol b/examples/src/mfa/ECDSAFactor.sol similarity index 100% rename from examples/src/MultiFactorValidator/ECDSAFactor.sol rename to examples/src/mfa/ECDSAFactor.sol diff --git a/examples/src/MultiFactorValidator/MultiFactor.sol b/examples/src/mfa/MultiFactor.sol similarity index 98% rename from examples/src/MultiFactorValidator/MultiFactor.sol rename to examples/src/mfa/MultiFactor.sol index 049102dc..2814f24e 100644 --- a/examples/src/MultiFactorValidator/MultiFactor.sol +++ b/examples/src/mfa/MultiFactor.sol @@ -7,7 +7,6 @@ import { IERC7579Account, Execution } from "@rhinestone/modulekit/src/Accounts.s import { PackedUserOperation } from "@rhinestone/modulekit/src/external/ERC4337.sol"; import { LibSort } from "solady/src/utils/LibSort.sol"; import { ECDSAFactor } from "./ECDSAFactor.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; import { ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; import { ModeLib } from "erc7579/lib/ModeLib.sol"; @@ -313,8 +312,8 @@ contract MultiFactor is ERC7579ValidatorBase, ECDSAFactor { function onInstall(bytes calldata data) external { // check if module is already initialized - if (multiFactorConfig[msg.sender].threshold != 0) revert("Already Initialized"); if (data.length == 0) return; + if (multiFactorConfig[msg.sender].threshold != 0) revert("Already Initialized"); // TODO: slice this with packed / calldata ( @@ -364,8 +363,6 @@ contract MultiFactor is ERC7579ValidatorBase, ECDSAFactor { return "0.0.1"; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { return multiFactorConfig[msg.sender].threshold != 0; } diff --git a/examples/src/OwnableValidator/OwnableValidator.sol b/examples/src/ownable-validator/OwnableValidator.sol similarity index 88% rename from examples/src/OwnableValidator/OwnableValidator.sol rename to examples/src/ownable-validator/OwnableValidator.sol index 598b3611..c64ad3f0 100644 --- a/examples/src/OwnableValidator/OwnableValidator.sol +++ b/examples/src/ownable-validator/OwnableValidator.sol @@ -6,7 +6,6 @@ import { PackedUserOperation } from "@rhinestone/modulekit/src/external/ERC4337. import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { ECDSA } from "solady/src/utils/ECDSA.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract OwnableValidator is ERC7579ValidatorBase { using SignatureCheckerLib for address; @@ -49,7 +48,9 @@ contract OwnableValidator is ERC7579ValidatorBase { returns (bytes4) { address owner = owners[msg.sender]; - return SignatureCheckerLib.isValidSignatureNowCalldata(owner, hash, data) + address recover = ECDSA.recover(hash, data); + bool valid = SignatureCheckerLib.isValidSignatureNow(owner, hash, data); + return SignatureCheckerLib.isValidSignatureNow(owner, hash, data) ? EIP1271_SUCCESS : EIP1271_FAILED; } @@ -66,7 +67,5 @@ contract OwnableValidator is ERC7579ValidatorBase { return typeID == TYPE_VALIDATOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } } diff --git a/examples/src/TokenRevocation/ERC20Revocation.sol b/examples/src/token-revocation/ERC20Revocation.sol similarity index 70% rename from examples/src/TokenRevocation/ERC20Revocation.sol rename to examples/src/token-revocation/ERC20Revocation.sol index 2494ba1e..d0d910ae 100644 --- a/examples/src/TokenRevocation/ERC20Revocation.sol +++ b/examples/src/token-revocation/ERC20Revocation.sol @@ -1,12 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { ISessionValidationModule } from - "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; +import { SessionKeyBase } from "@rhinestone/modulekit/src/Modules.sol"; import { IERC20 } from "forge-std/interfaces/IERC20.sol"; import { IERC721 } from "forge-std/interfaces/IERC721.sol"; -contract ERC20Revocation is ISessionValidationModule { +contract ERC20Revocation is SessionKeyBase { enum TokenType { ERC20, ERC721 @@ -18,9 +17,6 @@ contract ERC20Revocation is ISessionValidationModule { address sessionKeySigner; } - error InvalidMethod(bytes4); - error InvalidValue(); - error InvalidAmount(); error InvalidToken(); error NotZero(); @@ -29,22 +25,20 @@ contract ERC20Revocation is ISessionValidationModule { } function validateSessionParams( - address destinationContract, - uint256 callValue, + address to, + uint256 value, bytes calldata callData, - bytes calldata _sessionKeyData, + bytes calldata sessionKeyData, bytes calldata /*_callSpecificData*/ ) external - virtual - override returns (address) { - Token memory transaction = abi.decode(_sessionKeyData, (Token)); + Token memory transaction = abi.decode(sessionKeyData, (Token)); bytes4 targetSelector = bytes4(callData[:4]); - if (transaction.token != destinationContract) revert InvalidToken(); - if (callValue != 0) revert InvalidValue(); + if (transaction.token != to) revert InvalidToken(); + if (value != 0) revert InvalidValue(); if (transaction.tokenType == TokenType.ERC20) { _validateERC20(targetSelector, callData); } else if (transaction.tokenType == TokenType.ERC721) { @@ -80,4 +74,22 @@ contract ERC20Revocation is ISessionValidationModule { revert InvalidMethod(targetSelector); } } + + function onInstall(bytes calldata data) external { } + + function onUninstall(bytes calldata data) external { } + + function isModuleType(uint256 typeID) external pure override returns (bool) { + return typeID == TYPE_EXECUTOR; + } + + function isInitialized(address smartAccount) external view returns (bool) { } + + function name() external pure virtual returns (string memory) { + return "AutoSaving"; + } + + function version() external pure virtual returns (string memory) { + return "0.0.1"; + } } diff --git a/examples/src/WebauthnValidator/WebauthnValidator.sol b/examples/src/webauthn-validator/WebauthnValidator.sol similarity index 90% rename from examples/src/WebauthnValidator/WebauthnValidator.sol rename to examples/src/webauthn-validator/WebauthnValidator.sol index 031894ae..d26c67e3 100644 --- a/examples/src/WebauthnValidator/WebauthnValidator.sol +++ b/examples/src/webauthn-validator/WebauthnValidator.sol @@ -1,12 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity >=0.8.19; -import { WebAuthnLib } from "./utils/WebAuthNLib.sol"; +import { WebAuthnLib } from "./utils/WebAuthnLib.sol"; import { ERC7579ValidatorBase } from "@rhinestone/modulekit/src/Modules.sol"; import { PackedUserOperation, UserOperationLib } from "@rhinestone/modulekit/src/external/ERC4337.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; struct PassKeyId { uint256 pubKeyX; @@ -59,7 +58,7 @@ contract WebAuthnValidator is ERC7579ValidatorBase { ) = abi.decode(userOp.signature, (bytes32, bytes, bytes1, bytes, uint256, uint256[2])); PassKeyId memory passKey = smartAccountPassKeys[userOp.getSender()]; - require(passKey.pubKeyY != 0 && passKey.pubKeyY != 0, "Key not found"); + require(passKey.pubKeyX != 0 && passKey.pubKeyY != 0, "Key not found"); uint256[2] memory Q = [passKey.pubKeyX, passKey.pubKeyY]; bool isValidSignature = WebAuthnLib.checkSignature( authenticatorData, @@ -100,7 +99,5 @@ contract WebAuthnValidator is ERC7579ValidatorBase { return typeID == TYPE_VALIDATOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view returns (bool) { } } diff --git a/examples/src/WebauthnValidator/utils/Base64URL.sol b/examples/src/webauthn-validator/utils/Base64URL.sol similarity index 100% rename from examples/src/WebauthnValidator/utils/Base64URL.sol rename to examples/src/webauthn-validator/utils/Base64URL.sol diff --git a/examples/src/WebauthnValidator/utils/EllipticCurve.sol b/examples/src/webauthn-validator/utils/EllipticCurve.sol similarity index 100% rename from examples/src/WebauthnValidator/utils/EllipticCurve.sol rename to examples/src/webauthn-validator/utils/EllipticCurve.sol diff --git a/examples/src/WebauthnValidator/utils/WebAuthNLib.sol b/examples/src/webauthn-validator/utils/WebAuthNLib.sol similarity index 100% rename from examples/src/WebauthnValidator/utils/WebAuthNLib.sol rename to examples/src/webauthn-validator/utils/WebAuthNLib.sol diff --git a/examples/test/AutoSaving/AutoSavings.t.sol b/examples/test/auto-savings/AutoSavings.t.sol similarity index 95% rename from examples/test/AutoSaving/AutoSavings.t.sol rename to examples/test/auto-savings/AutoSavings.t.sol index 8a11e14e..6419e518 100644 --- a/examples/test/AutoSaving/AutoSavings.t.sol +++ b/examples/test/auto-savings/AutoSavings.t.sol @@ -7,12 +7,9 @@ import "@rhinestone/modulekit/src/Helpers.sol"; import "@rhinestone/modulekit/src/Core.sol"; import "solmate/test/utils/mocks/MockERC20.sol"; import "solmate/test/utils/mocks/MockERC4626.sol"; -import { AutoSavingToVault } from "src/AutoSaving/AutoSavings.sol"; +import { AutoSavingToVault } from "src/auto-savings/AutoSavings.sol"; -import { - MODULE_TYPE_VALIDATOR, - MODULE_TYPE_EXECUTOR -} from "@rhinestone/modulekit/src/external/ERC7579.sol"; +import { MODULE_TYPE_EXECUTOR } from "@rhinestone/modulekit/src/external/ERC7579.sol"; import "forge-std/console2.sol"; diff --git a/examples/test/AutoSaving/AutoSavings.tree b/examples/test/auto-savings/AutoSavings.tree similarity index 100% rename from examples/test/AutoSaving/AutoSavings.tree rename to examples/test/auto-savings/AutoSavings.tree diff --git a/examples/test/coldstorage/ColdStorage.t.sol b/examples/test/coldstorage/ColdStorage.t.sol index 21ae0877..734883a5 100644 --- a/examples/test/coldstorage/ColdStorage.t.sol +++ b/examples/test/coldstorage/ColdStorage.t.sol @@ -6,25 +6,20 @@ import "@rhinestone/modulekit/src/ModuleKit.sol"; import "@rhinestone/modulekit/src/Modules.sol"; import "@rhinestone/modulekit/src/Helpers.sol"; import "@rhinestone/modulekit/src/core/ExtensibleFallbackHandler.sol"; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; -import { - SessionData, - SessionKeyManagerLib -} from "@rhinestone/sessionkeymanager/src/SessionKeyManagerLib.sol"; import "@rhinestone/modulekit/src/Mocks.sol"; import { Solarray } from "solarray/Solarray.sol"; import { ECDSA } from "solady/src/utils/ECDSA.sol"; import { IERC7579Account, Execution } from "@rhinestone/modulekit/src/Accounts.sol"; -import { FlashloanCallback } from "src/ColdStorage-SubAccount/FlashloanCallback.sol"; -import { FlashloanLender } from "src/ColdStorage-SubAccount/FlashloanLender.sol"; -import { ColdStorageHook } from "src/ColdStorage-SubAccount/ColdStorageHook.sol"; -import { ColdStorageExecutor } from "src/ColdStorage-SubAccount/ColdStorageExecutor.sol"; -import { OwnableValidator } from "src/OwnableValidator/OwnableValidator.sol"; +import { FlashloanCallback } from "src/coldstorage-subaccount/FlashloanCallback.sol"; +import { FlashloanLender } from "src/coldstorage-subaccount/FlashloanLender.sol"; +import { ColdStorageHook } from "src/coldstorage-subaccount/ColdStorageHook.sol"; +import { ColdStorageExecutor } from "src/coldstorage-subaccount/ColdStorageExecutor.sol"; +import { OwnableValidator } from "src/ownable-validator/OwnableValidator.sol"; import { ERC7579BootstrapConfig } from "@rhinestone/modulekit/src/external/ERC7579.sol"; -import "src/ColdStorage-SubAccount/interfaces/Flashloan.sol"; +import "src/coldstorage-subaccount/interfaces/Flashloan.sol"; import "erc7579/lib/ExecutionLib.sol"; contract ColdStorageTest is RhinestoneModuleKit, Test { @@ -244,8 +239,6 @@ contract ColdStorageTest is RhinestoneModuleKit, Test { MockERC20.transfer.selector, address(mainAccount.account), amountToWithdraw ) }); - console2.log("token:", address(token)); - console2.logBytes(action.callData); _requestWithdraw(action, 0); @@ -310,6 +303,6 @@ contract ColdStorageTest is RhinestoneModuleKit, Test { _execWithdraw(action); uint256 newBalance = target.balance; - assertTrue(newBalance > prevBalance); + assertEq(newBalance, prevBalance + amountToWithdraw); } } diff --git a/examples/test/deadman-switch/DeadmanSwitch.t.sol b/examples/test/deadman-switch/DeadmanSwitch.t.sol index cc59f479..2184e068 100644 --- a/examples/test/deadman-switch/DeadmanSwitch.t.sol +++ b/examples/test/deadman-switch/DeadmanSwitch.t.sol @@ -6,17 +6,12 @@ import "@rhinestone/modulekit/src/ModuleKit.sol"; import "@rhinestone/modulekit/src/Helpers.sol"; import "@rhinestone/modulekit/src/Core.sol"; import "solmate/test/utils/mocks/MockERC20.sol"; +import { MODULE_TYPE_VALIDATOR, MODULE_TYPE_HOOK } from "@rhinestone/modulekit/src/external/ERC7579.sol"; -import "src/DeadManSwitch/DeadmanSwitch.sol"; +import "src/deadman-switch/DeadmanSwitch.sol"; import "forge-std/interfaces/IERC20.sol"; import { ECDSA } from "solady/src/utils/ECDSA.sol"; -import { - MODULE_TYPE_VALIDATOR, - MODULE_TYPE_EXECUTOR, - MODULE_TYPE_HOOK -} from "@rhinestone/modulekit/src/external/ERC7579.sol"; - contract DeadmanSwitchTest is RhinestoneModuleKit, Test { using ModuleKitHelpers for *; using ModuleKitUserOp for *; @@ -41,8 +36,12 @@ contract DeadmanSwitchTest is RhinestoneModuleKit, Test { timeout = uint48(block.timestamp + 128 days); bytes memory initData = abi.encode(nominee.addr, timeout); - instance.installModule(MODULE_TYPE_VALIDATOR, address(dms), initData); - instance.installModule(MODULE_TYPE_HOOK, address(dms), ""); + instance.installModule({ + moduleTypeId: MODULE_TYPE_VALIDATOR, + module: address(dms), + data: initData + }); + instance.installModule({ moduleTypeId: MODULE_TYPE_HOOK, module: address(dms), data: "" }); } function test_ShouldNeverRevertHook() external { diff --git a/examples/test/erc20-autosend/AutoSend.t.sol b/examples/test/erc20-autosend/AutoSend.t.sol index 2c33b0b8..df177c7a 100644 --- a/examples/test/erc20-autosend/AutoSend.t.sol +++ b/examples/test/erc20-autosend/AutoSend.t.sol @@ -5,21 +5,11 @@ import "forge-std/Test.sol"; import "forge-std/console2.sol"; import "@rhinestone/modulekit/src/ModuleKit.sol"; import "@rhinestone/modulekit/src/Modules.sol"; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; -import { - SessionData, - SessionKeyManagerLib -} from "@rhinestone/sessionkeymanager/src/SessionKeyManagerLib.sol"; import "@rhinestone/modulekit/src/Mocks.sol"; -import { AutoSendSessionKey } from "src/AutoSend/AutoSend.sol"; +import { AutoSendSessionKey } from "src/erc20-autosend/AutoSend.sol"; import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { Solarray } from "solarray/Solarray.sol"; - -import { - MODULE_TYPE_VALIDATOR, - MODULE_TYPE_EXECUTOR, - MODULE_TYPE_HOOK -} from "@rhinestone/modulekit/src/external/ERC7579.sol"; +import { MODULE_TYPE_EXECUTOR } from "@rhinestone/modulekit/src/external/ERC7579.sol"; contract AutoSendTest is RhinestoneModuleKit, Test { using ModuleKitHelpers for *; @@ -71,9 +61,11 @@ contract AutoSendTest is RhinestoneModuleKit, Test { AutoSendSessionKey.SpentLog[] memory logs = new AutoSendSessionKey.SpentLog[](1); logs[0] = AutoSendSessionKey.SpentLog({ spent: 0, maxAmount: 100 }); - instance.installModule( - MODULE_TYPE_EXECUTOR, address(sessionValidator), abi.encode(tokens, logs) - ); + instance.installModule({ + moduleTypeId: MODULE_TYPE_EXECUTOR, + module: address(sessionValidator), + data: abi.encode(tokens, logs) + }); } function test_transferBatch() public { diff --git a/examples/test/execution-automation/Auto-Execution.t.sol b/examples/test/execution-automation/Auto-Execution.t.sol new file mode 100644 index 00000000..8b137891 --- /dev/null +++ b/examples/test/execution-automation/Auto-Execution.t.sol @@ -0,0 +1 @@ + diff --git a/examples/test/mfa/MultiFactor.t.sol b/examples/test/mfa/MultiFactor.t.sol index 29571757..9ac65edc 100644 --- a/examples/test/mfa/MultiFactor.t.sol +++ b/examples/test/mfa/MultiFactor.t.sol @@ -7,16 +7,12 @@ import "@rhinestone/modulekit/src/ModuleKit.sol"; import "@rhinestone/modulekit/src/Modules.sol"; import "@rhinestone/modulekit/src/Mocks.sol"; -import { MultiFactor, ECDSAFactor } from "src/MultiFactorValidator/MultiFactor.sol"; +import { MultiFactor, ECDSAFactor } from "src/mfa/MultiFactor.sol"; import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { ECDSA } from "solady/src/utils/ECDSA.sol"; import { Solarray } from "solarray/Solarray.sol"; -import { - MODULE_TYPE_VALIDATOR, - MODULE_TYPE_EXECUTOR, - MODULE_TYPE_HOOK -} from "@rhinestone/modulekit/src/external/ERC7579.sol"; +import { MODULE_TYPE_VALIDATOR, MODULE_TYPE_EXECUTOR } from "@rhinestone/modulekit/src/external/ERC7579.sol"; contract DemoValidator is MockValidator { mapping(address account => bool isInitialized) public initialized; @@ -77,8 +73,12 @@ contract MultiFactorTest is RhinestoneModuleKit, Test { } function initAccount() internal { - instance.installModule(MODULE_TYPE_VALIDATOR, address(mfa), ""); - instance.installModule(MODULE_TYPE_EXECUTOR, address(mfa), ""); + instance.installModule({ + moduleTypeId: MODULE_TYPE_VALIDATOR, + module: address(mfa), + data: "" + }); + instance.installModule({ moduleTypeId: MODULE_TYPE_EXECUTOR, module: address(mfa), data: "" }); configMFA(); } @@ -116,8 +116,12 @@ contract MultiFactorTest is RhinestoneModuleKit, Test { } function init_localECDSA() public { - instance.installModule(MODULE_TYPE_VALIDATOR, address(mfa), ""); - instance.installModule(MODULE_TYPE_EXECUTOR, address(mfa), ""); + instance.installModule({ + moduleTypeId: MODULE_TYPE_VALIDATOR, + module: address(mfa), + data: "" + }); + instance.installModule({ moduleTypeId: MODULE_TYPE_EXECUTOR, module: address(mfa), data: "" }); address[] memory validators = Solarray.addresses(address(mfa), address(validator2)); ECDSAFactor.FactorConfig memory conf = ECDSAFactor.FactorConfig({ signer: signer.addr, diff --git a/examples/test/token-revocation/ERC20Revocation.t.sol b/examples/test/token-revocation/ERC20Revocation.t.sol index fe1ca582..bb1921f1 100644 --- a/examples/test/token-revocation/ERC20Revocation.t.sol +++ b/examples/test/token-revocation/ERC20Revocation.t.sol @@ -5,13 +5,8 @@ import "forge-std/Test.sol"; import "forge-std/console2.sol"; import "@rhinestone/modulekit/src/ModuleKit.sol"; import "@rhinestone/modulekit/src/Modules.sol"; -import "@rhinestone/sessionkeymanager/src/ISessionValidationModule.sol"; -import { - SessionData, - SessionKeyManagerLib -} from "@rhinestone/sessionkeymanager/src/SessionKeyManagerLib.sol"; import "@rhinestone/modulekit/src/Mocks.sol"; -import { ERC20Revocation } from "src/TokenRevocation/ERC20Revocation.sol"; +import { ERC20Revocation } from "src/token-revocation/ERC20Revocation.sol"; import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { Solarray } from "solarray/Solarray.sol"; diff --git a/packages/SessionKeyManager/src/SessionKeyManager.sol b/packages/SessionKeyManager/src/SessionKeyManager.sol index b7619884..44b20b90 100644 --- a/packages/SessionKeyManager/src/SessionKeyManager.sol +++ b/packages/SessionKeyManager/src/SessionKeyManager.sol @@ -16,7 +16,6 @@ import { ISessionValidationModule } from "./ISessionValidationModule.sol"; import { SessionData, SessionKeyManagerLib } from "./SessionKeyManagerLib.sol"; import { SignatureCheckerLib } from "solady/src/utils/SignatureCheckerLib.sol"; import { Execution } from "erc7579/interfaces/IERC7579Account.sol"; -import { EncodedModuleTypes } from "erc7579/lib/ModuleTypeLib.sol"; contract SessionKeyManager is ERC7579ValidatorBase { using UserOperationLib for PackedUserOperation; @@ -218,7 +217,5 @@ contract SessionKeyManager is ERC7579ValidatorBase { function onUninstall(bytes calldata data) external override { } - function getModuleTypes() external view override returns (EncodedModuleTypes) { } - function isInitialized(address smartAccount) external view override returns (bool) { } } diff --git a/packages/modulekit/gas_calculations/testWriteGas.json b/packages/modulekit/gas_calculations/testWriteGas.json index 23bc85df..6fd303a5 100644 --- a/packages/modulekit/gas_calculations/testWriteGas.json +++ b/packages/modulekit/gas_calculations/testWriteGas.json @@ -4,9 +4,9 @@ "OP-Stack": "8794 gas" }, "Phases": { - "Creation": "334760 gas", + "Creation": "334714 gas", "Execution": "37137 gas", - "Validation": "36067 gas" + "Validation": "36038 gas" }, - "Total": "2698700 gas" + "Total": "2698598 gas" } \ No newline at end of file diff --git a/packages/modulekit/src/core/ExtensibleFallbackHandler.sol b/packages/modulekit/src/core/ExtensibleFallbackHandler.sol index 1048e5a8..111f8a36 100644 --- a/packages/modulekit/src/core/ExtensibleFallbackHandler.sol +++ b/packages/modulekit/src/core/ExtensibleFallbackHandler.sol @@ -6,7 +6,6 @@ pragma solidity ^0.8.23; import { ERC7579FallbackBase } from "../modules/ERC7579FallbackBase.sol"; import { ERC2771Handler } from "./ERC2771Handler.sol"; -import { ModuleTypeLib, EncodedModuleTypes, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; interface IFallbackMethod { function handle( @@ -37,14 +36,6 @@ contract ExtensibleFallbackHandler is ERC7579FallbackBase, ERC2771Handler { Dynamic } - EncodedModuleTypes immutable MODULE_TYPES; - - constructor() { - ModuleType[] memory moduleTypes = new ModuleType[](1); - moduleTypes[0] = ModuleType.wrap(TYPE_FALLBACK); - MODULE_TYPES = ModuleTypeLib.bitEncode(moduleTypes); - } - function onInstall(bytes calldata data) external override { if (data.length == 0) return; Params[] memory params = abi.decode(data, (Params[])); @@ -117,10 +108,6 @@ contract ExtensibleFallbackHandler is ERC7579FallbackBase, ERC2771Handler { return isType == TYPE_FALLBACK; } - function getModuleTypes() external view returns (EncodedModuleTypes) { - return MODULE_TYPES; - } - function isInitialized(address smartAccount) external pure returns (bool) { return false; } diff --git a/packages/modulekit/src/external/ERC7579.sol b/packages/modulekit/src/external/ERC7579.sol index dc730b58..47e1cd7d 100644 --- a/packages/modulekit/src/external/ERC7579.sol +++ b/packages/modulekit/src/external/ERC7579.sol @@ -28,7 +28,6 @@ import { EXECTYPE_DEFAULT, MODE_DEFAULT } from "erc7579/lib/ModeLib.sol"; -import { EncodedModuleTypes, ModuleTypeLib, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; import { Execution, ExecutionLib as ERC7579ExecutionLib } from "erc7579/lib/ExecutionLib.sol"; import { diff --git a/packages/modulekit/src/mocks/MockExecutor.sol b/packages/modulekit/src/mocks/MockExecutor.sol index 928e081f..9fb9b3c7 100644 --- a/packages/modulekit/src/mocks/MockExecutor.sol +++ b/packages/modulekit/src/mocks/MockExecutor.sol @@ -3,17 +3,8 @@ pragma solidity ^0.8.23; import { ERC7579ExecutorBase } from "../Modules.sol"; import { IERC7579Account } from "../external/ERC7579.sol"; -import { ModuleTypeLib, EncodedModuleTypes, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract MockExecutor is ERC7579ExecutorBase { - EncodedModuleTypes immutable MODULE_TYPES; - - constructor() { - ModuleType[] memory moduleTypes = new ModuleType[](1); - moduleTypes[0] = ModuleType.wrap(TYPE_EXECUTOR); - MODULE_TYPES = ModuleTypeLib.bitEncode(moduleTypes); - } - function onInstall(bytes calldata data) external override { } function onUninstall(bytes calldata data) external override { } @@ -37,8 +28,4 @@ contract MockExecutor is ERC7579ExecutorBase { function isInitialized(address smartAccount) external pure returns (bool) { return false; } - - function getModuleTypes() external view returns (EncodedModuleTypes) { - return MODULE_TYPES; - } } diff --git a/packages/modulekit/src/mocks/MockHook.sol b/packages/modulekit/src/mocks/MockHook.sol index d34331a9..a8c97f22 100644 --- a/packages/modulekit/src/mocks/MockHook.sol +++ b/packages/modulekit/src/mocks/MockHook.sol @@ -2,17 +2,8 @@ pragma solidity ^0.8.23; import { ERC7579HookBase } from "../Modules.sol"; -import { ModuleTypeLib, EncodedModuleTypes, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract MockHook is ERC7579HookBase { - EncodedModuleTypes immutable MODULE_TYPES; - - constructor() { - ModuleType[] memory moduleTypes = new ModuleType[](1); - moduleTypes[0] = ModuleType.wrap(TYPE_HOOK); - MODULE_TYPES = ModuleTypeLib.bitEncode(moduleTypes); - } - function onInstall(bytes calldata data) external override { } function onUninstall(bytes calldata data) external override { } @@ -37,8 +28,4 @@ contract MockHook is ERC7579HookBase { function isModuleType(uint256 typeID) external pure returns (bool) { return typeID == TYPE_HOOK; } - - function getModuleTypes() external view returns (EncodedModuleTypes) { - return MODULE_TYPES; - } } diff --git a/packages/modulekit/src/mocks/MockValidator.sol b/packages/modulekit/src/mocks/MockValidator.sol index d4490ce6..417c25ee 100644 --- a/packages/modulekit/src/mocks/MockValidator.sol +++ b/packages/modulekit/src/mocks/MockValidator.sol @@ -4,17 +4,8 @@ pragma solidity ^0.8.23; /* solhint-disable no-unused-vars */ import { ERC7579ValidatorBase } from "../Modules.sol"; import { PackedUserOperation } from "../external/ERC4337.sol"; -import { ModuleTypeLib, EncodedModuleTypes, ModuleType } from "erc7579/lib/ModuleTypeLib.sol"; contract MockValidator is ERC7579ValidatorBase { - EncodedModuleTypes immutable MODULE_TYPES; - - constructor() { - ModuleType[] memory moduleTypes = new ModuleType[](1); - moduleTypes[0] = ModuleType.wrap(TYPE_VALIDATOR); - MODULE_TYPES = ModuleTypeLib.bitEncode(moduleTypes); - } - function onInstall(bytes calldata data) external virtual override { } function onUninstall(bytes calldata data) external virtual override { } @@ -48,10 +39,6 @@ contract MockValidator is ERC7579ValidatorBase { return typeID == TYPE_VALIDATOR; } - function getModuleTypes() external view returns (EncodedModuleTypes) { - return MODULE_TYPES; - } - function isInitialized(address smartAccount) external pure returns (bool) { return false; } diff --git a/packages/modulekit/test/components/HookDestruct.t.sol b/packages/modulekit/test/components/HookDestruct.t.sol index 46ba27d3..ad684a8f 100644 --- a/packages/modulekit/test/components/HookDestruct.t.sol +++ b/packages/modulekit/test/components/HookDestruct.t.sol @@ -5,7 +5,6 @@ import "src/modules/ERC7579HookDestruct.sol"; import { IERC7579Account } from "src/external/ERC7579.sol"; import "forge-std/Test.sol"; -import { EncodedModuleTypes } from "erc7579/lib/ModuleTypeLib.sol"; import { ExecutionLib, Execution } from "erc7579/lib/ExecutionLib.sol"; contract HookDestructTest is Test, ERC7579HookDestruct { @@ -222,7 +221,6 @@ contract HookDestructTest is Test, ERC7579HookDestruct { function onInstall(bytes calldata) public { } function onUninstall(bytes calldata) public { } - function getModuleTypes() public pure returns (EncodedModuleTypes) { } function isInitialized(address smartAccount) public view returns (bool) { } function isModuleType(uint256 moduleType) public pure returns (bool) { } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 18df2cad..16978881 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -28,7 +28,7 @@ importers: devDependencies: '@ERC4337/account-abstraction': specifier: github:kopy-kat/account-abstraction#develop - version: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + version: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) '@ERC4337/account-abstraction-v0.6': specifier: github:eth-infinitism/account-abstraction#v0.6.0 version: github.com/eth-infinitism/account-abstraction/7174d6d845618dbd11cee68eefa715f5263690b6(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) @@ -55,7 +55,7 @@ importers: version: github.com/rhinestonewtf/erc4337-validation/19a97d86f8f29709664334078925b2a843be19e0 erc7579: specifier: github:erc7579/erc7579-implementation - version: github.com/erc7579/erc7579-implementation/957cd05deeab6a9a85343bb8d1c9701705ed4ecf + version: github.com/erc7579/erc7579-implementation/85d2823a73f1816b519e7bd65e7d82c8b8a172a4 forge-std: specifier: github:foundry-rs/forge-std version: github.com/foundry-rs/forge-std/1d0766bc5d814f117c7b1e643828f7d85024fb51 @@ -64,10 +64,10 @@ importers: version: 2.8.8 sentinellist: specifier: github:zeroknots/sentinellist - version: github.com/zeroknots/sentinellist/2783f466b6d9c457da0a240e392db183ca1607bb + version: github.com/zeroknots/sentinellist/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b solady: specifier: github:vectorized/solady - version: github.com/vectorized/solady/1372606383445c0a247e6c58eb255a529734258a + version: github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b solarray: specifier: github:sablier-labs/solarray version: github.com/sablier-labs/solarray/6bf10cb34cdace52a3ba5fe437e78cc82df92684 @@ -82,7 +82,7 @@ importers: devDependencies: '@ERC4337/account-abstraction': specifier: github:kopy-kat/account-abstraction#develop - version: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + version: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) '@ERC4337/account-abstraction-v0.6': specifier: github:eth-infinitism/account-abstraction#v0.6.0 version: github.com/eth-infinitism/account-abstraction/7174d6d845618dbd11cee68eefa715f5263690b6(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) @@ -112,7 +112,7 @@ importers: version: github.com/rhinestonewtf/erc4337-validation/19a97d86f8f29709664334078925b2a843be19e0 erc7579: specifier: github:erc7579/erc7579-implementation - version: github.com/erc7579/erc7579-implementation/957cd05deeab6a9a85343bb8d1c9701705ed4ecf + version: github.com/erc7579/erc7579-implementation/85d2823a73f1816b519e7bd65e7d82c8b8a172a4 forge-std: specifier: github:foundry-rs/forge-std version: github.com/foundry-rs/forge-std/1d0766bc5d814f117c7b1e643828f7d85024fb51 @@ -121,10 +121,10 @@ importers: version: 2.8.8 sentinellist: specifier: github:zeroknots/sentinellist - version: github.com/zeroknots/sentinellist/2783f466b6d9c457da0a240e392db183ca1607bb + version: github.com/zeroknots/sentinellist/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b solady: specifier: github:vectorized/solady - version: github.com/vectorized/solady/1372606383445c0a247e6c58eb255a529734258a + version: github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b solarray: specifier: github:sablier-labs/solarray version: github.com/sablier-labs/solarray/6bf10cb34cdace52a3ba5fe437e78cc82df92684 @@ -139,7 +139,7 @@ importers: devDependencies: '@ERC4337/account-abstraction': specifier: github:kopy-kat/account-abstraction#develop - version: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.7.2)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + version: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.7.2)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) '@ERC4337/account-abstraction-v0.6': specifier: github:eth-infinitism/account-abstraction#v0.6.0 version: github.com/eth-infinitism/account-abstraction/7174d6d845618dbd11cee68eefa715f5263690b6(ethers@5.7.2)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) @@ -151,7 +151,7 @@ importers: version: github.com/dapphub/ds-test/e282159d5170298eb2455a6c05280ab5a73a4ef0 erc7579: specifier: github:erc7579/erc7579-implementation - version: github.com/erc7579/erc7579-implementation/be581c908df73f1554f466cb6b47c8ce8777e50f + version: github.com/erc7579/erc7579-implementation/85d2823a73f1816b519e7bd65e7d82c8b8a172a4 forge-std: specifier: github:foundry-rs/forge-std version: github.com/foundry-rs/forge-std/1d0766bc5d814f117c7b1e643828f7d85024fb51 @@ -160,10 +160,10 @@ importers: version: 2.8.8 sentinellist: specifier: github:zeroknots/sentinellist - version: github.com/zeroknots/sentinellist/1f9ec0250f1b3f14ba5d200629e3d9f3264fde61 + version: github.com/zeroknots/sentinellist/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b solady: specifier: github:vectorized/solady - version: github.com/vectorized/solady/9deb9ed36a27261a8745db5b7cd7f4cdc3b1cd4e + version: github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b solhint: specifier: ^4.1.1 version: 4.1.1(typescript@5.3.3) @@ -172,7 +172,7 @@ importers: devDependencies: '@ERC4337/account-abstraction': specifier: github:kopy-kat/account-abstraction#develop - version: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + version: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) '@ERC4337/account-abstraction-v0.6': specifier: github:eth-infinitism/account-abstraction#v0.6.0 version: github.com/eth-infinitism/account-abstraction/7174d6d845618dbd11cee68eefa715f5263690b6(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) @@ -199,7 +199,7 @@ importers: version: github.com/rhinestonewtf/erc4337-validation/19a97d86f8f29709664334078925b2a843be19e0 erc7579: specifier: github:erc7579/erc7579-implementation - version: github.com/erc7579/erc7579-implementation/957cd05deeab6a9a85343bb8d1c9701705ed4ecf + version: github.com/erc7579/erc7579-implementation/85d2823a73f1816b519e7bd65e7d82c8b8a172a4 forge-std: specifier: github:foundry-rs/forge-std version: github.com/foundry-rs/forge-std/1d0766bc5d814f117c7b1e643828f7d85024fb51 @@ -208,10 +208,10 @@ importers: version: 2.8.8 sentinellist: specifier: github:zeroknots/sentinellist - version: github.com/zeroknots/sentinellist/2783f466b6d9c457da0a240e392db183ca1607bb + version: github.com/zeroknots/sentinellist/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b solady: specifier: github:vectorized/solady - version: github.com/vectorized/solady/1372606383445c0a247e6c58eb255a529734258a + version: github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b solarray: specifier: github:sablier-labs/solarray version: github.com/sablier-labs/solarray/6bf10cb34cdace52a3ba5fe437e78cc82df92684 @@ -1450,13 +1450,13 @@ packages: /@types/bn.js@4.11.6: resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /@types/bn.js@5.1.5: resolution: {integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /@types/debug@4.1.12: @@ -1469,7 +1469,7 @@ packages: resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} dependencies: '@types/minimatch': 5.1.2 - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /@types/http-cache-semantics@4.0.4: @@ -1492,8 +1492,8 @@ packages: resolution: {integrity: sha512-nG96G3Wp6acyAgJqGasjODb+acrI7KltPiRxzHPXnP3NgI28bpQDRv53olbqGXbfcgF5aiiHmO3xpwEpS5Ld9g==} dev: true - /@types/node@20.11.19: - resolution: {integrity: sha512-7xMnVEcZFu0DikYjWOlRq7NTPETrm7teqUT2WkQjrTIkEgUyyGdWsj/Zg8bEJt5TNklzbPD1X3fqfsHw3SpapQ==} + /@types/node@20.11.20: + resolution: {integrity: sha512-7/rR21OS+fq8IyHTgtLkDK949uzsa6n8BkziAKtPVpugIkO6D+/ooXMvzXxDnZrmtXVfjb1bKQafYpb8s89LOg==} dependencies: undici-types: 5.26.5 dev: true @@ -1501,7 +1501,7 @@ packages: /@types/pbkdf2@3.1.2: resolution: {integrity: sha512-uRwJqmiXmh9++aSu1VNEn3iIxWOhd8AHXNSdlaLfdAAdSTY9jYVeGWnzejM3dvrkbqE3/hyQkQQ29IFATEGlew==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /@types/prettier@2.7.3: @@ -1515,14 +1515,14 @@ packages: /@types/readable-stream@2.3.15: resolution: {integrity: sha512-oM5JSKQCcICF1wvGgmecmHldZ48OZamtMxcGGVICOJA8o8cahXC1zEVAif8iwoc5j8etxFaRFnf095+CDsuoFQ==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 safe-buffer: 5.1.2 dev: true /@types/secp256k1@4.0.6: resolution: {integrity: sha512-hHxJU6PAEUn0TP4S/ZOzuTUvJWuZ6eIKeNKb5RBpODvSl6hp1Wrw4s7ATY50rklRCScUDpHzVA/DQdSjJ3UoYQ==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /abbrev@1.0.9: @@ -2597,7 +2597,7 @@ packages: dependencies: es-errors: 1.3.0 function-bind: 1.1.2 - has-proto: 1.0.1 + has-proto: 1.0.3 has-symbols: 1.0.3 hasown: 2.0.1 dev: true @@ -2883,8 +2883,8 @@ packages: es-define-property: 1.0.0 dev: true - /has-proto@1.0.1: - resolution: {integrity: sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==} + /has-proto@1.0.3: + resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} engines: {node: '>= 0.4'} dev: true @@ -3261,7 +3261,7 @@ packages: resolution: {integrity: sha512-90Tvmg2NXwnKMgTafA01PRELsYNNRb/F2bj3nzdByTLLMUmgkgL8H/oeWcjZtVVffnBJyNjDcYxY7cdOE/WoHg==} engines: {node: '>=14.17'} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.20 dev: true /md5.js@1.3.5: @@ -3995,8 +3995,8 @@ packages: - typescript dev: true - /solidity-coverage@0.8.7(hardhat@2.20.1): - resolution: {integrity: sha512-RzcPuNsIqVGq5F8rjQZPdI2EVdsRU7w2f1Uk1UY567n9eNcg5LSEQ3Q1WFoy9bi/2AD5SYbYK9SS/Nwh2oYbNw==} + /solidity-coverage@0.8.8(hardhat@2.20.1): + resolution: {integrity: sha512-7RN6/8YAFMQNeMdSulARtE0VC5JitBAUMwvkr10FkOK+nux5q+WykrgSZntkWrX/VHzRa096P4OOViO0T9Q9Cw==} hasBin: true peerDependencies: hardhat: ^2.11.0 @@ -4462,16 +4462,8 @@ packages: version: 1.0.0 dev: true - github.com/erc7579/erc7579-implementation/957cd05deeab6a9a85343bb8d1c9701705ed4ecf: - resolution: {tarball: https://codeload.github.com/erc7579/erc7579-implementation/tar.gz/957cd05deeab6a9a85343bb8d1c9701705ed4ecf} - name: micro-msa - version: 0.3.1 - dependencies: - '@openzeppelin/contracts': 5.0.1 - dev: true - - github.com/erc7579/erc7579-implementation/be581c908df73f1554f466cb6b47c8ce8777e50f: - resolution: {tarball: https://codeload.github.com/erc7579/erc7579-implementation/tar.gz/be581c908df73f1554f466cb6b47c8ce8777e50f} + github.com/erc7579/erc7579-implementation/85d2823a73f1816b519e7bd65e7d82c8b8a172a4: + resolution: {tarball: https://codeload.github.com/erc7579/erc7579-implementation/tar.gz/85d2823a73f1816b519e7bd65e7d82c8b8a172a4} name: micro-msa version: 0.3.1 dependencies: @@ -4494,7 +4486,7 @@ packages: ethereumjs-wallet: 1.0.2 hardhat-deploy: 0.11.45 hardhat-deploy-ethers: 0.3.0-beta.13(ethers@5.4.0)(hardhat@2.20.1) - solidity-coverage: 0.8.7(hardhat@2.20.1) + solidity-coverage: 0.8.8(hardhat@2.20.1) source-map-support: 0.5.21 table: 6.8.1 typescript: 4.9.5 @@ -4525,7 +4517,7 @@ packages: ethereumjs-wallet: 1.0.2 hardhat-deploy: 0.11.45 hardhat-deploy-ethers: 0.3.0-beta.13(ethers@5.7.2)(hardhat@2.20.1) - solidity-coverage: 0.8.7(hardhat@2.20.1) + solidity-coverage: 0.8.8(hardhat@2.20.1) source-map-support: 0.5.21 table: 6.8.1 typescript: 4.9.5 @@ -4546,9 +4538,9 @@ packages: version: 1.7.6 dev: true - github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0): - resolution: {tarball: https://codeload.github.com/kopy-kat/account-abstraction/tar.gz/aafae2a1f974e4c05f7025b3303d0d4aba85fa76} - id: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76 + github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.4.0)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0): + resolution: {tarball: https://codeload.github.com/kopy-kat/account-abstraction/tar.gz/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc} + id: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc name: accountabstraction version: 0.6.0 dependencies: @@ -4556,12 +4548,14 @@ packages: '@openzeppelin/contracts': 5.0.1 '@thehubbleproject/bls': 0.5.1 '@typechain/hardhat': 2.3.1(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + '@types/debug': 4.1.12 '@types/mocha': 9.1.1 + debug: 4.3.4(supports-color@8.1.1) ethereumjs-util: 7.1.5 ethereumjs-wallet: 1.0.2 hardhat-deploy: 0.11.45 hardhat-deploy-ethers: 0.3.0-beta.13(ethers@5.4.0)(hardhat@2.20.1) - solidity-coverage: 0.8.7(hardhat@2.20.1) + solidity-coverage: 0.8.8(hardhat@2.20.1) source-map-support: 0.5.21 table: 6.8.1 typescript: 4.9.5 @@ -4576,9 +4570,9 @@ packages: - utf-8-validate dev: true - github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76(ethers@5.7.2)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0): - resolution: {tarball: https://codeload.github.com/kopy-kat/account-abstraction/tar.gz/aafae2a1f974e4c05f7025b3303d0d4aba85fa76} - id: github.com/kopy-kat/account-abstraction/aafae2a1f974e4c05f7025b3303d0d4aba85fa76 + github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc(ethers@5.7.2)(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0): + resolution: {tarball: https://codeload.github.com/kopy-kat/account-abstraction/tar.gz/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc} + id: github.com/kopy-kat/account-abstraction/3c0127e9f7cb76e4a0fdb2d35cac51900f252bdc name: accountabstraction version: 0.6.0 dependencies: @@ -4586,12 +4580,14 @@ packages: '@openzeppelin/contracts': 5.0.1 '@thehubbleproject/bls': 0.5.1 '@typechain/hardhat': 2.3.1(hardhat@2.20.1)(lodash@4.17.21)(typechain@5.2.0) + '@types/debug': 4.1.12 '@types/mocha': 9.1.1 + debug: 4.3.4(supports-color@8.1.1) ethereumjs-util: 7.1.5 ethereumjs-wallet: 1.0.2 hardhat-deploy: 0.11.45 hardhat-deploy-ethers: 0.3.0-beta.13(ethers@5.7.2)(hardhat@2.20.1) - solidity-coverage: 0.8.7(hardhat@2.20.1) + solidity-coverage: 0.8.8(hardhat@2.20.1) source-map-support: 0.5.21 table: 6.8.1 typescript: 4.9.5 @@ -4612,7 +4608,7 @@ packages: version: 0.0.1 dependencies: '@openzeppelin/contracts': 5.0.1 - solady: github.com/vectorized/solady/1372606383445c0a247e6c58eb255a529734258a + solady: github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b dev: true github.com/sablier-labs/solarray/6bf10cb34cdace52a3ba5fe437e78cc82df92684: @@ -4627,26 +4623,14 @@ packages: version: 6.2.0 dev: true - github.com/vectorized/solady/1372606383445c0a247e6c58eb255a529734258a: - resolution: {tarball: https://codeload.github.com/vectorized/solady/tar.gz/1372606383445c0a247e6c58eb255a529734258a} - name: solady - version: 0.0.168 - dev: true - - github.com/vectorized/solady/9deb9ed36a27261a8745db5b7cd7f4cdc3b1cd4e: - resolution: {tarball: https://codeload.github.com/vectorized/solady/tar.gz/9deb9ed36a27261a8745db5b7cd7f4cdc3b1cd4e} + github.com/vectorized/solady/72e47ca417d24a30801b2921584e8486462cfc7b: + resolution: {tarball: https://codeload.github.com/vectorized/solady/tar.gz/72e47ca417d24a30801b2921584e8486462cfc7b} name: solady - version: 0.0.168 + version: 0.0.170 dev: true - github.com/zeroknots/sentinellist/1f9ec0250f1b3f14ba5d200629e3d9f3264fde61: - resolution: {tarball: https://codeload.github.com/zeroknots/sentinellist/tar.gz/1f9ec0250f1b3f14ba5d200629e3d9f3264fde61} + github.com/zeroknots/sentinellist/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b: + resolution: {tarball: https://codeload.github.com/zeroknots/sentinellist/tar.gz/6294bf412489c0f6d3b9c92ad0aceb08c5b8704b} name: sentinellist - version: 0.0.0 - dev: true - - github.com/zeroknots/sentinellist/2783f466b6d9c457da0a240e392db183ca1607bb: - resolution: {tarball: https://codeload.github.com/zeroknots/sentinellist/tar.gz/2783f466b6d9c457da0a240e392db183ca1607bb} - name: sentinellist - version: 0.0.0 + version: 1.0.0 dev: true