FEI/DAI PSM issues and solution

Thanks for your answer

Actually, the use of the Chainlink Oracle is the issue.

You can check this transaction : Ethereum Transaction Hash (Txhash) Details | Etherscan . The DAI price used was 0.9991 after the 50bps fees. With 25bps fees it would have been 1 DAI = 1.0016 FEI.

The actual Chainlink Oracle price was DAI = $1.0041, there is no evidence on that on-chain using USDC as reference. DAI was always $1 +/- trading fees (1 or 5bps). Chainlink is probably giving a good price overall (CeFi), but not on Ethereum DeFi.

With less than 41bps fees (what we expect to have) it would have been a loss for Fei Protocol. I agree, it’s not big, but it’s a useless loss that will be exploited over time. WIth 25bps fees, it would have been a 40k loss on December 28th (and an additional similar amount on non-earned fees).

Here are the details, you can see that it happened twice on December 28th.

The solution I propose is assuming we keep the same smart contract. To @fei.saver point, I think it would still work >95% of the time (as usually Chainlink price is within the narrow range, and the flashbots are never sleeping anyway). There are better ways to enable it to work all the time and provide more revenue for the protocol (and still protecting if there is an actual oracle or DAI issue), but I’m not sure it is worth the time to make a new contract.

It seems that all the good trades on the PSM are made by flashbots and all the bad by humans.

2 Likes