Lucene search
+L
Code423n4Recent

10190 matches found

Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’11 views

In Notional case Redeemer's redeem() will not do the position redeeming

Lines of code Vulnerability details Currently no actual redeeeming is done in Notional case as maxRedeem is a balance view function that doesn't close the position. This way one more operation, the redeeming itself, is now committed and in Notional case Redeemer's redeem doesn't perform anything,...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’6 views

lend() to Tempus will return less than expected or just revert

Lines of code Vulnerability details function lend uint8 p, address u, uint256 m, uint256 a, uint256 r, uint256 d, address t, address x public unpausedp returns uint256 // Instantiate market and tokens address principal = IMarketPlacemarketPlace.marketsu, m, p; if ITempusprincipal.yieldBearingToke...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

Everyone can burn principal token of any other user

Lines of code Vulnerability details Impact Everyone can burn principal token of any other user. It is very critical that you may lost your principal token anytime without any permission. Proof of Concept // Burn the prinicipal token from Illuminate token.burno, amount; function redeem uint8 p,...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

arbitrage on stake()

Lines of code Vulnerability details Issue: there is a huge arb opportunity for people who deposit 1 block before the rebase Consequences: then they can call instantUnstakeReserve or instantUnstakeCurve to unstake the staked amount, in this way the profit that needs to be distributed on the next...

6.6AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’13 views

Upgraded Q -> M from 104 [1656258768065]

Judge has assessed an item in Issue 104 as Medium risk. The relevant finding follows: L01: Silent overflow of fCashAmount Line References Description If a fCashAmount value that is greater than uint88 is passed into the mint function, downcasting it to uint88 will silently overflow. Recommended...

7.1AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’11 views

Principal token is not transferred

Lines of code Vulnerability details Impact When redeeming from APWine and Tempus here, the principal token is not transferred to the redeemer, so may be stuck on the lender contract. Proof of Concept Instead of Safe.transferFromIERC20u, lender, addressthis, amount; it should be...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

Lender.sol amountIn is used as returned for Pendle

Lines of code Vulnerability details uint256 returned; // Add the accumulated fees to the total uint256 fee = calculateFeea; feesu += fee; address memory path = new address; path0 = u; path1 = principal; // Swap on the Pendle Router using the provided market and params returned =...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’7 views

can override a marketplace

Lines of code Vulnerability details Impact There is no check if there is a market place in the m address and we can override all of the exist market places. Proof of Concept function setMarketPlaceaddress m external authorizedadmin returns bool if marketPlace != address0 revert ExistsmarketPlace;...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’13 views

Unable to redeem from Notional

Lines of code Redeemer.solL193 Vulnerability details Impact The maxRedeem function is a view function which only returns the balance of the Redeemer.sol contract. After this value is obtained, the PT is not redeemed from Notional. The user will be unable to redeem PT from Notional through...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

Yieldy._totalSupply has different upper bounds.

Lines of code Vulnerability details Impact Yieldy.totalSupply has different upper bounds. Yieldy.mint will revert when totalSupply is exactly same as MAXSUPPLY. Proof of Concept From L91-L98, we can see totalSupply can be same as MAXSUPPLY and I think "totalSupply = MAXSUPPLY" is reasonable also...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

User to lose all the funds when lend() to Swivel

Lines of code Vulnerability details function lend uint8 p, address u, uint256 m, uint256 memory a, address y, Swivel.Order calldata o, Swivel.Components calldata s public unpausedp returns uint256 // lent represents the number of underlying tokens lent uint256 lent; // returned represents the...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’13 views

Staking.setCurvePool() doesn't approve allowance when changes CURVE_POOL.

Lines of code Vulnerability details Impact Staking.setCurvePool doesn't approve allowance when changes CURVEPOOL. It will affect when users exchange asset through CURVEPOOL. Proof of Concept When initialize the contract, Staking contract approves CURVEPOOL here. But when admin updates CURVEPOOL...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

No minting done in the Element version of lend function, user funds are frozen within the system

Lines of code Vulnerability details Lender's Element lend transfers the funds from a user, opens the position with Element, but fails to mint a corresponding Illuminate position to a user. Setting severity to be high as there is no account of user investment is effectively created, so there is no...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’26 views

