Source:src/Strategy.sol·src/modules/CallValidatorModule.sol
Responsibility
Strategy is a restricted execution wallet for fund capital. The Fund pushes assets into a strategy, and operators holding CALLER_ROLE deploy that capital into external protocols (DEXes, lending markets, …) through a generic call interface — but only calls that have been explicitly allowlisted can execute.
Key properties:
- Each strategy has its own access control (
ACLModulewith its own admin), separate from the Fund’s roles. The fund admin and the strategy operator can be different parties. - The Fund can always pull assets back (
pullAssetisonlyFund, invoked viaFund.pullAssetFromStrategy), so the operator can deploy capital but never lock the Fund out of it. - The strategy can never call the Fund (
target == fundis rejected), preventing the operator from reaching Fund-privileged paths.
Fund.createStrategy → FundManager.createStrategyForFund, which binds the strategy to the fund and puts its proxy under the same ProxyAdmin owner as the Fund’s.
Call allowlisting (CallValidatorModule)
Two allowlist granularities, both keyed per (caller, target, selector):
- Plain calls —
addCalls([{caller, target, selector}])permitscallerto invoketarget.selector(…)with any arguments. - Constrained calls —
addConstrainedCalls([...])additionally pins specific 32-byte words of the calldata:constrainedOffsets[i]is a byte offset andconstrainedValues[i]the exact word required there. Example: allowtransfer(address,uint256)only when the recipient word (offset 4) equals a specific address — the amount stays free.
call. For constrained calls, the caller passes the same offsets/values used at registration (they’re part of the allowlist key), and the module verifies the actual calldata matches every pinned word.
Function reference
Execution
Fund actions
Allowlist management (strategy’s own ACL)
Views
fund(), getAllowedCalls(), getAllowedConstrainedCalls(), getCall(hash), getConstrainedCall(hash), getCallHash(caller, target, selector), getConstrainedCallHash(caller, target, selector, offsets, values).