Trading through decentralized exchanges (DEXs) has become crucial in today's blockchain ecosystem, enabling users to swap tokens efficiently and automatically. However, the capacity of miners to strategically order transactions has led to exploitative practices (e.g., front-running attacks, sandwich attacks) and gain substantial Maximal Extractable Value (MEV) for their own advantage. To mitigate such manipulation, Ferreira and Parkes recently proposed a greedy sequencing rule such that the execution price of transactions in a block moves back and forth around the starting price. Utilizing this sequencing rule makes it impossible for miners to conduct sandwich attacks, consequently mitigating the MEV problem. However, no sequencing rule can prevent miners from obtaining risk-free profits. This paper systemically studies the computation of a miner's optimal strategy for maximizing MEV under the greedy sequencing rule, where the utility of miners is measured by the overall value of their token holdings. Our results unveil a dichotomy between the no trading fee scenario, which can be optimally strategized in polynomial time, and the scenario with a constant fraction of trading fee, where finding the optimal strategy is proven NP-hard. The latter represents a significant challenge for miners seeking optimal MEV. Following the computation results, we further show a remarkable phenomenon: Miner's optimal MEV also benefits users. Precisely, in the scenarios without trading fees, when miners adopt the optimal strategy given by our algorithm, all users' transactions will be executed, and each user will receive equivalent or surpass profits compared to their expectations. This outcome provides further support for the study and design of sequencing rules in decentralized exchanges.
翻译:通过去中心化交易所(DEX)进行交易已成为当今区块链生态系统中至关重要的一环,使用户能够高效且自动地交换代币。然而,矿工策略性地排序交易的能力导致了剥削性行为(例如,抢先交易攻击、三明治攻击),并为他们自身谋取了大量最大可提取价值(MEV)。为了减轻这种操纵,Ferreira 和 Parkes 最近提出了一种贪婪排序规则,使得一个区块内交易的执行价格围绕起始价格来回波动。利用这种排序规则,矿工无法进行三明治攻击,从而缓解了 MEV 问题。然而,没有任何排序规则能阻止矿工获得无风险利润。本文系统地研究了在贪婪排序规则下,矿工为最大化 MEV 而采取的最优策略的计算问题,其中矿工的效用由其持有代币的总价值衡量。我们的结果揭示了无交易费用场景与存在恒定比例交易费用场景之间的二分性:前者可以在多项式时间内找到最优策略,而后者被证明是 NP-hard 问题,这为寻求最优 MEV 的矿工带来了重大挑战。根据这些计算结果,我们进一步展示了一个显著现象:矿工的最优 MEV 同样惠及用户。确切地说,在无交易费用的场景中,当矿工采用我们算法给出的最优策略时,所有用户的交易都将被执行,每位用户将获得与预期相当或更优的收益。这一结果为去中心化交易所中排序规则的研究与设计提供了进一步支持。