Function: addGuardian(byte[32] guardian, uint48 validUntil, uint48 validAfter)
This function can be invoked to add a guardian to a smart account.
Inputs
guardianControl: Arbitrary.
Constraints: Must not be zero or already present.
Impact: The guardian to be added.
validUntilControl: Arbitrary.
Constraints: Must not be in the past and before
validAfter.Impact: Time until the guardian will be active.
validAfterControl: Arbitrary.
Constraints: Must be in the future (respecting the security delay).
Impact: Time from which the guardian will be active.
Branches and code coverage
Intended branches
Adds the guardian to the smart account.
Negative behavior
Reverts if
guardianis zero.Reverts if
guardianis already set.Reverts if the time frame is invalid.