QuantAMM

QuantAMM
49,600 OP
View results
Submission Details
Severity: low
Invalid

No Zero-Address Check for _updateWeightRunner in UpdateRule Constructor

Summary

Within the UpdateRule base contract’s constructor:

constructor(address _updateWeightRunner){
// require(_updateWeightRunner != address(0), "Invalid address");
updateWeightRunner = _updateWeightRunner;
}

there is no validation to ensure _updateWeightRunner is not the zero address. A zero address would invalidate any calls expecting updateWeightRunner to be a legitimate contract or account.

Vulnerability Details

Impact

  • Risk of Disabled Functionality: If _updateWeightRunner is set to address(0), any logic relying on it (e.g., weight updates) may be rendered inoperative.

  • Limited Attack Surface: Since this typically requires privileged (deployment-level) control, it’s not a direct security hole for non-privileged users, but it is still a best practice concern.

Tools Used

Manual audit

Recommendations

  1. Add a Zero-Address Check

    require(_updateWeightRunner != address(0), "Invalid updateWeightRunner");
  2. Document Valid Assumptions.
    Explain that a valid, non-zero _updateWeightRunner is essential to ensure all weight update methods remain callable.

Updates

Lead Judging Commences

n0kto Lead Judge 10 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
Assigned finding tags:

Informational or Gas / Admin is trusted / Pool creation is trusted / User mistake / Suppositions

Please read the CodeHawks documentation to know which submissions are valid. If you disagree, provide a coded PoC and explain the real likelyhood and the detailed impact on the mainnet without any supposition (if, it could, etc) to prove your point.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.

Give us feedback!