Unchecked low-level calls
The contract ignores the return value of low-level calls that send Ether to a burn address. If such a call fails, the Ether remains locked in the contract.
Submitted by 0v3rf10w, also found by Reigada
Impact
Unchecked low-level calls
Proof of Concept
Unchecked cases at 2 places :- BasicSale.receive() (2021-11-bootfinance/tge/contracts/PublicSale.sol#148-156) ignores return value by burnAddress.call{value: msg.value}() (2021-11-bootfinance/tge/contracts/PublicSale.sol#154)
BasicSale.burnEtherForMember(address) (2021-11-bootfinance/tge/contracts/PublicSale.sol#158-166) ignores return value by burnAddress.call{value: msg.value}() (2021-11-bootfinance/tge/contracts/PublicSale.sol#164)
Tools Used
Manual
Recommended Mitigation Steps
The return value of the low-level call is not checked, so if the call fails, the Ether will be locked in the contract. If the low level is used to prevent blocking operations, consider logging failed calls.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The contract uses a low-level call to send Ether but does not check its return value, so failed transfers go unnoticed.
Impact
If the low-level call fails, the Ether sent by users could become permanently locked in the contract.
What the attacker needed
None
The fix
The contract should check the return value of the low-level call and handle failures, or log failed calls if blocking is to be avoided.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
When a smart contract sends Ether to another address, it can use a low-level call that returns a success flag. If the contract does not check that flag, it will not know the transfer failed. Here, the contract ignores the flag, so failed transfers leave the Ether stuck in the contract.
What is Smart contracts?
Flaws in on-chain code that let an attacker drain funds, freeze them or break the protocol's accounting.