Liquidation bonus logic is wrong
DYAD
MediumCode4rena
Every publicly disclosed report for DYAD and what kind of bugs they were.
Newest first. Only what DYAD chose to make public.
DYAD
MediumThe KeroseneManager contract is expected to contain only backing vaults to avoid infinite loops in UnboundedKerosineVault, but VaultManagerV2's getKeroseneValue function requires the same manager to license kerosene deposit vaults, which are not included in the deployment. As a result, getKeroseneValue always returns zero, breaking the valuation of kerosene deposits.
DYAD
MediumThe deployment script for the DYAD protocol did not call setUnboundedKerosineVault on the bounded Kerosene vault, so any attempt to query the Kerosene value of a dNFT that uses the bounded vault would revert. This could prevent users from withdrawing or minting DYAD if they had added the bounded Kerosene vault as collateral.
DYAD
MediumLiquidators who seize bounded Kerosene tokens cannot withdraw them, so the seized collateral is worth less than the amount they pay to liquidate. This could make liquidations of positions containing bounded Kerosene unprofitable, discouraging liquidators.
DYAD
MediumThe price of kerosene tokens is calculated from the protocol's total value locked (TVL) and can be manipulated instantly by large depositors withdrawing their collateral. An attacker can drop the kerosene price to push other users' collateralization ratios below the liquidation threshold and liquidate them.
DYAD
MediumThe burnDyad function in VaultManagerV2.sol lacks a check that the caller owns the specified DNft, allowing any user to burn another user's minted DYAD. An attacker can burn someone else's DYAD, clearing their debt and enabling them to mint more, or burn their own DYAD to avoid liquidation.
DYAD
MediumThe vault removal function requires that the vault has no assets for the dNFT, but anyone can deposit a tiny amount into that dNFT. An attacker can watch for a removal transaction and front-run it with a deposit, causing the removal to revert.
DYAD
MediumThe Kerosene vault price calculation subtracts Dyad's total supply from the protocol's TVL, which underflows and reverts when TVL is less than the supply. As a result, users who deposit Kerosene into the vault cannot withdraw it until TVL exceeds the supply.
DYAD
HighThe liquidation function only transfers non-Kerosene collateral to the liquidator, leaving Kerosene collateral in the liquidated position. A liquidator who fully liquidates a position pays DYAD but receives less collateral than expected, while the liquidated position retains Kerosene collateral.
DYAD
HighThe protocol's flash-loan protection only blocks deposits and withdrawals in the same block, but liquidations move collateral without updating that check. An attacker could use a flash loan to deposit, manipulate the kerosene price, self-liquidate into a second account, and withdraw in the same block, opening a position at a much lower collateral ratio than intended.
DYAD
HighThe liquidation reward for small positions is too low to cover gas and trading costs, so liquidators have no incentive to act. This can leave bad debt and potentially make the protocol insolvent.
DYAD
MediumThe liquidation function requires the liquidator to burn the full borrowed amount but only returns collateral worth less than that when the collateral ratio is below 1, so liquidators lose money and have no incentive to liquidate. This could leave bad debt unliquidated, potentially worsening the protocol's losses.
DYAD
MediumThe withdraw function in VaultManagerV2 calls an oracle method on the vault contract, but Kerosene vaults do not implement this method, causing any Kerosene withdrawal to revert. As a result, users cannot withdraw their deposited Kerosene, and it remains stuck in the contract.
DYAD
HighThe liquidate function only burns the entire DYAD amount minted by a DNft id, so a liquidator must cover the whole debt to liquidate a position. For very large positions this is impractical, so they stay undercollateralised and bad debt accrues in the system.
DYAD
HighDYAD
HighThe deposit function records the current block number for any dNft id, and withdraw reverts if a deposit occurred in the same block. An attacker can deposit a worthless fake token into a victim's dNft to make their withdrawal revert at no cost.
DYAD
HighThe withdraw function incorrectly checks the non-Kerosene collateral value against the minted Dyad amount even when withdrawing Kerosene collateral, causing transactions to revert. This prevents users from withdrawing their Kerosene collateral even when their overall collateral ratio is sufficient.
DYAD
HighThe liquidation function in VaultManagerV2 lacks a check that the vault's non-kerosene collateral value is at least the DYAD minted, so when a position's total collateral ratio remains at or above 150% due to kerosene but its exogenous collateral falls below the minted DYAD, liquidation reverts. This prevents liquidators from acting, allowing the protocol's core invariant (TVL > DYAD supply) to be broken and potentially causing DYAD to depeg.
DYAD
HighThe deployment script licensed the same WETH vault in both the KeroseneManager and VaultLicenser, and licensed the Kerosene vault in the VaultLicenser. This allowed users to register the same WETH vault in both normal and Kerosene vault mappings, double-counting collateral, or to use the Kerosene vault as normal collateral, enabling inflated collateral ratios and positions backed entirely by the volatile Kerosene token.
DYAD
High