Safe.approve may not work for USDT

Lines of code Vulnerability details Impact Some tokens like USDT do not work when changing the allowance from an existing non-zero allowance value. They must first be approved by zero and then the actual allowance must be approved. Proof of concept: The following function may fail and make USDT...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’21 views

Sending batch withdrawal requests can possibly DoS

Lines of code Vulnerability details Impact The function BatchRequests.sendWithdrawalRequests allows calling the sendWithdrawalRequests function on all of the Yieldy contracts at once. However, due to the unbounded for loop, if many Yieldy contracts are added to contracts, this function can...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’9 views

It's possible to perform DOS and fund lose in Stacking by transferring tokens directly to contract

Lines of code Vulnerability details Impact Function rebase in contract Staking calls Yieldy.rebaseprofit, and Yieldy.rebaseprofit, would revert if rebasingCredits / updatedTotalSupply was equal to 0. it's possible to transfer some STAKINGTOKEN directly to Stacking contract before or after...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’16 views

Uninitialized local variables

Lines of code Vulnerability details Impact Configuration -Check: uninitialized-local -Severity: Medium -Confidence: Medium -Description:Lender.approveaddress,address.i Lender.sol114 is a local variable never initialized.A smart contract with uninitialized local variables may lead to intentional...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’6 views

Funds may be stuck when redeeming for Illuminate

Lines of code Vulnerability details Impact Funds may be stuck when redeeming for Illuminate. Proof of Concept Assuming the goal of calling redeem for Illuminate here is to redeem the Illuminate principal held by the lender or the redeemer, then there is an issue because the wrong balance is...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’16 views

Redeemer.sol#redeem() can be called by anyone before maturity, which may lead to loss of user funds

Lines of code Vulnerability details function redeem uint8 p, address u, uint256 m public returns bool // Get the principal token that is being redeemed by the user address principal = IMarketPlacemarketPlace.marketsu, m, p; // Make sure we have the correct principal if p !=...

7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’7 views

Fee on transfer tokens not supported

Lines of code Vulnerability details Impact Fee on transfer tokens would lead to sellers getting more PT than what the pool has received in underlying as the difference in balance is not accounted for, only the a input. This is also true for mintWithUnderlying as minters get more in relation to th...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’6 views

[M-04] Admin can lose control on the contract

Lines of code Vulnerability details Proof of Concept The setAdmin function is too loose, if no one have access to the address passed in this function, the whole project is stuck - cannot withdraw funds or fees, cannot create new markets, etc. Recommended Mitigation Steps Change setAdmin in favour...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’11 views

Improper Upper Bound Definition on the Fee

Lines of code Vulnerability details Impact The feenominator does not have any upper or lower bounds. Values that are too large will lead to reversions in several critical functions or the platform user will lost all funds when paying the fee. Proof of Concept 1. Navigate to the following contract...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

instead of call() , transfer() is used to withdraw the ether

Lines of code Vulnerability details Impact To withdraw eth it uses transfer, this trnansaction will fail inevitably when : - The withdrwer smart contract does not implement a payable function. Withdrawer smart contract does implement a payable fallback which uses more than 2300 gas unit Thw...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’14 views

Illuminate PT redeeming allows for burning from other accounts

Lines of code Vulnerability details Illuminate PT burns shares from a user supplied address account instead of user's account. With such a discrepancy a malicious user can burn all other's user shares by having the necessary shares on her balance, while burning them from everyone else. Setting th...

6.6AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’15 views

Rug vector for admin of Lender.sol who can max approve all principal tokens for any market without waiting the 3 days to themselves

Lines of code Vulnerability details Impact The admin of Lender.sol is authorized to call the function approve which will grant any address max approval over the principal tokens of a particular market. I assume that this functionality is used to approve the respective redeemer contracts used in...

7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’15 views

[PNM-003] _totalStakedBefore_ and _totalStakedAfter_ are the always the same

Lines of code Vulnerability details Description It can be medium or high according to the off-chain logic which is not avaiable for the contest. Specifically, rebases can only be updated by function storeRebase and the only callsite of function storeRebase is in function rebase. While we have...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’13 views

