UManager
Inherits: Auth
State Variables
period
The period in seconds for the rate limit.
uint16 public period;allowedCallsPerPeriod
The number of calls allowed per period.
uint16 public allowedCallsPerPeriod;callCountPerPeriod
The number of calls made in the current period.
mapping(uint256 => uint256) public callCountPerPeriod;manager
The ManagerWithMerkleVerification this uManager works with.
ManagerWithMerkleVerification internal immutable manager;boringVault
The BoringVault this uManager works with.
address internal immutable boringVault;Functions
enforceRateLimit
modifier enforceRateLimit();constructor
constructor(address _owner, address _manager, address _boringVault) Auth(_owner, Authority(address(0)));setPeriod
Sets the duration of the period.
Callable by MULTISIG_ROLE.
function setPeriod(uint16 _period) external requiresAuth;setAllowedCallsPerPeriod
Sets the number of calls allowed per period.
Callable by MULTISIG_ROLE.
function setAllowedCallsPerPeriod(uint16 _allowedCallsPerPeriod) external requiresAuth;revokeTokenApproval
Allows auth to set token approvals to zero.
Callable by STRATEGIST_ROLE.
function revokeTokenApproval(
bytes32[][] calldata manageProofs,
address[] calldata decodersAndSanitizers,
ERC20[] calldata tokens,
address[] calldata spenders
)
external
requiresAuth;Events
PeriodUpdated
event PeriodUpdated(uint16 oldPeriod, uint16 newPeriod);AllowedCallsPeriodUpdated
event AllowedCallsPeriodUpdated(uint16 oldAllowance, uint16 newAllowance);Errors
UManager__CallCountExceeded
error UManager__CallCountExceeded();Was this helpful?