Roles and permissions
Three groups control different parts of YieldBasis: the YB DAO, the Curve DAO, and the Curve Emergency DAO. Each group has a section with its main powers, and some powers overlap. The last section covers pool policies, which more than one group controls.
YB DAO
veYB holders, who lock YB for voting power, vote on proposals in the YB DAO, the governance DAO of YieldBasis. The YB DAO controls these contracts and roles:
- GaugeController, the contract that tallies gauge votes and mints YB emissions: adds gauges, and kills or revives them.
- FeeDistributor, the contract that pays admin fees to veYB holders: sets the token set (the yb-LP tokens that it pays), kills distribution, and recovers tokens.
- FeeSplitter, the contract that receives admin fees from the markets: sets the share of admin fees for the net-pressure reserve, and the rest goes to veYB holders. The net-pressure reserve funds a bonus for crvUSD liquidity in a Curve pool. To read the reserve share, call
split_fraction()on the FeeSplitter (1e18= 100%). - The admin role of the YB Factory, the contract that deploys each market. The YB DAO holds this role through HybridFactoryOwner. The role covers market parameters such as the fee of LEVAMM (the market's leveraged AMM), the borrow rate, and crvUSD allocations. It also lets the YB DAO kill or revive a market (
HybridFactoryOwner.lt_set_killed). - Each oracle-report policy (
YBOraclizedPolicy) that it owns: the policy fee and price-target settings, the price-report verifier, and the kill switch. Pool policies covers these settings and links to their limits.
For the address of each of these contracts, read Contract addresses.
Curve DAO
veCRV holders, who lock CRV for Curve voting power, vote through the Curve ownership voting contract 0xE478de485ad2fe566d49342Cbd03E49ed7DB3356. The admin of the Curve Twocrypto pool factory for the Curve Cryptoswap pools of YieldBasis markets is an owner proxy (0x97aA696e37659Fb4f0B53824246d802Df40E980A). The proxy has two roles:
dao: the Curve Ownership Agent (0x40907540d8a6C65c637785e8f8B742ae6b0b9968). Only this role can callexecute().emergency_dao: the Curve Emergency DAO. This role can callemergency_parametersonly.
Only the Curve DAO path, through execute(), can change two pool settings:
reserved_profit_fraction: the protected share of pool profit, which recenteringprice_scale, the pool's internal price, cannot spend.- The pool
admin_fee: a Curve DAO share of that protected profit.
The Curve DAO and the Curve Emergency DAO can both change the pool fee parameters (mid_fee, out_fee, fee_gamma), the adjustment step, and the moving-average time. They use emergency_parameters on the owner proxy. On a pool whose policy returns a fee above zero, the pool uses the policy fee instead of mid_fee and out_fee.
For the Curve DAO's control over which policy a pool runs, read Pool policies.
Curve Emergency DAO
The Curve Emergency DAO is a Safe multisig. This multisig is the YB Factory emergency admin and the EMERGENCY_ADMIN of each oracle-report policy (YBOraclizedPolicy). It can take these actions:
- Kill or revive a market (
LT.set_killed), with no YB DAO vote. - Kill or revive a YBOraclizedPolicy, with no Curve DAO vote.
- Change the fee and adjustment parameters of a market's Curve pool through
emergency_parameterson the pool owner proxy, with no Curve DAO vote. - In a killed market, withdraw a holder's position or redeem staked yb-LP from a gauge. The funds go to the holder, not to the emergency admin.
The Curve Emergency DAO cannot veto YB DAO proposals, because the voting plugin has no veto function.
For the address of the multisig, read the emergency admin row in Core contracts in Contract addresses.
Pool policies
A pool policy is a contract that a market's Curve Cryptoswap pool calls to set its swap fee, its price_scale target, or both. The price_scale target is the price that the pool's internal price moves toward.
After a pool's one-time initialization, only a Curve DAO vote can attach, replace, or remove its policy (set_policy_contract). The YB DAO and the Curve Emergency DAO cannot. At deployment, the deployer could attach a policy in initialize() before the first deposit without a vote.
The YB DAO owns each oracle-report policy (YBOraclizedPolicy) and can change its settings only within limits in the code. For the limits, read Dev: Pool policy — governance limits.
Price reports are signed Pyth Pro (Pyth Lazer) prices that traders deliver to the policy. The verifier, a Pyth contract that checks their signatures, decides which price reports the policy accepts. The owner chooses the verifier, which is a full trust point for price authenticity.
The YB DAO or the Curve Emergency DAO can kill an oracle-report policy. For what changes when a policy is killed, read What can go wrong in Pool policies.
A pool that runs YBTwocryptoPolicy has a policy with no owner, no settings, and no kill switch. To see which policy a pool runs, call POLICY() on the pool or read the pool policies table in Contract addresses. For how each policy sets fees and the price target, read Pool policies.
Related
- Proposals: how a YB DAO proposal passes and executes.
- Pool policies: how each policy sets the swap fee and the price target, and the effect of a kill.
- Contract addresses: the address of each contract and multisig that this page names.
- Risks: the governance and emergency risks that come with these roles.