Beginner FriendlyFoundryBridge
100 EXP
View results
Submission Details
Severity: low
Invalid

Redundant Invocation of pause Function Without State Check

Summary

The contract includes a pause function without a check to verify if the contract is already in a paused state. Multiple invocations of the pause function can occur without altering the contract state, leading to redundant transactions and potential gas wastage.

Vulnerability Details

The absence of a state check in the pause function allows for multiple calls, resulting in no change to the contract's paused state when it's already paused. The function lacks a condition to verify the current state before execution, leading to redundant and potentially unnecessary function calls.

Impact

The impact of this issue is relatively low. Redundant invocations of the pause function, when the contract is already paused, don't affect the contract state. However, it results in unnecessary transaction execution and gas costs.

Tools Used

Manual inspection

Recommendations

Implement a state check within the pause function to verify if the contract is already paused before executing the pausing action. This check will prevent redundant function calls, saving gas and avoiding unnecessary transactions.

Updates

Lead Judging Commences

0xnevi Lead Judge
over 1 year ago
0xnevi Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Other

Support

FAQs

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