Badger Finance
Search…
Tree Summary

Summary

The Badger tree yielding coins
Badger Tree is a central rewards management contract that uses the magic of Merkle trees to distribute rewards from across the system to users. This allows users to realize their gains from all liquidity mining programs, special Sett rewards, and any other rewards programs in the Badger ecosystem in one place at very low cost.
The claimable values are updated on a schedule decided upon by the DAO. The default is every 4 hours. The DAO elects one or more "RootUpdater" accounts that are the permission to update the Merkle root.

How it works

Each Merkle tree uploaded specifies a mapping of each user to their total accumulated rewards, across every token for which rewards are distributed. The reward amounts are generated by tracking on-chain conditions and events via an open source script (Such that any user can independently verify it).
An appointed Guardian account must sign off on any new Root before it is made official.
The BadgerTree contract tracks the cumulative amount of rewards claimed by the user, allowing them to claim their full unclaimed reward balance from across the system at once.
The full data of each Merkle tree, along with UI-friendly metadata, is uploaded to IFPS by the RootUpdater. The IPFS content hash and corresponding Merkle root are published to the contract on update.

Permissions

    The Admin has the rights to add or remote RootUpdaters
    RootUpdaters can propose new Merkle roots with corresponding IPFS content hashes
    The Guardian (also elected by the DAO) can approve proposed merkle roots, and pause the contract in an emergency situation.
      The Guardian is expected to be running scripts independently to confirm every root.

Other Safeguards

The contract is aware of the total amount of each given token should be available for claiming at any given time.
Funds to be distributed via the BadgerTree are held in the RewardsEscrow to prevent malicious roots from allowing more tokens to be claimed than expected.
New roots do not become active until the guardian has 'signed off' on the root via an approval transaction.
Last modified 6mo ago