I was reviewing Dapp-Learning-DAO/Dapp-Learning and found something in security/Analysis&POC/XSURGE/POC.sol line 65 that might need attention.
(bool buy_successful,) = payable(Surge_Address).call{value: address(this).balance, gas: 40000}("");
Potential reentrancy — external call before state update. If balances are updated after the call, an attacker can drain funds via re-entrant calls.
Worth a look to see if this is accounted for elsewhere — could be a real issue depending on the surrounding context.
I was reviewing Dapp-Learning-DAO/Dapp-Learning and found something in
security/Analysis&POC/XSURGE/POC.sol line 65that might need attention.(bool buy_successful,) = payable(Surge_Address).call{value: address(this).balance, gas: 40000}("");
Potential reentrancy — external call before state update. If balances are updated after the call, an attacker can drain funds via re-entrant calls.
Worth a look to see if this is accounted for elsewhere — could be a real issue depending on the surrounding context.