Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Rebalance vulnerable due to how slippage is calculated #142

Open
PeterMPhillips opened this issue Jun 2, 2022 · 0 comments
Open

Rebalance vulnerable due to how slippage is calculated #142

PeterMPhillips opened this issue Jun 2, 2022 · 0 comments

Comments

@PeterMPhillips
Copy link
Member

PeterMPhillips commented Jun 2, 2022

https://github.com/code-423n4/2022-05-enso-findings/issues/101

Removed from cod4rena Kanban.
We do recognize that calls to rebalance can have it's constituent trades sandwiched, but the strategy is protected somewhat loosely by its global rebalanceRange. This protection is not exact though since there is a strange dynamic with

Peter: "the problem with the rebalanceSlippage value is that it can't be easily updated and so restricts the manager's behaviour. if they have a high slippage restriction then they have to rebalance more frequently to avoid really large trades that have higher slippage. if there is a big change, then they may have to adjust the rebalanceSlippage before they can rebalance. however, if there is a large slippage tolerance then there is more risk of skimming
but because it can't be adjusted to the current market conditions, there will always be this "looseness" where the manager has to give more room for slippage and then risks getting skimmed in an mev attack
"

This may be a difficult fix. It needs some further discussion.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant