Raisebox Faucet

First Flight #50
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Impact: low
Likelihood: low
Invalid

burnFaucetTokens function doesn't emit any event

Root + Impact

Description

  • Every function on this contract has its own event to help off-chain data fetching

  • This functions doesn't have its own event

function burnFaucetTokens(uint256 amountToBurn) public onlyOwner {
require(amountToBurn <= balanceOf(address(this)), "Faucet Token Balance: Insufficient");
// transfer faucet balance to owner first before burning
// ensures owner has a balance before _burn (owner only function) can be called successfully
_transfer(address(this), msg.sender, balanceOf(address(this)));
_burn(msg.sender, amountToBurn);
@> //no events
}

Risk

Likelihood:

  • Reason 1: This will occur every time a user interacts with the affected function, since no event is emitted to log the action on-chain.

Reason 2: Off-chain applications relying on logs for state synchronization (such as UIs or The Graph subgraphs) will not detect these state changes automatically.

Impact:

  • Impact 1: The impact on protocol logic is very low, as the absence of an event does not affect the correctness of on-chain operations.

  • Impact 2: However, it can make integration with front-end or off-chain services more complex, as they would need to perform manual state reads instead of listening for emitted logs.

Proof of Concept

Recommended Mitigation

Emit a dedicated event (e.g., TokenBurn(uint256 amount, uint timestamp) ).
This improves transparency, eases integration with monitoring tools, and simplifies debugging or auditability.

+ event RaiseBoxFaucet__TokenBurn(uint256 amount, uint256 timestamp);
function burnFaucetTokens(uint256 amountToBurn) public onlyOwner {
require(amountToBurn <= balanceOf(address(this)), "Faucet Token Balance: Insufficient");
// transfer faucet balance to owner first before burning
// ensures owner has a balance before _burn (owner only function) can be called successfully
_transfer(address(this), msg.sender, balanceOf(address(this)));
_burn(msg.sender, amountToBurn);
+ emit RaiseBoxFaucet__TokenBurn(amountToBurn, block.timestamp);
}
Updates

Lead Judging Commences

inallhonesty Lead Judge 9 days ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.