0xSh1r0 Profile picture
Jun 30 11 tweets 4 min read
The recently launched Zeromev by @pmcgoohanCrypto has shed light on the dark forest of #MEV.

#MEV had been harmful to us, crypto users. Here's what you need to know about the impact of MEV and how to avoid it.

A thread🧵

1/10
Let's look into the most occurred MEV on Zeromev: Sandwich attack.

What happened here:
1. A victim's tx (swapping $ETH for $USDC) was sandwiched and received a worse swap rate
2. An attacker net a profit from frontrun (sell $ETH at high price) and backrun (buy $ETH at low)

2/10
Let's dive into the txs details

1. Frontrun tx

An attacker
- sold 169.12 $ETH for 183,725 $USDC (avg sold price = 1,086.36)
- paid 0.008 $ETH as tx fee

Now, $ETH price decreased as there are more $ETH and less $USDC in the pool.

3/10
2. Sandwich tx

The victim
- sold 450 $ETH for 487,972 $USDC

The tx further decreased $ETH price.

4/10
3. Backrun tx

An attacker
- bought 169.4 $ETH using 183,725 $USDC gained from the frontrun tx (avg bought price = 1,084.56)
- paid 0.27 $ETH as tx fee

5/10
From frontrun and backrun tx, the attacker
- net 0.002 $ETH free money (mostly the earning is paid to miner for Gas Price Auction)

6/10
But how much did the victim lose?

If there was no frontrun and backrun, the victim would get 488,749 $USDC from selling 450 $ETH, an extra 777 $USDC!

7/10
So why did this occur?

The victim allowed some price slippage when using the swap router.

Low price slippage: before your tx gets executed, the price may alr move, so your tx will be rejected.

High slippage: you accept a worse swap price and are prone to sandwich attack.

8/10
How can you avoid MEV?

One solution provided by Zeromev is to use Layer 2 chains with first come first serve (FCFS) implemented e.g. @arbitrum. FCFS ensures your txs are executed in order of arrival time. No more frontrun.

9/10
If you find the thread helpful, Like, Retweet, and Follow me @0xSh1r0 for more threads like this.

10/10

Also, like this tweet if you want to know how to calculate the victim's loss.

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with 0xSh1r0

0xSh1r0 Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @0xSh1r0

Jun 16
The current #BEAR market hits hard. I've listed out some strategies you can do to earn juicy APRs.

Disclaimer: Farming strategies can be on different chains. You may need to bridge your asset.

The strategies do not come without risks. Please DYOR!!!

Let's start. 🧵

1/
Strategy 1 : Stablecoin Farming

Stablecoin pools like @CurveFinance normally offer low-risk stable income but earn little APY. However, @defi_sunio provides farmers with a whopping 30%+ APY on their stableswap pools.

sun.io/#/stake?search…

2/
@CurveFinance @defi_sunio But there is a caveat.

There are rumors about @justinsuntron game on $USDD and $TRX. There is a chance $USDD will suffer the same fate as $LUNA/$UST. But in the short run, I think it is safe to assume it will not depeg.

3/
Read 15 tweets
May 14
Regards to the current potential crisis $stETH - $ETH can lead to, here's an ELI5 on what's happening

🧵
1/ For context, $stETH is a token that represents a share of staked $ETH on @LidoFinance to earn 3.6% APR.

1 $stETH (theoretically) == 1 $ETH.

$stETH is only redeemable for staked $ETH after the ETH2.0 merge. Image
@LidoFinance 2/ Each stETH is backed by locked ETH, so it’s fully collateralized. Even if stETH price dumps or pumps, there’s literally no effect on the actual staking/unstaking mechanism.

Users can `set it and forget it`, risk-free.
Read 13 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(