386 matches found
Reentrancy vulnerability in SGLCommon._removeAsset
Lines of code Vulnerability details Impact The function SGLCommon.removeAsset is vulnerable to reentrancy attacks. Reentrancy occurs when a contract calls another contract, and the second contract calls back to the first contract before the first contract has finished executing. This can allow th...
CBEthCollateral and AnkrStakedEthCollateral _underlyingRefPerTok is incorrect
Lines of code Vulnerability details The CBEthCollateral.underlyingRefPerTok function just uses CBEth.exchangeRate to get the ref/tok rate. The CBEth.exchangeRate can only get the conversion rate from cbETH to staked ETH2 on the coinbase. However as the docs...
CurveVolatileCollateral Collateral status can be manipulated by flashloan attack
Lines of code Vulnerability details Impact Attacker can make the CurveVolatileCollateral enter the status of IFFY/DISABLED . It will cause the basket to rebalance and sell off all the CurveVolatileCollateral. Proof of Concept The CurveVolatileCollateral overrides the anyDepeggedInPool function to...
The amount of debt removed during liquidation may be worth more than the account's collateral
Lines of code Vulnerability details Impact The contract decreases user's debts but may not take the full worth in collateral from the user, leading to the contract losing potential funds from the missing collateral. Proof of concept During the liquidate function call, the function...
Malicious user can drain the Singularity contract of it's liquidity
Lines of code Vulnerability details Impact The SGLCollateral contract has functionality to allow users to remove and add collateral for the Singularity market. The addCollateral function accepts a skim parameter that, if defined as true, will cause the internal addTokens function to assert that t...
Risk of Incorrect Collateral Pricing in Case of Aggregator Reaching minAnswer
Lines of code Vulnerability details Impact Chainlink aggregators have a built-in circuit breaker to prevent the price of an asset from deviating outside a predefined price range. This circuit breaker may cause the oracle to persistently return the minPrice instead of the actual asset price in the...
liquidateBorrow() mTokens that do not enter the market can still be liquidated as collateral
Lines of code Vulnerability details Impact borrower's mTokens that do not join the market, but it still be Liquidation as collateral Proof of Concept If user wants to use mToken as collateral, the user needs to enter market with enterMarket function. / @notice Add assets to be included in account...
More collateral is seized than approved
Lines of code Vulnerability details Impact More collateral is seized outside of the comptroller's approved liquidation amount which means excess seizeTokens are transferred from the borrower to the liquidator leading to loss of funds Proof of Concept liquidateBorrowFresh first checks the allowanc...
Liquidator can seize more tokens than the borrower has as collateral, leading to an arithmetic underflow and locking collateral.
Lines of code Vulnerability details Impact Lack of validation on seizeTokens could allow collateral locking by underflow. Proof of Concept The liquidateBorrowFresh function does not explicitly validate that seizeTokens is less than or equal to accountTokensborrower before transferring tokens from...
Users positions can be directly liquidated when the admin changes the collateralFactorMantissa from a higher value to a lower value
Lines of code Vulnerability details Impact In Comptroller contract : Market.collateralFactorMantissa mltiplier represents the maximum underlying asset amount the depositors can borrow against their collateral in a market,for example:if it is set to 0.9;then 90% of collateral value is allowed to b...
M-07 Unmitigated
Lines of code Vulnerability details Original Issue code-423n4/2023-06-angle-findings8 Details This issue shows users may get fewer tokens than expected when the collateral list order changes. As mitigation, it recommends checking the length of minAmountsOut and ts.collateralList as well as the...
M-07 Unmitigated
Lines of code Vulnerability details The fix addresses the scenarios when collaterals are removed between the crafting of the minAmountsOut list and the submission of the transaction. Then, we will have amounts.length minAmountOuts.length, meaning that the following line causes a revert: if...
LibHelpers.piecewiseLinear will revert when the value is less than the first element of the array
Lines of code Vulnerability details Impact LibHelpers.piecewiseLinear reverts when the value is less than the first element of the array. This method is used in Redeemer contract and if the collateral ratio is below the first element of xRedemptionCurve, the redepmtion will revert. Proof of Conce...
LACK OF deadline CHECK COULD PROMPT DELAYED EXECUTION OF swap OPERATION
Lines of code Vulnerability details Impact The RewardHandler.sellRewards function is used by governance and trusted sellers to sell reward tokens for collateral tokens. This function ensures that none of the collateral should be decreased after the swap by checking their respective balances befor...
No check for active Arbitrum Sequencer
Lines of code Vulnerability details Impact If the Arbitrum sequencer goes down, the stale ratio will be used during the swap. Proof of Concept readChainlinkFeed gets the price from chainlink oracle and the ratio is used during the swap. function readChainlinkFeed uint256 quoteAmount,...
Possible reentrancy during redemption/swap
Lines of code Vulnerability details Impact Redeemers might charge more collaterals during redemption/swap by the reentrancy attack. Proof of Concept Redeemers can redeem the agToken for collaterals in Redeemer contract and redeem burns the agToken and transfers the collaterals. function redeem...
User may get less tokens than expected when collateral list order changes
Lines of code Vulnerability details Impact The order of ts.collateralList is not stable: Whenever LibSetters.revokeCollateral is used to revoke a collateral, it may change because of the swap that is performed. However, the function Redeemer.redeem relies on this order, as the user has to provide...
A user could drain collateral from LybraStETHVault.sol even if they have redeemed all their eUSD for their deposited collateral
Lines of code Vulnerability details Impact Suppose a user deposits certain Ether and mints eUSD. The user collects mining rewards for sometime assuming that the their earnings are not claimable by others. After sometime, the user redeems all their eUSD for StETH. Now, even after redemption, the...
In LybraStETHVault.sol (LybraEUSDVaultBase.sol) a user could rigid redeem an amount more than their deposited collateral when the collateral ratio of the user goes below 100% even if they have been super-liquidated.
Lines of code Vulnerability details Impact If the collateral ratio of a user goes below 100%, the user would be able to redeem all of their eUSD for a collateral amount greater than their depositedAssetuser even after they have been super-liquidated. For eg, let us say we have a user X. Now, in...
Withdraw fee discounting using self rigidRedemption
Lines of code Vulnerability details Description There is no restriction for self rigidRedemption so that allows one to repay and withdraw instantly part of the collateral. That allows us to instantly withdraw with less fee paid. Impact It may be used for malicious scenarios with flashloan for...