_replaceScope() validates each account against the agreement's isContractInScope and checks for duplicates, but never checks account != address(0). If the agreement contract returns true for address(0), a zero-address entry would be admitted into the pool scope. This would break any off-chain consumer iterating getScopeAccounts() and calling .balanceOf or similar on address(0).
Likelihood: Low — requires a BattleChain agreement to report address(0) as in-scope, or the owner to pass it in the initial scope array.
Impact: Low — no funds lost. Off-chain consumers iterating the scope may encounter errors when attempting to query address(0).
File: L12-ScopeAccount-ZeroAddress.poc.t.sol
Run: forge test --match-path 'L12-ScopeAccount-ZeroAddress.poc.t.sol' -vv
Add zero-address validation in the _replaceScope loop:
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.