Rari Capital
Published in

Rari Capital

Unexpected Liquidity Migration Caused False Liquidation Event

Today, September 17, 2021:

The FRAX-ETH liquidity pool was reduced to nearly zero due to a strong shift in liquidity between DEXs, combined with MEV bot transactions, this low level of liquidity led to a uniquely easy to manipulate on-chain price. The first issue was a greatly lowered level of liquidity, in the feeds that the oracle network was configured to monitor, this configuration by the oracle networks users created this initial issue. The FRAX-ETH price oracle network reports data based on parameters/liquidity sources defined by users. As a standard security best practice, Chainlink users are required to notify oracle node operators of liquidity migrations to allow enough time for price feeds to be updated to accurately track active liquidity pools. That lack of notice of a liquidity migration, created a low liquidity environment, where flashbots were able to act more easily, as they regularly do in various low liquidity DEX markets. Part of the risk here was using a pair that was only powered by DEX data, which rapidly became lower in volume.

There were six users impacted, each of whom were borrowing FRAX between several Fuse pools.

At block height 13243822, an MEV bot in response to a large FXS buy order on the FRAX-FXS pair:


Then it was sandwiched by this flashbotted transaction on the FRAX-ETH pair bringing the price of FRAX close to 2x against ETH within the remaining block. Here FRAX is almost $2 in the FRAX-ETH pair:


At this time, the price of FRAX-ETH is almost $2. Afterwards, the price of FRAX-ETH returns back to $1.00.

At block height 13243849, Chainlink oracle network submitted a FRAX-ETH price of close to $2, reflecting the price during that previous period of time, after the aggregation and submission process:


In this transaction, the oracle nodes for the FRAX/ETH Chainlink feed reported a range of answers, some of which were correct, while others were incorrect due to the manipulated liquidity sources lower volume. This drop in liquidity made it substantially easier for an MEV flashbot to manipulate the DEX markets tracked by the oracles, markets that were sufficiently high in liquidity when they were initially configured to be tracked by users.

​​We have now migrated the FRAX-ETH feeds to FRAX-USD feeds and have confirmed that these feeds are accurately reporting pricing information. We will continuously monitor the feeds for invariance and invoke failsafes if the deviation is off.

We really appreciate all of the messages from our community and users involved in this incident. The goal of this post is to inform individuals of every detail of this incident.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store