Executor
An overview of the intermediary executor contract that routes all Warlock pushes and liquidations.
Unlike other oracles, Warlock bundles liquidations with oracle updates — requiring both temporary proprietary access to oracle update flow, as well as interfaces to perform liquidations.
Executor.sol serves as Warlock’s intermediary contract to push permissioned oracle flow, execute liquidations, and provide kickbacks to partners.
More specifically, the Executor owns all temporarily permissioned flow granted by Warlock’s DataFeed. We are then able to execute liquidations through any given external protocol with a generic multicall, while returning value to partners without requiring unnecessary transfers on each liquidation.
Technical Documentation
Executor
Inherits: Multicall2
State Variables
admin
The admin which is authorized to change other static variables.
updater
The external address priveliged to execute price data updates.
dataFeed
The address of the Sauron dataFeed contract.
USDC
kickbacks
A mapping of USDC kickbacks owed to a given partner.
Functions
constructor
push
Allows the authorized address to push a price update.
Parameters
submitted
Hash.SubmittedData
The submitted price data
sig
Sig.Components
The signature of the submitted price data
pushLiquidate
Allows the authorized address to push a price update then batch calls.
Parameters
submitted
Hash.SubmittedData
The submitted price data
sig
Sig.Components
The signature of the submitted price data
encodedCalls
Call[]
The encoded calls to make
pushLiquidateKickback
Allows the authorized address to push a price update then batch calls (with internal kickbacks).
Parameters
submitted
Hash.SubmittedData
The submitted price data
sig
Sig.Components
The signature of the submitted price data
encodedCalls
Call[]
The encoded calls to make
recipient
address
The recipient of the kickback
withdrawKickback
Allows the admin to withdraw kickbacks.
Parameters
to
address
The address to send the kickback to
setDataFeed
authorized
Allows only the authorized contract to execute the method.
Errors
Exception
A single custom error capable of indicating a wide range of detected errors by providing an error code value whose string representation is documented , and any possible other values that are pertinent to the error.
Last updated