PantsirПанцирь
Preparing access
Checking your lab membership...
Created 10 Feb 2026Updated 10 Feb 2026
Creator TipJar (Solidity Reentrancy)
A small onchain tip-jar dApp lets creators withdraw tips, but a payout flow is vulnerable to reentrancy.
solidity320 pts35 min

Overview

The Creator TipJar dApp lets fans tip creators onchain and lets creators withdraw their accumulated tips.

Main workflow:

  • tipCreator(address creator) receives ETH and credits that creator.
  • withdrawTips(uint256 amount) sends ETH to the caller.

A bug bounty report says a malicious creator contract can drain more ETH than its recorded balance.

Your task: inspect the payout path, identify the exact vulnerable line, and describe how to fix it using secure Solidity patterns.

Content locked
Join this lab to access the content.
contracts/ReentrancyAttacker.solsol