Falta de Controle de Acesso (Missing Access Control)
contract VulnerableContract {
address public owner;
uint public totalFunds;
constructor() {
owner = msg.sender;
}
function deposit() external payable {
totalFunds += msg.value;
}
function withdrawAllFunds(address payable _to) external {
require(totalFunds > 0, "No funds available");
_to.transfer(totalFunds);
totalFunds = 0;
}
}PreviousManipulação de Oráculos de Preços (Price Oracle Manipulation)NextManipulação de Recompensas (Reward Manipulation)
Last updated