The documentation states that the admin should be able to pause all markets, but the actual implementation only uses the pause functionality in the TokenManager::withdraw
function. There is no direct function to pause all markets, the pause functionality is only available through the Rescuable contract, which means individual contracts or functions cannot be paused. function
Documented Functionality:
The documentation states: "The Owner can pause all the markets"
Actual Implementation
Pause functionality is only used in TokenManager::withdraw function
No direct function to pause all markets exists
Pause functionality is only accessible through the Rescuable contract makes Owner can't pause or unpause specific contract or functions.
- Inability to quickly pause all markets in case of an emergency, increasing vulnerability to potential attacks or bugs
- incomplete emergency controls, potentially compromising the ability to protect user funds in critical situations
Manual code Review
Implement a centralized pause function that allows the admin to pause all markets at once. This function should be accessible directly by the admin and should trigger the pause across all relevant contracts
Use onlyOwner modifier in all the function that should be paused due an Exploits or emergency or should be .
I believe this is informational and non-acceptable severity because: - A single pause on withdraw to be sufficient to pause the markets during times of emergencies, given that is the only function where collateral/point tokens/native ETH can be pulled from market transactions. - Every tadle market place can be switched offline by the admin via [`updateMarketPlaceStatus`](https://github.com/Cyfrin/2024-08-tadle/blob/04fd8634701697184a3f3a5558b41c109866e5f8/src/core/SystemConfig.sol#L160-L171) and is checked in market actions via [`checkMarketPlaceStatus`](https://github.com/Cyfrin/2024-08-tadle/blob/04fd8634701697184a3f3a5558b41c109866e5f8/src/libraries/MarketPlaceLibraries.sol#L54-L67) to be online. This prevents many major market actions including the creation, listing and settlement of offers.
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.