Lucene search
+L
Code423n4Most viewed

10190 matches found

Code423n4
Code423n4
•added 2021/11/22 12:00 a.m.•18 views

OZ ERC1155Supply vulnerability

Handle pauliax Vulnerability details Impact Overlay uses OZ contracts version 4.3.2: dependencies: - OpenZeppelin/[email protected] and has a contract that inherits from ERC1155Supply: contract OverlayV1OVLCollateral is ERC1155Supply This version has a recently discovered vulnerability...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/22 12:00 a.m.•18 views

User can refund the received airdropped (free) "key"

Handle GiveMeTestEther Vulnerability details Impact User can refund the received airdropped free "key". If a lot of users received a airdropped "key" they can drain the funds of the lock. e.g. key owner cannot withdraw anything, user that purchased a key can't cancel and refund. Proof of Concept ...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/18 12:00 a.m.•18 views

_transferBurn does not actually burn tokens (decrease supply)

Handle harleythedog Vulnerability details Impact The implementation of transferBurn in ovl/OverlayToken.sol does not actually burn any tokens since totalSupply is not decreased see the implementation for burn for reference of what should be done. The transferBurn function is a helper function tha...

7.1AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/17 12:00 a.m.•18 views

ERC1155Supply vulnerability in OpenZeppelin Contracts

Handle defsec Vulnerability details Impact When ERC1155 tokens are minted, a callback is invoked on the receiver of those tokens, as required by the spec. When including the ERC1155Supply extension, total supply is not updated until after the callback, thus during the callback the reported total...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

Wrong design/implementation of addLiquidity() allows attacker to steal funds from the liquidity pool

Handle WatchPug Vulnerability details The current design/implementation of Vader pool allows users to addLiquidity using arbitrary amounts instead of a fixed ratio of amounts in comparison to Uni v2. We believe this design is flawed and it essentially allows anyone to manipulate the price of the...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

Lacking Validation Of Chainlink' Oracle Queries

Handle leastwood Vulnerability details Impact TwapOracle.consult is missing additional validations to ensure that the round is complete and has returned a valid/expected price. The consult improperly casts an int256 price to uint256 without first checking the value. As a result, the variable may...

7.1AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

Unused slippage params

Handle pauliax Vulnerability details Impact Unused slippage params. function addLiquidity in VaderRouter both V1 and V2 do not use slippage parameters: uint256, // amountAMin = unused uint256, // amountBMin = unused making it susceptible to sandwich attacks / MEV. For a more detailed explanation,...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

Synth tokens can get over-minted

Handle WatchPug Vulnerability details Per the document: It also is capable of using liquidity units as collateral for synthetic assets, of which it will always have guaranteed redemption liquidity for. However, in the current implementation, Synth tokens are minted based on the calculation result...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

VaderRouter.calculateOutGivenIn calculates wrong swap

Handle cmichel Vulnerability details The 3-path hop in VaderRouter.calculateOutGivenIn is supposed to first swap foreign assets to native assets in pool0, and then the received native assets to different foreign assets again in pool1. The first argument of VaderMath.calculateSwapamountIn,...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

TWAPOracle.getRate does not scale the ratio

Handle cmichel Vulnerability details The TWAPOracle.getRate function simply performs an integer division to compute the rate. function getRate public view returns uint256 result uint256 tUSDInUSDV = consultUSDV; uint256 tUSDInVader = consultVADER; // @audit shouldn't this scale by 1e18 first?...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

Attacker can claim more IL by manipulating pool price then removeLiquidity

Handle gzeon Vulnerability details Impact Vader reimburse user IL immediately when user withdraw from the pool VaderRouterV2.sol:L227, an attacker can therefore manipulate the pool balance causing a high IL, remove liquidity and restore the pool balance such that he will receive a larger IL...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•18 views

mintSynth() and burnSynth() can be front run

Handle WatchPug Vulnerability details Given that mintSynth and burnSynth will issue and redeem assets based on the price of the pool reserves, and they will create price impact based on the volume being minted and burnt. However, the current implementation provides no parameter for slippage...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/14 12:00 a.m.•18 views

Zap contract's redeem() function doesn't check which token the user wants to receive

Handle Ruhum Vulnerability details Impact In the redeem function, the user can pass a token address. That's the token they receive in return for the ibbtc they give back. Because of missing address checks the user can provide any possible ERC20 token here without the function reverting. Although...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/12 12:00 a.m.•18 views

