The development of smart contracts in blockchain networks has enabled the creation of sophisticated decentralized finance (DeFi) protocols, encompassing decentralized exchanges, lending platforms, and algorithmic crypto-assets. Despite decentralization and transparency, blockchain networks do not guarantee a predictable transaction execution order, leading to the emergence of the phenomenon known as Maximal Extractable Value (MEV) – an additional profit extracted by certain network participants who influence transaction ordering.
This study focuses on the empirical analysis of MEV extraction across various DeFi protocols to identify critical factors influencing the frequency and extent of MEV attacks. The research introduces a comparative methodology for evaluating MEV extraction based on a modified version of the MEV Inspect Py software suite, enhanced by newly developed components: a Price Resolver for collecting and correcting cryptocurrency price data, and a Jupyter Notebook module for detailed data analysis, comparison and visualization. An evaluation of the total volume of sandwich and arbitrage-type MEV attacks was also developed, and a method for correcting cryptocurrency price data was implemented, which improved the quality of the obtained results.
The obtained results demonstrate that Uniswap V2 and Uniswap V3 are the primary targets for MEV extraction; however, their operational mechanisms create distinct conditions for attacks. A clear correlation was identified between concentrated liquidity, pricing algorithms, and the scale of MEV exploitation. Furthermore, the findings confirm that the architectural features of DeFi protocols significantly affect their vulnerability to MEV.
These results can be employed to enhance the resilience of decentralized exchange algorithms against MEV extraction and to develop mechanisms that minimize its negative impacts on both protocol efficiency and user fairness. Moreover, the insights from this research provide valuable guidance to DeFi protocol users seeking to reduce their exposure to MEV- related risks and make more informed decisions. Future research directions include extending the analysis to MEV exploitation in blockchain networks other than Ethereum and evaluating the effectiveness of existing and emerging protective strategies.
[1] Werner, S. M., Perez, D., Gudgeon, L., Klages-Mundt, A., Harz, D., & Knottenbelt, W. J. (2021). SoK: Decentralized Finance (DeFi). https://doi.org/10.48550/arxiv.2101.08778
https://doi.org/10.1145/3558535.3559780
[2] Amazon.com: Flash Boys: A Wall Street Revolt: 9780393351590: Lewis, Michael: Books (n. d.). Retrieved August 13, 2023, from https://www.amazon.com/Flash- Boys-Wall-Street-Revolt/dp/0393351599
[3] Daian, P., Goldfeder, S., Kell, T., Li, Y., Zhao, X., Bentov, I., Breidenbach, L., & Juels, A. (2019). Flash Boys 2.0: Frontrunning, Transaction Reordering, and Consensus Insta- bility in Decentralized Exchanges. https://doi.org/10.48550/ arxiv.1904.05234
[4] Cherkas, N. S., & Batyuk, A. Ye. (2023). Maximal extractable value (mev) in blockchain networks and its impact on blockchain ecosystem. Ukrainian Journal of Information Technology, 5(2), 60-71. https://doi.org/10.23939/ujit2023.02.060
[5] Heimbach, L., Kiffer, L., Torres, C. F., & Wattenhofer, R. (2023). Ethereum's Proposer-Builder Separation: Promises and Realities. http://arxiv.org/abs/2305.19037
https://doi.org/10.1145/3618257.3624824
[6] Qin, K., Zhou, L., & Gervais, A. (2021). Quantifying Blockchain Extractable Value: How dark is the forest? https://doi.org/10.48550/arxiv.2101.05511
https://doi.org/10.1109/SP46214.2022.9833734
[7] Piet, J., Fairoze, J., & Weaver, N. (2022). Extracting Godl [sic] from the Salt Mines: Ethereum Miners Extracting Value. https://doi.org/10.48550/arxiv.2203.15930
[8] Weintraub, B., Torres, C. F., Nita-Rotaru, C., & State, R. (2022). A Flash(bot) in the Pan: Measuring Maximal Extractable Value in Private Pools. https://doi.org/10.1145/3517745.3561448
[9] Eskandari, S., Moosavi, S., & Clark, J. (2019). SoK: Transparent Dishonesty: front-running attacks on Blockchain. https://doi.org/10.48550/arxiv.1902.05164
https://doi.org/10.1007/978-3-030-43725-1_13
[10] Torres, C. F., Camino, R., & State, R. (2021). Frontrunner Jones and the Raiders of the Dark Forest: An Empirical Study of Frontrunning on the Ethereum Blockchain. https://doi.org/10.48550/arxiv.2102.03347
[11] Wahrstätter, A., Zhou, L., Qin, K., Svetinovic, D., & Gervais, A. (2023). Time to Bribe: Measuring Block Construction Markets.
[12] GitHub - flashbots/mev-inspect-py: an MEV inspector for Ethereum (n. d.). Retrieved October 7, 2024, from https:// github. com/flashbots/mev-inspect-py
[13] PostgreSQL: The world's most advanced open source database (n. d.). Retrieved March 9, 2025, from https://www. postgresql.org/
[14] Redis - The Real-time Data Platform (n. d.). Retrieved March 9, 2025, from https://redis.io/
[15] Kubernetes (n. d.). Retrieved March 9, 2025, from https://kubernetes.io/
[16] Welcome! / minikube (n. d.). Retrieved March 9, 2025, from https://minikube.sigs.k8s.io/docs/
[17] Cryptocurrency Prices, Charts, and Crypto Market Cap / CoinGecko (n. d.). Retrieved March 9, 2025, from https:// www.coingecko.com/
[18] DEX Tracker - Tool for Tracking Crypto Prices & Charts / GeckoTerminal. (n. d.). Retrieved March 9, 2025, from https://www.geckoterminal.com/
[19] Project Jupyter / Home (n. d.). Retrieved October 7, 2024, from https://jupyter.org/
[20] Z-Score: Meaning and Formula (n. d.). Retrieved March 9, 2025, from https://www.investopedia.com/terms/z/zscore. asp
[21] Nisan, Noam (2007). Algorithmic game theory. Cambridge University Press. https://doi.org/10.1017/CBO9780511800481
[22] Judmayer, A., Stifter, N., Schindler, P., & Weippl, E. (2021). Estimating (Miner) Extractable Value is Hard, Let's Go Shopping! https://github.com/
[23] Choi, N., & Kim, H. (2024). Decentralized Exchange Transaction Analysis and Maximal Extractable Value Attack Identification: Focusing on Uniswap USDC3. Electronics (Switzerland), 13(6). https://doi.org/10.3390/electronics13061098
[24] Zhou, L., Qin, K., Torres, C. F., Le, D. V., & Gervais, A. (2020). High-Frequency Trading on Decentralized On-Chain Exchanges. Proceedings - IEEE Symposium on Security and Privacy, 2021, May, 428-445. https://doi.org/10.1109/SP40001.2021.00027
[25] Luu, L., Teutsch, J., Kulkarni, R., & Saxena, P. (2015). Demystifying incentives in the consensus computer. Proceedings of the ACM Conference on Computer and Communications Security, 2015, October, 706-719. https://doi.org/10.1145/2810103.2813659
[26] Home / Uniswap Protocol (n. d.). Retrieved August 13, 2023, from https://uniswap.org/ https://doi.org/10.1007/978-1-4842-8616-6_2
[27] ncherkas/mev-inspect-py: Private fork of https://github. com/flashbots/mev-inspect-py (n. d.). Retrieved March 9, 2025, from https://github.com/ncherkas/mev-inspect-py
[28] Xu, J., Paruch, K., Cousaert, S., & Feng, Y. (2023). SoK: Decentralized Exchanges (DEX) with Automated Market Maker (AMM) Protocols. ACM Computing Surveys, 55(11). https://doi.org/10.1145/3570639
[29] Compound (n. d.). Retrieved March 9, 2025, from https://compound.finance/
[30] Aave (n. d.). Retrieved March 9, 2025, from https://aave.com/
[31] DEX by volume May 2024 (n. d.). Retrieved March 9, 2025, from https://dune.com/queries/4824483/7994859
[32] Li, Z., Li, J., He, Z., Luo, X., Wang, T., Ni, X., Yang, W., Chen, X., & Chen, T. (2023). Demystifying DeFi MEV Activities in Flashbots Bundle. CCS 2023 - Proceedings of the 2023 ACM SIGSAC Conference on Computer and Communications Security, 165-179. https://doi.org/10.1145/3576915.3616590