Skip to main content
Flash Loans
APEXE3HQ avatar
Written by APEXE3HQ
Updated over a week ago

Decentralized Finance, or ‘DeFi’ refers to the group of projects that are aiming to bring traditional financial services to the blockchain. For example, loans, savings and insurance could all be managed and executed without the need for a centralized authority. This functionality is built on ‘smart contracts’, which exist on blockchains like Ethereum, and are automatically executed when certain conditions are met. Some of the cited advantages of using blockchain technology in this way is the fact that anybody with internet access is able to access these financial services without having to get ‘permission’ from any singular gatekeeper.

One such example of these innovative DeFi projects is ‘flash loans’, in which loanees do not have to put down any collateral to borrow from those willing to put up capital. Whilst this may sound incredibly risky to most people, the ingenuity comes in the method and speed with which the loans are repaid, with the loan and repayment happening within the same transaction, hence ‘flash loan’. If the contract sees that the loan will not be repaid, it cancels the transaction. This is useful for those looking to exploit arbitrage opportunities across markets, who can write code that executes taking out the loan, placing a trade and paying back the loan almost instantly. However, as displayed earlier this month, by two separate ‘attackers’ who made off with over $900,000 in profit by exploiting inconsistencies in the system, it is far from perfect.

To execute the first attack, the ‘trader’ first took out a loan of 10,000 ETH from DeFi lending platform ‘dYdX’. This loan was split into two, with some being used as collateral for a loan of WBTC (‘wrapped’ Bitcoin that exists on the Ethereum blockchain) from another platform called ‘Compound’. The rest of the ETH was sent to a decentralized exchange called ‘bZx’ and used to short Ethereum in favour of WBTC. Because of the lack of liquidity on this decentralized exchange, this large short caused the price of ETH to drop significantly. It was at this point that the trader swapped their WBTC for ETH on an automatic decentralized token swapper called ‘Uniswap’, which receives it’s exchange rates from bZx. Because of the skewed rates caused by the big short, the trader received a very large amount of ETH and was able to pay off the original loans, whilst taking a healthy profit. The second attack a few days later used a similar methodology.

“Many DEXs support assets that are very illiquid. Illiquidity means the markets can be moved a lot more easily. Liquidity needs to improve, which I’m confident will happen over time — there are technical and market factors that need to be overcome”
Zhuoxun Yin, Head of Operations, dYdX

These ‘attacks’ were well-researched and relied on the fact that there would be enough of a lack of liquidity on the decentralized exchanges to be able to easily skew the market in their favour. However, the events aren’t entirely damning for the future of DeFi, since extra safety protocols have been put in place on the exchanges to stop similar dumps and on the token swapper to aggregate exchange rates from more than one source. Since the DeFi space is still in the early stages, some teething problems are to be expected, however it is those left with an under-collateralized loan that pay the price.

It seems that the most robust way to trade your Digital Assets is still with the traditional, centralized exchanges, where liquidity is much greater. Using platforms like APEX:E3 can aid in finding areas of high liquidity in the Digital Asset space to avoid being burnt by any significant price manipulation. Of course, price manipulation such as this is is illegal in traditional financial markets.

The graph above shows how the price of WBTC plunged during the attack due to the large short position placed by the trader.

Try our platform HERE to access real-time digital asset analytics, related news and social media content.

Credit: Stuart Moore

Join us

Did this answer your question?