Anyone Can Arbitrarily Call FSDVesting.updateVestedTokens()

Handle leastwood Vulnerability details Impact The updateVestedTokens function is intended to be called by the FSD.sol contract when updating a user's vested token amount. A check is performed to ensure that user == beneficiary, however, as user is a user controlled argument, it is possible to spo...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/10 12:00 a.m.•18 views

Vestings' revoke status can be set by anyone

Handle cmichel Vulnerability details The idea of revoking vesting supposedly exists for the admins to call Vesting.revoke and claim back a user's vesting. However, if the user wants to protect their vesting from being revoked by the admin, they can create a new vest with isRevocable = false and a...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/09 12:00 a.m.•18 views

Can not update target price

Handle jonah1005 Vulnerability details Impact The sanity checks in rampTargetPrice are broken SwapUtils.solL1571-L1581 if futureTargetPricePrecise = initialTargetPricePrecise, "futureTargetPrice is too small" ; else require futureTargetPricePrecise =...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/09 12:00 a.m.•18 views

Permissioned nature of TwapOracle allows owner to manipulate oracle

Handle TomFrench Vulnerability details Impact Potentially frozen or purposefully inaccurate USDV:VADER price feed. Proof of Concept Only the owner of TwapOracle can call update on the oracle. Should the owner desire they could cease calling update on the oracle for a period. Over this period the...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/08 12:00 a.m.•18 views

Contract BasicSale is missing an approve(address(vestLock), 2**256-1) call

Handle Reigada Vulnerability details Impact As we can see in the contracts AirdropDistribution and InvestorDistribution, they both have the following approve call: mainToken.approveaddressvestLock, 2256-1; This is necessary because both contracts transfer tokens to the vesting contract by calling...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/30 12:00 a.m.•18 views

No sanity check on pricePerShare might lead to lost value

Handle kenzo Vulnerability details pricePerShare is read either from an oracle or from ibBTC's core. If one of these is bugged or exploited, there are no safety checks to prevent loss of funds. Impact As pricePerShare is used to calculate transfer amount, a bug or wrong data which returns smaller...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/27 12:00 a.m.•18 views

Improper Validation Of create2 Return Value

Handle leastwood Vulnerability details Impact The BeaconProxyDeployer.deploy function is used to deploy lightweight proxy contracts that act as each asset's vault. The function does not revert properly if there is a failed contract deployment or revert from the create2 opcode as it does not...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/26 12:00 a.m.•18 views

Unchecked ERC20 transfer calls

Handle loop Vulnerability details ERC20 transfer and transferFrom calls normally return true on a succesful transfer. In DutchAuctionLiquidator the call asset.transfermsg.sender, collateral; is made. asset refers to whichever ERC20 asset is used for the vault of that auction. If asset is an ERC20...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/21 12:00 a.m.•18 views

Validator can fail to receive commission reward in redeemAllRewards

Handle jonah1005 Vulnerability details Impact Validator can fail to receive commission reward by calling redeemAllRewards. There's a check in redeemAllRewards uint128 rewards = sharesToTokenss.shares, v.exchangeRate - s.staked; requirerewards 0, "Nothing to redeem"; The validator's tx might be...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/20 12:00 a.m.•18 views

depositAndFix can be made to fail

Handle cmichel Vulnerability details There's a griefing attack where an attacker can make any user transaction for TempusController.depositAndFix fail. In depositAndFix, swapAmount many yield shares are swapped to principal where swapAmount is derived from the function arguments. A final...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/19 12:00 a.m.•18 views

disableValidator() can distort totalGlobalShares (edge case)

Handle gpersoon Vulnerability details Impact Assume a validator has been added Assume this validator calls disableValidator maybe by accident or it recognizes a mistake Assume stake hasn't been called yet and endEpoch is still 0 The function disableValidator will execute and set v.disabledEpoch t...

7.3AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/16 12:00 a.m.•18 views

cancel() calculates hashTx in the wrong way

Handle gpersoon Vulnerability details Impact The function cancel of contract QuickAccManager uses the wrong way to calculate the hash that has to be cancelled. It uses: "bytes32 hashTx = keccak256abi.encodeaddressthis, block.chainid, accHash, nonce, txns;" Where it should use "bytes32 hash =...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/15 12:00 a.m.•18 views

MAX_TRUST_LIMIT might be too high

