Skip to main content

GnoOwnMevEscrow

Git Source ↗

Inherits: IOwnMevEscrow

Accumulates received MEV. The escrow is owned by the Vault.

State Variables​

vault​

Vault address

address payable public immutable override vault

Functions​

constructor​

Constructor

constructor(address _vault) ;

Parameters

NameTypeDescription
_vaultaddressThe address of the Vault contract

harvest​

Withdraws MEV accumulated in the escrow. Can be called only by the Vault.

IMPORTANT: because control is transferred to the Vault, care must be taken to not create reentrancy vulnerabilities. The Vault must follow the checks-effects-interactions pattern: https://docs.soliditylang.org/en/v0.8.22/security-considerations.html#use-the-checks-effects-interactions-pattern

function harvest() external returns (uint256);

Returns

NameTypeDescription
<none>uint256assets The amount of assets withdrawn

receive​

Function for receiving MEV

receive() external payable;