VeVault Architecture

Protocol-agnostic auto-compounding liquid locker for veNFTs

How It Works

Users deposit permanently-locked veNFTs into the vault and receive a fungible ERC-20 token (llToken) representing their share. The vault claims rewards, swaps them to the underlying token, and locks more into the veNFT — increasing the NAV per token over time.

User VeVault Protocol ──── ─────── ──────── │ │ │ │ transfer veNFT │ │ │ ──────────────────────────>│ merge into primary veNFT │ │ │ ─────────────────────────────>| │ receive llToken 1:1 │ │ │ <──────────────────────────│ │ │ │ │ │ hold llToken │ weekly: executeEpoch() │ │ (NAV grows over time) │ ─────────────────────────────>│ │ │ claim rewards → compound │ │ │ <─────────────────────────────│

Contract Structure

Core Vault
VeVault
0xA3daFa7B35DA8343E7F9134799C732685E5eEe8D
Wrapper Token
llDUST
0xE1ea92e10d1DdF0e27667bC9a43B807413123D1c
Adapter
Neverland
0x110892FefD165b14749423e210E1e60d39A42EB3
Swap Router
SwapAdapter
0x8EC6ca5384f59F66Db24419D4169a89834cdb1D9
Oracle
TWAP
0x86Fc0475A238200Fac6dBc6685611410B43f07a8
Revenue
10% fee
0x298990749E771eCBD86E2adbE2AC663F60C28CDF

The Three Regimes

NORMAL Compound

Default steady-state. USDC is swapped to DUST and locked into the veNFT. totalLocked increases while supply stays constant — NAV per token rises.

DISCOUNT Buyback + Burn

When llToken trades below NAV. The vault buys cheap llToken on the DEX and burns it, pushing supply down and price back toward NAV. Intensity scales with discount depth (50-100% buyback).

PREMIUM Mint + Sell + Compound

When llToken trades above 110% of NAV. Vault mints new llToken, sells at premium, compounds all proceeds. Slight dilution, but net accretive because sold above NAV. Capped at 3% supply per epoch with 2-epoch cooldown.

Adapter Pattern

Adding a new veNFT protocol requires only a new adapter implementing IVeNFTAdapter. The core vault stays unchanged. Re-audit scope: ~50 lines.

Security Model

RoleCan doCannot doGuardrails
Owner Set modules, router, keeper, pause, rescue tokens Mint tokens, move locked DUST, bypass caps Ownable2Step, future timelock
Keeper executeEpoch, sync Change config, mint outside epoch, move funds Price ±10% of reference, mint capped 3%, cooldown, deviation <30%
Token Transfer, approve (ERC-20) Only vault can mint/burn, immutable vault ref

Contract Sizes

ContractSLOCPurpose
VeVault.sol263Core vault logic (protocol-agnostic)
RevenueModule.sol129Reward processing + fee split
OracleModule.sol94TWAP oracle for regime detection
SwapAdapter.sol67V2/V3 routing wrapper
NeverlandAdapter.sol59Neverland-specific adapter
NAVLib.sol58Pure math (NAV, regime, mint calc)
StDustToken.sol23Minimal ERC-20 wrapper
IVeNFTAdapter.sol11Adapter interface
Total704