User fund lose in addLiquidity() of LiquidityReserve by increasing (totalLockedValue / totalSupply()) to very large number by attacker

Lines of code Vulnerability details Impact Function addLiquidity suppose to do add Liquidity for the staking Token and receive lrToken in exchange. to calculate amount of IrToken codes uses this calculation: amountToMint = amount lrFoxSupply / totalLockedValue but it's possible for attacker to...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’12 views

Staking.sol#stake() DoS by staking 1 wei for the recipient when warmUpPeriod > 0

Lines of code Vulnerability details if warmUpPeriod == 0 IYieldyYIELDYTOKEN.mintrecipient, amount; else // create a claim and mint tokens so a user can claim them once warm up has passed warmUpInforecipient = Claim amount: info.amount + amount, credits: info.credits +...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’17 views

Able to mint any amount of PT

Lines of code Lender.solL192-L235 Lender.solL486-L534 Lender.solL545-L589 Vulnerability details Impact Some of the lend functions do not validate addresses sent as input which could lead to a malicous user being able to mint more PT tokens than they should. Functions affect: Illuminate and Yield...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’11 views

LiquidityReserve may break if underlying token is upgraded to have fees

Lines of code Vulnerability details Impact One of the tokens supported by this project is USDC, which is an upgradeable contract, and the code specifically casts addresses to IERC20Upgradeable rather than to IERC20, so the intention is for the code to support upgrades. If USDC ever upgrades to ha...

7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

Yield of LiquidityReserve can be stolen

Lines of code Vulnerability details Impact Using sandwich attacks and JIT Just-in-time liquidity, the yield of LiquidityReserve could be extracted for liquidity providers. Proof of Concept The yield of LiquidityReserve is distributed when a user calls instantUnstakeReserve in Staking. Then, in...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’19 views

Yieldy: WarmUp expiry can be prolonged by staking from somebody else

WarmUp expiry can be prolonged by staking from somebody else Staking.sol:406 Staking.sol:439-444 Staking.sol:691 Impact When warmUpPeriod is greater than 1, a third person can stake to the victim to prolong the warmUp expiry. The expiry prolongation also happens with cool down, although a third...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’11 views

Cannot mint to exactly max supply using _mint function

Lines of code Vulnerability details Impact Cannot mint to exactly max supply using mint function Proof of Concept requiretotalSupply MAXSUPPLY, "Max supply"; if totalSupply == MAXSUPPLY this assert will be failed and reverted. But is shouldn't be reverted as totalSupply == MAXSUPPLY is valid. Too...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’9 views

[M-01] Easily bypassing admins 'pause' for swivel

Lines of code Vulnerability details Impact Assuming admin decides to pause an external principle when it's dangerous, malicious or unprofitable, Bypassing the admins decision can result in loss of funds for the project. Proof of Concept The principals enum p is only used for unpausedp modifier, a...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

Upgraded Q -> H from 222 [1656255302682]

Judge has assessed an item in Issue 222 as High risk. The relevant finding follows: L-02 totalAssets of erc4626 should never revert eip-4626 According to the spec, totalAssets of erc4626 should never revert MUST NOT revert. wfcash would revert if it's matured but hasn't settled...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’14 views

Fees should be paid by the user when lend() to Swivel

Lines of code Vulnerability details function lend uint8 p, address u, uint256 m, uint256 memory a, address y, Swivel.Order calldata o, Swivel.Components calldata s public unpausedp returns uint256 // lent represents the number of underlying tokens lent uint256 lent; // returned represents the...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’12 views

[H-03] Attacker can mint unbound amount of iPTs (on APWine)

Lines of code Vulnerability details Note that I've reported a similar vulnerability, on a different 'Principals' and POC\attack vector is a bit different. I will leave it to the judge to decide if these should be grouped as 1 report or not - but I wanted to be specific at the POC instead of...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

Griefing on claim()

Lines of code Vulnerability details Issue: griefing can happen if coolDownPeriod 0 due to the fact that you can stake for someone else. Whenever a stake happens, the expiry variable increases with coolDownPeriod. This can be done either by watching the mempool and frontrun a stake when someone...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’12 views

