Skip to content

Conversation

Brenzee
Copy link

@Brenzee Brenzee commented Jul 1, 2025

EnsoFlashloanShortcuts smart contract supports executing a weiroll script within a flashloan.

Supported protocols (and it's forks)

  • Euler
  • Balancer V2
  • Morpho
  • Aave v3

Comments:

  1. After weiroll script execution, contract is expected to hold enough assets to repay the flashloan amount.
  2. There are no access control for flashloan callback functions, because there are no direct risks to user funds. This contract is not meant to hold any assets, it will only hold assets during execution (same as EnsoShortcuts contract).
  3. The reason why execute function is called as this.execute(commands, state) instead of execute(commands, state) is to overcome the memory/calldata type issue for state.
  4. Protocols in the main flashLoan function are in order of usage (my opinion).

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

Successfully merging this pull request may close these issues.

2 participants