IAccount
ERC-4337 account interface.
Functions
validateUserOp
Validates a user operation on behalf of the EntryPoint.
MUST be gated to msg.sender == entryPoint. MUST NOT revert on a signature mismatch — instead
return validationData with the low bit set (SIG_VALIDATION_FAILED == 1). If missingAccountFunds
is non-zero, the account MUST transfer at least that much to the EntryPoint (msg.sender).
function validateUserOp(PackedUserOperation calldata userOp, bytes32 userOpHash, uint256 missingAccountFunds)
external
returns (uint256 validationData);Parameters
| Name | Type | Description |
|---|---|---|
| userOp | PackedUserOperation | The packed user operation. |
| userOpHash | bytes32 | The EntryPoint-computed hash the signature is over (already domain-bound). |
| missingAccountFunds | uint256 | The prefund the account owes the EntryPoint for this op. |
Returns
| Name | Type | Description |
|---|---|---|
| validationData | uint256 | Packed authorizer(160) || validUntil(48) || validAfter(48); 0 = valid,1 = signature failure. |