ERC5095 redeem must check allowance with principalAmount instead of underlyingAmount

Lines of code Vulnerability details Impact ERC5095 redeem must check allowance with principalAmount instead of underlyingAmount. Allowing any user to redeem token of anybody freely. This is very critical, anyone can lost their money everytime without their acknowledgement. Proof of Concept functi...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’17 views

Reentrancy vulnerabilities

Lines of code Vulnerability details Impact Reentrancy attacks can allow malicious actors to take over the control flow, and make...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’13 views

No check for set with address(0)

Lines of code Vulnerability details Impact can mint and get approve from address 0. Proof of Concept function setMarketPlaceaddress m external authorizedadmin returns bool if marketPlace != address0 revert ExistsmarketPlace; marketPlace = m; return true; Tools Used None Recommended Mitigation Ste...

7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’14 views

Removal of liquidity from the reserve can be griefed

Lines of code Vulnerability details Impact Users may be unable to withdraw/remove their liquidity from the LiquidityReserve if a user decides to grief the contract. Proof of Concept This is the only function in this contract that is able to unstake funds, so that they can be withdrawn/removed:...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’9 views

Unpaused modifier can be sidestepped in one of the lend functions.

Lines of code Vulnerability details Impact Suppose you tried to pause the lend function that is connected to Swivel. In that case, the attacker could sidestep it because there is no verification that the number input from the user corresponds with the desired input. Proof of Concept Let's say a b...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

if attacker gets admin private key then he can drain all the tokens that Lender.sol contract holds

Lines of code Vulnerability details Impact if attacker gets admin private key then he can drain all the tokens that Lender.sol contract holds Recommended Mitigation Steps make it harder for admin to do this with some internal sec requirements --- The text was updated successfully, but these error...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

Redeemer.sol#redeem() the principal token from Notional can not be redeemed

Lines of code Vulnerability details int256 amount = IERC20principal.balanceOflender; // Transfer the principal token from the lender contract to here Safe.transferFromIERC20principal, lender, addressthis, amount; if p == uint8MarketPlace.Principals.Swivel // Redeems zc tokens to the sender's...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’9 views

IStaking(contracts[i]).canBatchContracts() will revert due to the fact that contracts[i] can contain address(0)

Lines of code Vulnerability details Issue: canBatchContracts will revert due to the fact that contractsi can contain address0 as an address which will revert the whole call. Affected Code File: BatchRequests.sol 33: function canBatchContracts external view returns Batch memory 34: uint256...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’10 views

DoS attack on claiming rewards can lead to user never being able to claim

Lines of code Vulnerability details Proof of Concept: the stake function can be called for a different recipient than msg.sender. Each time you stake tokens your warmUpInfo.expiry or the time when you are able to claim rewards grows by warmUpPeriod as is visible the last line here not the line wi...

6.7AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’15 views

Critical address change

Lines of code Vulnerability details Impact Changing critical addresses in contracts should be a two-step process. in order to prevent changing admin by mistake Proof of Concept check these links: OpenZeppelin/openzeppelin-contracts1488 OpenZeppelin/openzeppelin-contracts2369 Tools Used Manual...

6.9AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

Transfer the principal token from the lender contract to here but actually transfer underlying token

Lines of code Vulnerability details Impact Transfer the principal token from the lender contract to here but actually transfer underlying token from lender to redeemer. Proof of Concept // Transfer the principal token from the lender contract to here Safe.transferFromIERC20u, lender, addressthis,...

6.8AI score
SaveExploits0
Code423n4
Code423n4
β€’added 2022/06/26 12:0 a.m.β€’8 views

Forgot to mint Illuminate zcTokens for Element

Lines of code Vulnerability details function lend uint8 p, address u, uint256 m, uint256 a, uint256 r, uint256 d, address e, bytes32 i public unpausedp returns uint256 // Get the principal token for this market for element address principal = IMarketPlacemarketPlace.marketsu, m, p; // the element...

7AI score
SaveExploits0
Total number of security vulnerabilities10190