{"hook":"0xF6fBD259Fd80be4Dc9131eFd7Ed6F2089aA6E0cC","block":93144847,"bits":8396,"flags":[{"bit":13,"key":"beforeInitialize","label":"Before initialize","risk":0,"does":"Runs once, when a pool is created.","fn":"beforeInitialize(address,(address,address,uint24,int24,address),uint160)","on":true},{"bit":12,"key":"afterInitialize","label":"After initialize","risk":0,"does":"Runs once, right after a pool is created.","fn":"afterInitialize(address,(address,address,uint24,int24,address),uint160,int24)","on":false},{"bit":11,"key":"beforeAddLiquidity","label":"Before add liquidity","risk":1,"does":"Can refuse a deposit, or only let some addresses provide liquidity.","fn":"beforeAddLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),bytes)","on":false},{"bit":10,"key":"afterAddLiquidity","label":"After add liquidity","risk":0,"does":"Runs after each deposit.","fn":"afterAddLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),int256,int256,bytes)","on":false},{"bit":9,"key":"beforeRemoveLiquidity","label":"Before remove liquidity","risk":2,"does":"Can refuse a withdrawal. LPs may not get out.","fn":"beforeRemoveLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),bytes)","on":false},{"bit":8,"key":"afterRemoveLiquidity","label":"After remove liquidity","risk":0,"does":"Runs after each withdrawal.","fn":"afterRemoveLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),int256,int256,bytes)","on":false},{"bit":7,"key":"beforeSwap","label":"Before swap","risk":1,"does":"Runs before every swap. On a dynamic-fee pool it can set the fee each time.","fn":"beforeSwap(address,(address,address,uint24,int24,address),(bool,int256,uint160),bytes)","on":true},{"bit":6,"key":"afterSwap","label":"After swap","risk":0,"does":"Runs after every swap.","fn":"afterSwap(address,(address,address,uint24,int24,address),(bool,int256,uint160),int256,bytes)","on":true},{"bit":5,"key":"beforeDonate","label":"Before donate","risk":0,"does":"Runs before a donation to LPs.","fn":"beforeDonate(address,(address,address,uint24,int24,address),uint256,uint256,bytes)","on":false},{"bit":4,"key":"afterDonate","label":"After donate","risk":0,"does":"Runs after a donation to LPs.","fn":"afterDonate(address,(address,address,uint24,int24,address),uint256,uint256,bytes)","on":false},{"bit":3,"key":"beforeSwapReturnDelta","label":"Before swap returns delta","risk":2,"does":"Can take part of what you put into a swap, or change how much is swapped.","fn":null,"on":true},{"bit":2,"key":"afterSwapReturnDelta","label":"After swap returns delta","risk":2,"does":"Can take part of what you get out of every swap.","fn":null,"on":true},{"bit":1,"key":"afterAddLiquidityReturnDelta","label":"After add returns delta","risk":2,"does":"Can charge LPs on the way in.","fn":null,"on":false},{"bit":0,"key":"afterRemoveLiquidityReturnDelta","label":"After remove returns delta","risk":2,"does":"Can take part of what LPs withdraw.","fn":null,"on":false}],"code":{"size":4049,"selectors":["0x01785603","0x21d0ee70","0x259982e5","0x575e24b4","0x6c2bbe7e","0x6fe7e6eb","0x817db73b","0x8322fff2","0x91dd7346","0x9f063efc","0xb47b2fb1","0xb5217bb4","0xb6a8b0fa","0xc45a0155","0xcbb68618","0xd55be8c6","0xdc4c90d3","0xdc98354e","0xe1b4af69"],"delegatecall":false,"selfdestruct":false,"create":false,"calls":5,"addresses":[]},"proxy":{"implementation":null,"admin":null,"beacon":null,"clone":false},"owner":null,"functions":[{"selector":"0x01785603","name":"pendingFees(bytes32)"},{"selector":"0x21d0ee70","name":"beforeRemoveLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),bytes)"},{"selector":"0x259982e5","name":"beforeAddLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),bytes)"},{"selector":"0x575e24b4","name":"beforeSwap(address,(address,address,uint24,int24,address),(bool,int256,uint160),bytes)"},{"selector":"0x6c2bbe7e","name":"afterRemoveLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),int256,int256,bytes)"},{"selector":"0x6fe7e6eb","name":"afterInitialize(address,(address,address,uint24,int24,address),uint160,int24)"},{"selector":"0x817db73b","name":"collectFees(bytes32)"},{"selector":"0x8322fff2","name":"ETH()"},{"selector":"0x91dd7346","name":"unlockCallback(bytes)"},{"selector":"0x9f063efc","name":"afterAddLiquidity(address,(address,address,uint24,int24,address),(int24,int24,int256,bytes32),int256,int256,bytes)"},{"selector":"0xb47b2fb1","name":"afterSwap(address,(address,address,uint24,int24,address),(bool,int256,uint160),int256,bytes)"},{"selector":"0xb5217bb4","name":"pools(bytes32)"},{"selector":"0xb6a8b0fa","name":"beforeDonate(address,(address,address,uint24,int24,address),uint256,uint256,bytes)"},{"selector":"0xc45a0155","name":null},{"selector":"0xcbb68618","name":"register((address,address,uint24,int24,address),address,uint16)"},{"selector":"0xd55be8c6","name":"MAX_FEE_BPS()"},{"selector":"0xdc4c90d3","name":"poolManager()"},{"selector":"0xdc98354e","name":"beforeInitialize(address,(address,address,uint24,int24,address),uint160)"},{"selector":"0xe1b4af69","name":"afterDonate(address,(address,address,uint24,int24,address),uint256,uint256,bytes)"}],"history":{"pools":8,"firstTime":1789684233,"lastTime":1789832538},"pools":[{"id":"0xbdafa158d1ca8e4f21834ca66acb46cf6b73f12d5eefc702ea91f380843bbe06","key":{"currency0":"0x0000000000000000000000000000000000000000","currency1":"0xd60F466bc10ed83695b2B9dD10C1Fe3bd6859aD5","fee":0,"tickSpacing":200,"hooks":"0xF6fBD259Fd80be4Dc9131eFd7Ed6F2089aA6E0cC"},"symbols":["ETH","AGI"],"state":{"sqrtP":"2478021006120592457140883785284147","tick":207023,"protocolFee":0,"lpFee":0,"liquidity":"31690866724818180046727"},"swaps":[{"zeroForOne":true,"ok":true,"amountIn":"293110095706789","paid":"293110095706789","got":"272323955466706645805251","expected":"286652650188454029412663","feePpm":0,"takePpm":49987},{"zeroForOne":false,"ok":true,"amountIn":"495597972704016690953153","paid":"495597972704016690953153","got":"481044478220066","expected":"506362608652701","feePpm":0,"takePpm":50000}],"roundTrip":{"ok":true,"lossPpm":1,"added":["-3860096105092","-3040458480300715605708"],"removed":["3860096105091","3040458480300715605707"]}},{"id":"0x2a9388cd1141dcf526faf074b66054d45cc915abb0d6c41677eb045927e1639d","key":{"currency0":"0x0000000000000000000000000000000000000000","currency1":"0xc3F286B2a0412a4dFe45854319f51EdD68994Eaa","fee":0,"tickSpacing":200,"hooks":"0xF6fBD259Fd80be4Dc9131eFd7Ed6F2089aA6E0cC"},"symbols":["ETH","STAKDOG"],"state":{"sqrtP":"2476509868809061262966534574920204","tick":207010,"protocolFee":0,"lpFee":0,"liquidity":"31690866724818180046727"},"swaps":[{"zeroForOne":true,"ok":true,"amountIn":"138544585498854","paid":"138544585498854","got":"132641197916922620761749","expected":"135347791278382528789941","feePpm":0,"takePpm":19998},{"zeroForOne":false,"ok":true,"amountIn":"495295749039962806801805","paid":"495295749039962806801805","got":"496538153481154","expected":"506671585184851","feePpm":0,"takePpm":20000}],"roundTrip":{"ok":true,"lossPpm":1,"added":["-3921922309175","-2980013747489938775451"],"removed":["3921922309174","2980013747489938775450"]}}],"openCallbacks":[],"checks":[{"id":"01","title":"Permissions that touch your money","status":"caution","detail":"The address enables before swap returns delta, after swap returns delta. The hook is allowed to take; the next two checks measure whether it does."},{"id":"02","title":"What it takes from a swap","status":"caution","detail":"It takes 5% of each swap on top of the pool fee."},{"id":"03","title":"LPs can get out","status":"pass","detail":"Liquidity added and removed in the same block came back whole."},{"id":"04","title":"The fee is the fee","status":"pass","detail":"A fixed fee of 0%, written in the pool key."},{"id":"05","title":"No one holds the switch","status":"caution","detail":"No owner() but it has collectFees."},{"id":"06","title":"The code cannot change","status":"pass","detail":"Not a proxy, no DELEGATECALL, no SELFDESTRUCT."},{"id":"07","title":"Only the PoolManager can call it","status":"pass","detail":"Each callback refused a call that did not come from the PoolManager."},{"id":"08","title":"Track record","status":"pass","detail":"8 pools over 32 days."}],"score":75,"verdict":"caution"}