Thread
1) How FTX really ended up with a $10 Billion hole:
2) Nov 8th, FTX froze withdrawals due to a lack of collateral. What was one of the titans of the industry less than a month before the fall, seemingly overnight turned into a headline for one of the largest cases of fraud and financial mismanagement in over a decade.
3) The question everyone has been trying to answer since then, is how?
To begin, let’s dive into a seemingly unrelated, much smaller (but still > $100MM) DeFi exploit that happened nearly a month prior.
To begin, let’s dive into a seemingly unrelated, much smaller (but still > $100MM) DeFi exploit that happened nearly a month prior.
4) October 11th, Mango Markets, a decentralized futures exchange built on the Solana blockchain, was exploited for $114 million.
5) The protocol exploit was completed by @avi_eisen. He’s been very open about how his team pulled off the heist, claiming that it was a highly profitable trading strategy.
What happened?
What happened?
6) Mango Markets utilized a margin trading protocol allowing cross-margin between a basket of different crypto assets as collateral. They used an oracle which fed them spot prices of these assets from several major exchanges to determine the value of the collateral on the exch.
7) One of the assets that was allowed to be used for collateral was MNGO, the exchange’s native token. MNGO was extremely illiquid, and Avi realized that it would be relatively easy to manipulate the price of MNGO on the centralized exchanges that fed data into the oracle.
8) He took large positions on MM at the same time using MNGO as collateral, was able to withdraw various forms of collateral from the exchange while the position was in profit, & by the time MNGO crashed back to fair market value, the exchange was left w/ a large sum of bad debt.
9) SBF wrote a great thread detailing the mechanics of this move less than a month before FTX’s collapse – & once we’re done peering through it – I think you’ll realize the mechanics between the MNGO exploit and the explanation for the FTX balance sheet hole are eerily similar.
10) Let’s break this down tweet by tweet.
First things first, here's a link to the thread:
First things first, here's a link to the thread:
12) His fictional asset for the sake of this example is XYZ – which is supposed to represent MNGO. Now, I’m getting a bit ahead of myself here, but I also want you to start picturing XYZ as tokens such as FTT or SRM that were used as forms of collateral by Alameda on FTX.
13) In this example, Alice – the user, has $200MM of collateral in the form of XYZ marked to market, and a balance of -$25MM USD. For those who aren’t very familiar with how spot margin works, yes the USD value in this example is negative.
How is this possible?
How is this possible?
14) On a spot margin exchange if Alice has a position open & the market moves against her, rather than immediately liquidating her XYZ collateral, she instead borrows from the exch in the form USD at x% interest to those lending to her as long as she has ample maintenance margin.
15) As you can see in the next screenshot, according to the exchange’s oracle – Alice has more than enough collateral in forms of XYZ that allows this to happen (she has 87.5% margin and the exchange only requires 20% maintenance margin).
16) SBF then proposes the question – how much should the risk engine allow Alice to withdraw?
He points out that it would be naïve to allow Alice to withdraw up to $115MM, which would leave her with the required initial margin ratio of 30%.
He points out that it would be naïve to allow Alice to withdraw up to $115MM, which would leave her with the required initial margin ratio of 30%.
17) Why is this naïve?
Well, as SBF points out – holding $200MM of XYZ (MNGO) collateral, isn’t the same thing as holding $200MM of USD collateral.
Well, as SBF points out – holding $200MM of XYZ (MNGO) collateral, isn’t the same thing as holding $200MM of USD collateral.
18) Why?
In this ex. his primary point is the manipulation of MNGO price on centralized exchanges read by the oracle. (e.g. MNGO was briefly manipulated up to $0.40 when it’s true market value it was trading at prior to the illiquid pump read by the oracle was closer to $0.04).
In this ex. his primary point is the manipulation of MNGO price on centralized exchanges read by the oracle. (e.g. MNGO was briefly manipulated up to $0.40 when it’s true market value it was trading at prior to the illiquid pump read by the oracle was closer to $0.04).
19) While the oracle read that the price of MNGO was trading at $0.40, it didn’t take into account how liquid MNGO was at that price. It assumed the entire position size could be liquidated at the value of MNGO marked to market price.
20) What SBF recognizes here is that utilizing a marked to market price for MNGO is incredibly poor logic. There aren’t enough buyers at $0.40 to liquidate a $200MM position. In reality, there might be enough to liquidate closer to $20MM.
21) The oracle doesn’t take this into account, and allows Alice to withdraw a large amount of USD before the price of MNGO begins to retrace.
What does this mean for everyone else on the platform?
What does this mean for everyone else on the platform?
22) Alice withdrew $100MM when the fair market value of her collateral was really closer to $20MM. She used the system within the framework of how it was built, but in the process she paid herself w/ other users funds & left them w/ bad debt in the form of MNGO.
23) So, as SBF so elogantly puts it – did the oracle fuck up?
Not really, because the oracle accurately reported the *current* price of MNGO. As he says, AND THIS IS IMPORTANT, the ‘current price’ wasn’t really anything close to the ‘fair price’.
Not really, because the oracle accurately reported the *current* price of MNGO. As he says, AND THIS IS IMPORTANT, the ‘current price’ wasn’t really anything close to the ‘fair price’.
24) Don’t miss this.
He admits, the ‘current price’ of the shitcoin used as collateral wasn’t really ANYTHING CLOSE to the ‘fair price’.
He admits, the ‘current price’ of the shitcoin used as collateral wasn’t really ANYTHING CLOSE to the ‘fair price’.
25) THIS IS WHAT HAPPENED TO FTX. It’s important to remember that on a cross margin exchange, THE COLLATERAL USED ON YOUR EXCHANGE ARE DIRECT LIABILITIES. Here’s a link to FTX’s “Collateral Management” policies. help.ftx.com/hc/en-us/articles/360031149632
26) As you can see in the screenshots from the “List of Non-USD Collateral”, these tokens were given a weighted discount, but there was no policy that affected the weight as the size of the collateral increased.
FTT was given a weight of 0.95, SOL a weight of 0.9, SRM 0.95, etc.
FTT was given a weight of 0.95, SOL a weight of 0.9, SRM 0.95, etc.
27) These might be fair values for a position size of $10K, or maybe even $1MM for a more liquid token like SOL. The issue was, Alameda was utilizing the above collateral for TENS OF BILLIONS of dollars.
28) Here’s a screenshot of some of the assets FTX was left with after its implosion. Notice how there “less liquid” collateral deliverables for the week prior to the insolvency included $5.9B of FTT, $5.4B of SRM, $2.2B of SOL, etc.
Source:
Source:
29) Using the same logic SBF mapped out for the MNGO example, Alameda could have easily opened up positions worth BILLIONS of dollars against this collateral – because the FTX spot margin risk engine only discounted the value of those positions 5 to 10%, regardless of their size.
30) Like in the example with Avi and MNGO, there might have been a time where they were up BILLIONS on these positions and could have easily withdrawn that profit in the form of USD, BTC, or ETH.
31) The issue here is that they were extracting real value, while putting up monopoly money against it.
They never should have been allowed to open positions that large in the first place.
They never should have been allowed to open positions that large in the first place.
32) Nobody in their right minds would allow a token like SRM, which had a market cap value of $200MM based on the marked to market value of the circulating supply of the tokens, would have allowed that same token to be used as nearly $5B of collateral on the exchange.
33) This implies that a large portion of that “less liquid” collateral that Alameda was using was locked! SRM also only had an average daily volume of <$20M.
FTT wasn't much better - though it was propped up by the weekly "buy and burns" funded from a % of exchange fees.
FTT wasn't much better - though it was propped up by the weekly "buy and burns" funded from a % of exchange fees.
34) There should have been some system in place that accounted for the true fair market value of the asset based on general market liquidity metrics.
As SBF pointed out – “the ‘current price’ of the shitcoin used as collateral wasn’t really ANYTHING CLOSE to the ‘fair price’.”
As SBF pointed out – “the ‘current price’ of the shitcoin used as collateral wasn’t really ANYTHING CLOSE to the ‘fair price’.”
35) Let’s continue down SBF’s Mango Markets thread, because he does a great job of explaining what systems FTX had in place that were supposed to prevent this type of an event.
Ironically, SBF contrasts the exploit of Mango Markets with FTX’s success.
Ironically, SBF contrasts the exploit of Mango Markets with FTX’s success.
36) EWMA stands for Exponentially Weighted Moving Average.
This is a decent system.
It does do a good job of preventing over-utilization of collateral during *brief* price spikes like what was experienced by MNGO.
help.ftx.com/hc/en-us/articles/360027946651-Order-Limits-and-Price-Bands
This is a decent system.
It does do a good job of preventing over-utilization of collateral during *brief* price spikes like what was experienced by MNGO.
help.ftx.com/hc/en-us/articles/360027946651-Order-Limits-and-Price-Bands
38) It does have some weaknesses though.
Here’s one example – MOB had something similar happen to what happened with MNGO, it just happened over the course of days rather than a couple of minutes. Apparently that exploit led to a $1B loss by Alameda.
Here’s one example – MOB had something similar happen to what happened with MNGO, it just happened over the course of days rather than a couple of minutes. Apparently that exploit led to a $1B loss by Alameda.
39) The second risk management practice SBF points out are the use of IMF Factors.
IMF Factors are great, and they’re completely necessary for a margin exchange.
help.ftx.com/hc/en-us/articles/360024780511-Complete-Futures-Specs
IMF Factors are great, and they’re completely necessary for a margin exchange.
help.ftx.com/hc/en-us/articles/360024780511-Complete-Futures-Specs
40) Why?
As the size of the position a trader wants to open increases, so does the margin requirement for said position depending on the liquidity of the token.
As the size of the position a trader wants to open increases, so does the margin requirement for said position depending on the liquidity of the token.
41) It basically does its best to limit a traders ability to open a massive position on an extremely illiquid shitcoin that can easily be manipulated higher without ensuring a large amount of collateral is present to do so.
42) Point 17) is where SBF and FTX’s logic starts to have some massive flaws. He asks the question “And what if you try to use something other than dollars as collateral? Well, we haircut it. In some cases, a lot.”
43) As discussed previously, this isn’t true. Their definition of a large haircut is a weighted cut ranging from 5-20% off the total m2m price of the token. There are no factors such as IMF for calculating fair market price of collateral as the size of the collateral increases.
44) Here's a link to FTX's spot margin trading page.
help.ftx.com/hc/en-us/articles/360053007671-Spot-Margin-Trading-Explainer
help.ftx.com/hc/en-us/articles/360053007671-Spot-Margin-Trading-Explainer
45) SBF makes the point that FTX US derivatives would only be for BTC / ETH futures using strictly USD margin. He almost jokingly points out using no MNGO collateral, which is jokingly pointing out the risk of using a shitcoin’s m2m value as collateral for a futures position.
46) SBF ends his thread by coming full circle, returning back to the oracle reporting the value of MNGO as $0.40. He asks “Is it wrong?”.
His answer: “It depends on what it’s promising.”
His answer: “It depends on what it’s promising.”
47) As he shares in his last points in his thread, SBF’s promise is that FTX was created to help create a trading platform founded upon a set of rules that’s conservative & handles large moves gracefully – that “there was an opening for a thoughtfully automated risk engine.”
48) He broke that promise – and he did it knowingly.
49) He has lied about being ignorant to the size of Alameda’s position.
He's known what they used for collateral on the platform and what their position sizes looked like this whole time.
He's known what they used for collateral on the platform and what their position sizes looked like this whole time.
50) Here's another example from last year, stating "If only people knew how balls long crypto Alameda has been"
Interesting thing to tweet out if you're completely ignorant to their positions.
Interesting thing to tweet out if you're completely ignorant to their positions.
51) He was fully aware of the fact that they were using billions of dollars of illiquid collateral as a backdoor to extract real value from customers in the same way that Avi did with Mango Markets.
52) You could possibly even argue that Sam Trabucco and Caroline Ellison are more akin to Avi than anyone else in this scenario. That they just operated within the framework of a broken system to execute a “highly profitable trading strategy”.
53) Sam Bankman-Fried knowingly facilitated this strategy. He allowed his venture capital fund to take out grossly oversized positions with monopoly money, that the risk engine calculated as being real.
54) SBF's direct admission that there was a period of time where wire transfers were sent to Alameda, and that a portion of them may have actually ever ended up making it on to the FTX platform also can't be overlooked.
55) Either way, it's very clear that he was fully conscionable of the impacts of allowing large, illiquid shitcoins to be used as collateral w/ a marked to market method. That’s clear from his thread he wrote about Mango Markets.
Don’t let him fool you into believing otherwise.
Don’t let him fool you into believing otherwise.
56) If you missed my space yesterday discussing some of the issues above, it's definitely worth a listen ⬇️
twitter.com/i/spaces/1lPJqBDWbodxb?s=20
twitter.com/i/spaces/1lPJqBDWbodxb?s=20
57) If you enjoyed the thread, make sure to check out my newsletter where I plan on continuing to share more relevant news about the crypto market ⬇️
(it's also way easier to read than this lol)
www.getrevue.co/profile/cryptokaleo?via=twitter-profile
(it's also way easier to read than this lol)
www.getrevue.co/profile/cryptokaleo?via=twitter-profile