🔥 Liquidity Adder Contract (“DWOJ FlamePool”)
The DWOJ FlamePool contract is the on-chain engine that turns your presale contributions into permanent, tamper-proof scarcity. It handles two critical tasks in one seamless, atomic process: swapping collected USDT/USDC into ETH (or BNB), and then minting—and immediately burning—full‐range liquidity on Uniswap V3 (Ethereum) or PancakeSwap (BNB Chain).
Core Security & Attack Resistance
Ownable & “onlyOwner” Controls: Only the project’s multisig wallet can trigger swaps or minting, preventing unauthorized actors from manipulating liquidity flows.
ReentrancyGuard Protection: All external actions (swapExactInputSingle, addLiquidityETHFullRange) are wrapped with a nonReentrant modifier, blocking reentrancy attacks even if paired tokens attempt malicious callbacks.
Strict Input Validation:
require(tokenIn != address(0))andrequire(amountIn > 0)ensure zero-address or zero-amount swaps are impossible.Fee tiers are locked to 0.05%, 0.3% or 1% only—no arbitrary pool fees can be injected.
Tick bounds and pool initialization are rigorously checked to prevent malformed liquidity positions.
Safe Approvals & Error Handling:
Allowances are reset to zero before approval to prevent ERC-20 “approve front-running” exploits.
All swap calls use Uniswap V3’s minimal router interface and wrap each call in
try/catch, emitting debug events on failure without leaving funds stranded.
Immutable Burn Mechanism: After liquidity is minted, all resulting LP NFTs are sent directly to the
0x…dEaDaddress—there is no withdraw or timelock function. This atomic “mint-and-burn” approach removes any single point of failure or rug-pull vector.Fallback & Cleanup: Any leftover ERC-20 tokens or ETH/BNB are immediately returned to the owner, ensuring no stray balances accumulate that could be exploited later.
By combining proven OpenZeppelin building blocks, rigorous input checks, and Uniswap V3’s full-range mint capability, the DWOJ FlamePool guarantees that every presale dollar is safely converted into on-chain liquidity—and then irrevocably burned—without compromise.
Last updated