I propose to create a function in Openzeppelin to "arrest the attacker's tokens during a sandwich attack"

an additional function should be to send a message to the attacker "We advise you to file a police report that your money was seized while trying to rob another person."
It's real ?
PS although the alien spirits of a higher civilization whisper in my ear that it would be more correct to block the address, thereby prohibiting the transfer and sale for 5-10 years, thereby turning the MEV bot into a long-term holder.

If someone buys your token and are then blocking them from using them then you are actually committing a crime (at least in my country) and you could get sued. People love thinking the crypto space is the Wild West, however if your project or wallet is linked to a KYC / exchange data then people can lawfully request that information and sue you.

1 Like

In the stock market, getting ahead of yourself is considered a crime.
Also in the world there is a practice of freezing funds in a bank if the bank has a suspicion that the client is conducting suspicious transactions that may be fraud.
From such practice, I proposed such an option.
In your country, if a criminal admits that his money was frozen in an attempted scam, a criminal case is opened against him?! For example, if a successful attack from its address or an address associated with it is recorded in the node's blockchain.

true, however MEV in itself is not illegal in most countries. What you refer to is "insider trading" however the transactions that a MEV bot uses are public transactions. Which makes it public knowledge and then rules about insider knowledge does not apply.
You are however planning to illegally block funds. You are not allowed to block it unless law enforcement requires you to do so. I assume you are not law enforcement so you can not do that on your own accord. It has to come from the government/law enforcement.

For some reason people think MEV is illegal. It is not. You are publicly stating you want a minimum of X in exchange for Y. Your request is publicly message and is fulfilled according to that request. Yes the MEV bot has increased the price but it still fulfils your request for a minimum of X.

(edit typo's)