Handle gpersoon Vulnerability details Impact Both SumOfTrust.sol and CreditLimitByMedian.sol contain an expensive sort function. This is used by UserManager.sol via the functions getLockedAmount and getCreditLimit. If the list of stakers would be very long then the sort would take up all the gas...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/09 12:00 a.m.•18 views

Denial of Service in Basket.mint()

Handle pants Vulnerability details The function Basket.mint calls Basket.mintTo, but both Basket.mint and Basket.mintTo use the nonReentrant modifier. Impact The function Basket.mint will always revert when it calls Basket.mintTo, due to reentrancy. Tool Used Manual code review. Recommended...

7.1AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/06 12:00 a.m.•18 views

Can reclaim the same incentive multiple times

Handle pauliax Vulnerability details Impact function reclaimIncentive can be invoked more than once for the same incentiveId. If there were multiple incentives for the same token it would allow to drain these tokens by repeatedly calling reclaimIncentive. Recommended Mitigation Steps Simple...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/10/06 12:00 a.m.•18 views

ConcentratedLiquidityPool: secondsPerLiquidity should be modified whenever pool liquidity changes

Handle hickuphh3 Vulnerability details Impact secondsPerLiquidity is updated as such: secondsPerLiquidity += uint160diff 128 / liquidity; where diff = timestamp - uint256lastObservation. Hence, whenever liquidity changes, secondsPerLiquidity should be updated prior to the change. In particular,...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/29 12:00 a.m.•18 views

HybridPool's flashSwap gives the total fee to barFeeTo

Handle 0xsanson Vulnerability details Impact In HybridPool's flashSwap function there's a transfer to barFeeTo transfertokenIn, fee, barFeeTo, false; Here fee = amountIn swapFee / MAXFEE is the total swap fee. However it should transfer out only a fraction of it barFee/MAXFEE otherwise liquidity...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/29 12:00 a.m.•18 views

HybridPool's reserve is converted to "amount" twice

Handle cmichel Vulnerability details The HybridPool's reserves are stored as Bento "amounts" not Bento shares in updateReserves because balance converts the current share balance to amount balances. However, when retrieving the reserve0/1 storage fields in getReserves, they are converted to amoun...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/22 12:00 a.m.•18 views

approveUnderlying isn't safe

Handle 0xsanson Vulnerability details Impact In Basket.sol, approveUnderlying is used to approve tokens to be spent by the Auction. The current implementation uses a simple approve function, instead of the safer safeApprove. Also it's recommended to have an approve to zero first, since the...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/16 12:00 a.m.•18 views

missing access control in basket.sol

Handle jah Vulnerability details Impact function mint and function minTo are not protected so anyone can mint Proof of Concept Tools Used manual analysis Recommended Mitigation Steps use modifier to check who can call the function --- The text was updated successfully, but these errors were...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/15 12:00 a.m.•18 views

convert fails for fee-on-transfer tokens

Handle 0xsanson Vulnerability details Impact The Controller contract can call converter.convert inside earn and withdraw functions, after transferring amount of tokens to the Converter contract. This contract assumes that it has received exactly amount tokens, however this isn't true for...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/15 12:00 a.m.•18 views

An attacker can steal funds from multi-token vaults

Handle WatchPug Vulnerability details The total balance should NOT be simply added from different tokens' tokenAmounts, considering that the price of tokens may not be the same. function balanceOfThis public view returns uint256 balance address memory tokens = manager.getTokensaddressthis; for...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/15 12:00 a.m.•18 views

Controller.withdrawAll sets wrong vault balance

Handle cmichel Vulnerability details The Controller.withdrawAll decreases the vault balance by amount, the want token amount that has been withdrawn from the strategy and transferred to the vault. Note that amount gets overwritten in the convert != address0 branch and is a convert token value...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/15 12:00 a.m.•18 views

wrong YAXIS estimates

Handle cmichel Vulnerability details The Harvester.getEstimates contract tries to estimate a YAXIS amount but uses the wrong path and/or amount. It currently uses a WETH input amount to compute a YAXIS - WETH trade. address memory path; path0 = IStrategystrategy.want; path1 =...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/13 12:00 a.m.•18 views

harvestNextStrategy never executes because lastCalled is 0 and stays 0

