Hash on Ethereum

Uniswap v4 Hook Contract 0xac7b5d06fa1e77d08aea40d46cb7c5923a87a0cc on Ethereum · Rewards · Verified contract

Volume (24h)
$9.84
Value locked (TVL)
$8.81K
All-time volume
$3.70M
Pools using this hook
3
Swaps (24h)
1 (1 traders)
Total swaps
15,767

What it does

A post-quantum PoW token that is its own Uniswap v4 hook: it sells HASH in a genesis sale, seeds an ETH/HASH pool, takes a 1% fee on ETH-side swaps, and mints HASH to miners who solve proof-of-work challenges.

How it works step by step

  • Sells HASH in a fixed genesis sale at 0.01 ETH per 1,000 HASH, capped at 1,050,000 HASH and limited to 5 units per transaction.
  • Seeds a full-range Uniswap v4 ETH/HASH pool with genesis ETH and HASH once sold out or after a 30 minute partial-seed delay.
  • Charges a 1% fee on ETH-denominated swap legs and reports it via beforeSwap and afterSwap return deltas.
  • Mints mining rewards to any caller who submits a valid keccak proof for the current epoch and difficulty, halving every 100,000 mints.
  • Adjusts mining difficulty every 2,016 mints toward a five-block target per mint, bounded to a 4x change.
  • Blocks all external liquidity adds and removes; only the seeding routine can place liquidity.
Swap behaviour
Buys of HASH with exact-input ETH take a 1% fee of the ETH input in beforeSwap. Sells with exact-input HASH take a 1% fee of the ETH output in afterSwap. Other swap modes revert with UnsupportedSwapMode.
Liquidity behaviour
Liquidity can only be added through the seeding routine, which places a full-range position from the genesis ETH and HASH into the pool. beforeAddLiquidity, afterAddLiquidity, beforeRemoveLiquidity and afterRemoveLiquidity all revert, so no further liquidity can be added or removed by others.
Fee behaviour
Swaps that buy HASH with ETH (exact input, zeroForOne) pay a 1% fee of the ETH input, taken via poolManager.take in beforeSwap and reported as a return delta. Sells that are exact-input go through afterSwap, which takes 1% of the ETH output. The pool itself uses a zero LP fee.
Owner & admin controls
No owner or pausing. The controller address (tx.origin at deployment) can only call partialSeed (before genesis completes, after a 30 minute delay) and claimFees, which sweeps all ETH held by the hook to the controller. Contract is non-upgradeable, parameters are immutable or constant.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta

beforeInitialize restricts pool initialization to the pool manager and requires genesis completion with ETH as currency0. beforeSwap takes the 1% fee on ETH-in buys and returns it as a delta. afterSwap takes the 1% fee on ETH-out sells and returns it as a delta. beforeSwapReturnDelta and afterSwapReturnDelta allow the hook to claim these fee amounts from swap deltas.

Security & trust assessment

Risk level: medium (verified source, high confidence).

Who controls it: The controller can call claimFees to withdraw all ETH accumulated by the hook (genesis proceeds and fees), and can call partialSeed once after 30 minutes to force seeding with only partially sold genesis supply. It cannot change fees, pause trading, mint tokens or alter mining parameters.

Risk to user funds: The hook holds genesis ETH and accumulated swap fees, which the controller can withdraw at any time via claimFees. Pool liquidity itself is held by the position manager under a full-range position that the hook cannot withdraw. Users' HASH is a standard ERC20 without blocklists or transfer hooks.

Security findings

  • [medium] Controller can withdraw all ETH held by the hook: Genesis ETH is held by the hook and claimFees sends the full hook balance to the controller address set at deployment. Until seeding, buyers' ETH sits in the contract under this single key.
  • [low] Controller can seed the pool before genesis sells out: partialSeed lets the controller seed the pool once 30 minutes after deployment even if genesis is not sold out, fixing the initial price from the amount actually raised and setting the genesis state complete.
  • [info] Hook takes fees via return deltas on every ETH-denominated swap: The mining reward is paid from the hook's own token balance, and the 1% fee relies on the poolManager.take and return delta mechanism. Swap and fee logic cannot be disabled, so the hook can always take fees from swaps.
  • [info] Proof-of-work mint path is permissionless: Mining difficulty is adjusted per 2016 mints and bounded to a factor of four per adjustment; nonce proofs are keyed by miner and epoch. Rewards halve every 100,000 mints.

Contract details

Verified source
Yes (Hash)
Compiler
solc 0.8.26+commit.8a97fa7a
Bytecode size
17,141 bytes
Upgradeable proxy
No
Detected patterns
erc20, return-delta, rewards

Pools using Hash