Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TOB-BOB-1] withdrawDepositsToL1 is lacking a pausable modifier #2

Open
technovision99 opened this issue Apr 12, 2024 · 0 comments
Open

Comments

@technovision99
Copy link

withdrawDepositsToL1 is lacking a pausable modifier

Severity: Informational
Difficulty:High
Type: Data Validation
Target: src/FusionLock.sol

Description

The FusionLock contract is designed to be pausable, with the documentation saying that all user functionalities can be paused by the owner. However, the withdrawDepositsToL1 function does not have the whenNotPaused modifier. As a result, L1 withdrawals cannot be paused.

/**
* @dev Function to withdraw all deposits to Layer 1 for multiple tokens.
* @param tokens Array of token addresses to withdraw.
*/
function withdrawDepositsToL1(address[] memory tokens) external {

Recommendations

Short term, add the whenNotPaused modifier to the function.

Long term, improve unit testing to uncover edge cases and ensure intended behavior throughout the system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant