The basis spread EMA used in mark price calculation is computed over 900 snapshots instead of the intended 15-minute window, because the code passes 15 minutes as a snapshot count. This causes the mark price to lag behind market conditions for up to 2.25 hours, leading to inaccurate funding rates.
Reduce-only orders are counted towards the market's quote open interest even though they create no real exposure, so an attacker can place a tiny reduce-only buy at an extremely high price and push quoteOI towards its maximum. Once that value is near the limit, other users' buy orders overflow and revert, blocking the order book.
Liquidation orders on both the STANDARD and BACKSTOP order books are blocked whenever the best quote on the needed side lies outside the divergence band around the mark price. An attacker or ordinary market stress can therefore prevent under-margined positions from being liquidated, letting losses grow into bad debt.
The funding accrual in the perpetuals contract adds a per-interval funding amount without scaling by elapsed time, so the cumulative funding index depends on how often settlements occur rather than only on elapsed time and price. This can charge or credit users incorrect funding, distort PnL and insurance-fund flows, and potentially cause unintended liquidations.
The margin withdrawal check allows a user to withdraw all margin as long as equity (margin plus unrealised profit) meets the intended margin, leaving margin at zero. When the user later closes another position, the close logic refunds a margin delta that was already withdrawn, letting the attacker extract more than they deposited.
When the GTL vault places a post-only limit order on a new subaccount, the subaccount is not added to the vault's internal accounting until the order fills, so totalAssets omits the posted collateral. Deposits made during that window mint inflated shares, diluting existing depositors and potentially making the vault insolvent.
The addRewards function in Distributor.sol does not verify that the quoteAsset parameter is a legitimate token, allowing an attacker to supply a malicious contract as token1. By doing so, the attacker can inflate the recorded quote rewards without transferring real tokens, then drain all quote tokens from the contract and brick the system for other users.
The mint function calculates the deposited token amounts as the difference between current balances and reserves, but reserves exclude accumulated launchpad fees. An attacker can call mint directly to mint LP tokens for free, then burn them to steal funds from the pair.
The pair contract calculates the amount of tokens a user has paid in by comparing the current balance with the stored reserve, but the balance includes accrued launchpad fees while the reserve does not. An attacker can call swap with an output amount equal to the accrued fees and no actual input, tricking the contract into thinking tokens were paid in, and repeat this to drain the pair's funds.
The GTE launchpad pair contract's swap function does not actually deduct the swap fee from the transferred amounts, so the fee is never charged. An attacker could perform swaps without paying fees, causing liquidity providers to lose the fees they should earn.
The _movePop function in ClearingHouse.sol incorrectly removes the last element of the assets array instead of the intended asset when a position is closed, leaving the closed asset in place and removing an active one. This corrupts the account's asset list, potentially causing incorrect margin accounting, missed liquidations, and inaccessibility of funds.
The protocol calculates the mark price using orders that may have expired, allowing a malicious user to submit short-lived orders that manipulate the mid and impact prices. This can distort the mark price, affecting funding rates and potentially causing unfair liquidations.
The launchpad's buy function checks slippage only against the cost of tokens bought from the bonding curve, not the total purchase including the subsequent AMM swap after graduation. An attacker could cause a buyer to receive far fewer tokens than expected at an exorbitant effective price while the transaction still succeeds.
The accumulated rewards per share calculation can round down to zero when the precision factor is too small relative to total shares, so a claim adds nothing to the accumulator. Users then miss out on rewards and the funds remain stuck in the Distributor contract.
The backstop liquidation function assumes a position is fully closed when only one position remains and margin is negative, writing off the entire margin balance. However, the liquidation order is an IOC order that may be only partially filled, leaving a remaining position while the protocol absorbs the loss.
The burn function in GTELaunchpadV2Pair calculates token distribution amounts using the contract's total balances, which include accrued launchpad fees owed to the distributor. An attacker can repeatedly mint and burn LP tokens to claim a portion of these fees, potentially draining almost all liquidity from the pair.
When LaunchTokens are transferred, the Distributor pays out pending staking earnings to the LaunchPad contract instead of the token holder, because it uses the wrong recipient address. A user who receives tokens can therefore lose all the staking earnings they were entitled to.
An attacker can send a tiny donation of quote tokens to a Launchpad token's Uniswap-style pair and call sync(), leaving one reserve at zero. When graduation then calls the router's addLiquidity, the library's quote() check fails and the graduation transaction reverts, temporarily blocking the token launch.
The Launchpad contract computes a Uniswap pair address using a CREATE2 salt that omits the launchpad LP and fee distributor addresses, so it does not match the address actually deployed by the pair factory. When a user buys enough tokens to exhaust the bonding curve, the pair lookup fails and the transaction reverts, leaving the system stuck in the bonding state.
The Distributor contract reverts when adding rewards if the total shares for a token are zero, but the rewards program only ends when shares reach zero before unlocking. After unlocking, if all stakers transfer out, the pair contract still tries to distribute fees and reverts, bricking swaps and liquidity operations.
The LaunchToken contract reduces a user's bonding shares by the full transfer amount whenever they send tokens, even if the tokens being sent were received from someone else rather than originally purchased. This means a user who still holds their original tokens can lose all bonding shares and fee-sharing rights after transferring tokens they received.
The setPositionLeverage function lacks the same margin safety check as removeMargin, so a user can increase leverage to reduce the required margin and effectively withdraw margin from a profitable position that removeMargin would block. This bypasses the protocol's margin safety mechanism, potentially increasing liquidation risk.
The Launchpad contract can change its LP vault address, but the pair factory stores the vault address immutably. New pairs created after the update therefore calculate fees using the old vault while LP tokens are sent to the new vault, so no fees accrue for those pairs.
The pair factory only sets the Launchpad fee hooks when the Launchpad itself creates the token/quote pair; if anyone else creates that pair first, it becomes the canonical pair with zero hooks. As a result, the market never accrues or distributes Launchpad rewards to stakers.
The withdrawal queue is iterated in cancelWithdrawal and processWithdrawals, so an attacker could submit many small withdrawal requests to make these functions exceed the gas limit and become unusable.
A backstop order book enforces maker-only orders and a tick-size grid, so an attacker can place a sell backstop at the lowest legal price and block all future buy backstops. This freezes the bid side of the backstop book, which may prevent liquidations from relying on backstop bids.
When a user changes leverage on an open position, the system refunds margin without accounting for unrealised losses, allowing the user to withdraw margin that should cover those losses. This can create bad debt for the protocol, covered by the insurance fund.
The bonding curve contract calculates the quote amount for token purchases using integer division, which truncates fractional remainders. An attacker can make small buys that underpay for tokens, and the reduced quote reserve compounds the error over repeated purchases, draining quote tokens from the protocol.
The Launchpad's pairFor() helper derives the Uniswap V2 pair address without the extra salt values the custom factory uses, so the donation guard compares against the wrong address. An attacker could send purchased launch tokens straight into the real pair during bonding, pre-seed reserves and set the initial AMM price before graduation.
The GTL contract inherits an ERC4626 vault implementation but does not enable any of the library's built-in inflation-attack protections. An attacker could manipulate the share price so that a later depositor receives no shares, losing their funds.
GP
GTE Perps and Launchpad
Medium
Instant results are busy. Press Enter to search every report.
No direct matches. Search every report above, or try a bug class like IDOR or SSRF.