Root Cause: The deployment script mines an address with BEFORE_INITIALIZE_FLAG, while the hook declares afterInitialize: true and beforeInitialize: false. The mismatch triggers Hooks.validateHookPermissions and reverts in the constructor.
Impact: The hook contract cannot be deployed using the provided script, preventing protocol setup and pool initialization.
The normal behavior is to mine a hook address whose flags exactly match the permissions returned by getHookPermissions.
The script uses BEFORE_INITIALIZE_FLAG, but the hook only implements afterInitialize, so the constructor validation reverts and deployment fails.
Likelihood:
Occurs on every deployment that uses the current script.
Impact:
Deployment fails and the hook is never created, blocking protocol setup.
Steps:
Operator runs forge script script/deployLaunchHook.s.sol.
The script mines a hook address with BEFORE_INITIALIZE_FLAG.
The hook constructor validates permissions against address flags.
Validation fails due to flag mismatch.
The constructor reverts with HookAddressNotValid.
Deployment is aborted and the hook is not created.
PoC demonstrates constructor failure when using the script’s flags.
Update script/deployLaunchHook.s.sol to use the correct flags that match the contract's permissions.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.
The contest is complete and the rewards are being distributed.