CoverageFundV1

Kiln

Coverage Fund (v1)

This contract receive donations for the Slashing Coverage Fund and pulls the funds into River. This contract acts as a temporary buffer for funds that should be pulled in case of a loss of money on the consensus layer due to slashing events. There is no fee taken on these funds, they are entirely distributed to LsETH holders, and no tokenss will be minted. Funds will be distributed by increasing the underlying value of every LsETH token. The fund will be called on every report, and, if ETH is available in the contract, River will attempt to pull as much ETH as possible. This maximum is defined by the upper bound allowed by the Oracle. This means that it might take multiple reports for funds to be pulled entirely into the system due to this upper bound, ensuring a lower secondary market impact. The value provided to this contract is computed off-chain and provided manually an authorized insurance entity. The Coverage Funds are pulled upon an oracle report, after the ELFees have been pulled in the system, if there is a margin left before crossing the upper bound. The reason behind this is to favor the revenue stream which depends on market and network usage, while the Coverage Fund will be pulled after the revenue stream and there won't be any commission on the ETH pulled. Once a slashing event occurs, the team will do its best to inject the recovery funds in at maximum 365 days. The entities allowed to donate are selected by the protocol. It will mainly be treasury entities or insurance protocols able to fill this coverage fund properly.

Methods

function donate() external payable

Donates ETH to the coverage fund contract

initCoverageFundV1

function initCoverageFundV1(address _riverAddress) external nonpayable

Initialize the coverage fund with the required arguments

Parameters

NameTypeDescription

_riverAddress

address

Address of River

pullCoverageFunds

function pullCoverageFunds(uint256 _maxAmount) external nonpayable

Pulls ETH into the River contract

Only callable by the River contract

Parameters

NameTypeDescription

_maxAmount

uint256

The maximum amount to pull into the system

Events

event Donate(address indexed donator, uint256 amount)

A donation has been made to the coverage fund

Parameters

NameTypeDescription

donator indexed

address

Address that performed the donation

amount

uint256

The amount donated

Initialize

event Initialize(uint256 version, bytes cdata)

Emitted when the contract is properly initialized

Parameters

NameTypeDescription

version

uint256

New version of the contracts

cdata

bytes

Complete calldata that was used during the initialization

SetRiver

event SetRiver(address indexed river)

The storage river address has changed

Parameters

NameTypeDescription

river indexed

address

The new river address

Errors

EmptyDonation

error EmptyDonation()

A donation with 0 ETH has been performed

InvalidCall

error InvalidCall()

The fallback or receive callback has been triggered

InvalidInitialization

error InvalidInitialization(uint256 version, uint256 expectedVersion)

An error occured during the initialization

Parameters

NameTypeDescription

version

uint256

The version that was attempting to be initialized

expectedVersion

uint256

The version that was expected

InvalidZeroAddress

error InvalidZeroAddress()

The address is zero

Unauthorized

error Unauthorized(address caller)

The operator is unauthorized for the caller

Parameters

NameTypeDescription

caller

address

Address performing the call

Last updated