News

KiloEx Exploit Exposes Critical Flaws in DeFi Access Control: $7.5M Drained Due to Missing Checks

This year, decentralized finance witnessed one of its most striking instances of architectural fragility when KiloEx—a platform that allows for decentralized perpetual trading—was exploited for $7.5 million across several different chains, including Base, opBNB, and BNB Chain.

The breach occurred because of a single, fatal design oversight: a missing access check in a core contract. And it gets worse: the access check should have been there and should have been checked. But it wasn’t, and so KiloEx lost a whole bunch of money to a bad actor who, for all intents and purposes, shouldn’t have even been able to access the platform in the first place.

KiloEx’s internal oracle system was at the heart of the exploit. It contained a contract called KiloPriceFeed that was responsible for updating asset prices on the platform. In theory, only a designated Keeper module had the privilege to call the function `setPrices()` and push price updates. However, theory and on-chain implementation did not align.

A direct call from the Keeper to the oracle was replaced by a chain of contracts that formed a permissions path. That path was: MinimalForwarder → PositionKeeper → Keeper → KiloPriceFeed. And that’s where the problem began.

The Trust Assumption That Opened Pandora’s Box

As detailed in the analysis after the fact by the security firm SlowMist Team, the attacker found a systemic flaw a t the top of the call chain— in the MinimalForwarder contract. This contract was supposed to enable meta- transactions by relaying calls made on behalf of users, and was supposed to require no more than a proper digital signature to allow an operation to be executed. The thing is, the `execute()` function didn’t verify that the caller was legit, or that the path the call followed was a valid one.

By using a signature that was not authentic, the attacker took on the appearance of many different addresses and went through the chain of command until they got to the function named `setPrices()`, on KiloPriceFeed. From there, the rest of the attack was straightforward.

The exploiter figuratively had star performers like Marge Simpson on their resume. Yet, these operatives did real harm within the ecosystem. They manipulated asset prices with alarming frequency and severity. They would dramatically lower asset prices; open large long positions (this is a way of saying they’d bet that prices would go up); and then, with some combination of market manipulation and possibly straight-up lying, get the prices back up to where they were or above where they were when they so shamelessly crashed them.

A Failure of Architecture, Not Just a Bug

This exploit was not caused by a random edge-case bug or a clever workaround. It was the byproduct of systemic design flaws and a mistaken assumption that internal contract calls could be implicitly trusted.

Here is a breakdown of what went awry:

– Authentication was not at the top level: The contract MinimalForwarder did not check whether the caller had permission to start the transaction.

– No restrictions on the caller: The function setPrices() had no access controls, so anyone following the right call path could trigger it.

– No limits on the path: The architecture let calls go as deep as they needed to, allowing attackers to “hop” through contracts.

– Signature validation was weak: The platform did not properly check that forwarded signatures were authentic and in the correct context.

– Trust boundaries were missing: There were no guard rails to make sure that only internal, trusted contracts could reach sensitive logic.

KiloEx has, since the unauthorized withdrawal, communicated to all concerned parties that it is disabling front-end operations. The exchange is working with security partners in an effort to trace and recover the approximately 200 BTC (worth about $1.6 million at today’s prices). A patch is said to be in progress.

The actual lesson for the wider DeFi ecosystem is more profound than this specific occurrence.

A Wake-Up Call for Smart Contract Engineers

The KiloEx hack serves as a painful reminder that access control remains one of the most critical, yet commonly neglected, components in decentralized systems. In modular smart contract architectures—where logic is distributed across multiple contracts—every unchecked permission or default trust becomes a potential vulnerability.

One team failing does not equal a fault of all teams. This lesson is not just for one group; it’s a warning for every group to heed. The reason is simple: smart contracts, once deployed, are very hard to change. Much harder than changing a traditional computer program.

– Are you prioritizing development speed over security?

– Do you know with certainty who is calling your contracts and via what route?

– Are your internal modules secured as securely as your public interfaces?

Hope is not a strategy in DeFi. You have to build your systems to resist bad actors from the get-go.

Attackers do not have to be brilliant coders; all they need to be is brilliant readers. They read your code, line for line, to find the assumption you made that, if you really thought it through, you would never have made.

KiloEx identified it. The total cost was $7.5 million.

Disclosure: This is not trading or investment advice. Always do your research before buying any cryptocurrency or investing in any services.

Prev Next
No Comments

Leave a Reply

Your email address will not be published. Required fields are marked *