Handle gpersoon Vulnerability details Impact The function harvestNextStrategy of Harvester.sol checks canHarvest to make sure it can harvest. Initially strategy.lastCalled will be 0 so canHarvest will return false. Thus the require in harvestNextStrategy fails And it never reaches the point where...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/13 12:00 a.m.•18 views

Deposits into vaults are not tracked at a token level

Handle itsmeSTYJ Vulnerability details Impact If the strategy used accepts multiple tokens, a user can deposit in a cheaper token and withdraw in a more expensive token because the vault only tracks ownership based on how many shares they own. Proof of Concept 1. An approved strategist adds 2...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/12 12:00 a.m.•18 views

Controller transfer extra token on withdrawing tokens

Handle jonah1005 Vulnerability details Impact The Controlle�r's function withdrawaddress token, uint256 amount should return whatever amount of the token user/vault asks. However, it tries to withdraw strategy.want token and convert it. Take for example, when a user/vault calls withdrawdai, 100,...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/09/06 12:00 a.m.•18 views

Settle Portfolio state could be griefed.

Handle tensors Vulnerability details Impact It could be possible for a user to get a portfolioState that is large enough to be unfeasible to compute, either because of the block gas limit or simply because gas fees are so high and the code itself is complex. If this is possible, than he could tak...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/25 12:00 a.m.•18 views

Market whitelist does not work

Handle cmichel Vulnerability details The RCTreasury.marketWhitelistCheck function gets the marketWhitelistmsgSender variable and performs a special check if it's non-zero. However, there's no way to set the whitelist in the first place making this function unnecessary. Impact The market whitelist...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/14 12:00 a.m.•18 views

Rewards squatting - setting rewards in different ERC20 tokens opens various economic attacks.

Handle moose-code Vulnerability details Impact Users have essentially have an option to either claim currently earned reward amounts on future rewards tokens, or the current rewards token. Although stated on line 84, it does not take into account the implications and lock in this contract will ha...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/13 12:00 a.m.•18 views

TimeLock cannot schedule the same calls multiple times

Handle cmichel Vulnerability details The TimeLock.schedule function reverts if the same targets and data fields are used as the txHash will be the same. This means one cannot schedule the same transactions multiple times. Impact Imagine the delay is set to 30 days, but a contractor needs to be pa...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/11 12:00 a.m.•18 views

initializeMarket uses wrong market index for synthetic

Handle cmichel Vulnerability details The LongShort.initializeMarket function accepts a marketIndex parameter to identify which market should be initialized. However, this index is not used everywhere, when calling IStakerstaker.addNewStakingFund the latestMarket variable is used. In the...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/10 12:00 a.m.•18 views

initializeMarket always initialize the latest market

Handle jonah1005 Vulnerability details Impact In longshore contract's initializeMarket, while it should initialize according to the parameter marketIndex, it initialize latestMarket. This would break two market, the market of marketIndex' and market of latestMarket. User's fund would get stuck at...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/08 12:00 a.m.•18 views

Synths minted to the wrong market when initializing

Handle 0xImpostor Vulnerability details Impact Synthetix tokens are not minted to the correct market index since the creation of the synth market and the initialization are 2 separate steps. Proof of Concept 1. Create 2 synth market without initializing them 2. Call initializeMarket twice 3. Synt...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/08/06 12:00 a.m.•18 views

Staker.sol: Wrong values returned in edge cases of _calculateFloatPerSecond()

Handle hickuphh3 Vulnerability details Impact In calculateFloatPerSecond, the edge cases where full rewards go to either the long or short token returns return 1e18 k longPrice, 0; and return 0, 1e18 k shortPrice; respectively. This is however 1e18 times too large. We can verify this by checking...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/07/30 12:00 a.m.•18 views

Transfer-on-fee/deflationary tokens are not correctly accounted for

Handle shw Vulnerability details Impact When a user stakes or a protocol deposits a transfer-on-fee/deflationary token, the solution does not correctly handle the received amount, which could be less than what is accounted for. Proof of Concept Referenced code: PoolOpen.solL36-L38...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/07/29 12:00 a.m.•18 views

Difficult for the project to be decentralized if the Watsons share one address.

Handle tensors Vulnerability details Impact The Watsons share a single address. As it stands right now the Watsons could be a single person effectively providing insurance with other peoples risk. There should be mechanisms in place to make sure Watson's have an accurate amount of skin in the gam...

6.9AI score
SaveExploits0
Total number of security vulnerabilities5000