Lucene search
+L
Code423n4Most viewed

10190 matches found

Code423n4
Code423n4
•added 2022/05/09 12:00 a.m.•28 views

sendToCosmos doesn't consider the ERC20 transfer fee, resulting in incorrect amount of ERC20 token

Lines of code Vulnerability details Impact Some ERC tokens have a fee on each transfer. The protocol doesn’t handle the fee when transferring this kind of ERC20 tokens, leading to the inconsistent amount of token actually received in the contract. Validators on the Cudos will mint more tokens to...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/09 12:00 a.m.•28 views

Attackers can prevent the transfer of the highest-value Cosmos to Ethereum transactions

Lines of code Vulnerability details In order to ensure that profitable batches are eventually created we must avoid locking up the high fee 'good transactions' into obviously bad batches. To add to the difficulty we don't actually know what any token in this process is worth or what ETH gas costs...

6.5AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/08 12:00 a.m.•28 views

FixedPricePassThruGate.sol All the msg.value should be pass thru to gate.beneficiary instead of gate.ethCost

Lines of code Vulnerability details In FixedPricePassThruGate.solpassThruGate, at L48 the msg.value is checked to be = gate.ethCost instead of == gate.ethCost, which makes it possible for the caller to send more than gate.ethCost. However, at L53 only the amount of gate.ethCost is passed thru to...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/08 12:00 a.m.•28 views

Users can not initialize and withdraw tokens if coinsPerSecond is 0

Lines of code Vulnerability details Impact If a user tries to claim a few totalCoins with a long vestingTime, this user will call the initialize function failed, and can not withdraw funds. Proof of Concept In MerkleResistor.sol L259: uint coinsPerSecond = totalCoins uint100 - tree.pctUpFront /...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/04 12:00 a.m.•28 views

Outdated Interface Implementation

Lines of code Vulnerability details Impact The Chainlink aggregator interface used by the project is outdated and does not permit the project to properly sanitize the price values it receives. Recommended Mitigation Steps The interface is to be updated according to the official Chainlink...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/02 12:00 a.m.•28 views

ABDKMath64 performs multiplication on results of division

Lines of code Vulnerability details Impact Solidity could truncate the results, performing multiplication before division will prevent rounding/truncation in solidity math. Recommended Mitigation Steps Consider ordering multiplication first. --- The text was updated successfully, but these errors...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/02 12:00 a.m.•28 views

GUniLPOracle can provide stale prices

Lines of code Vulnerability details As stale price is determined by assetUpdatedAt, which is the time since last timestamp, the price that is most recent, but wasn't updated for more than threshold, will be rejected, which makes system unavailable in such a case. In the same time real stale price...

6.5AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/05/02 12:00 a.m.•28 views

Fund loss or theft by attacker with creating a flash loan and setting SuperVault as receiver so executeOperation() will be get called by lendingPool but with attackers specified params

Lines of code Vulnerability details Impact According to Aave documentation, when requesting flash-loan, it's possible to specify a receiver, so function executeOperation of that receiver will be called by lendingPool. In the SuperVault there is no check to prevent this attack so attacker can use...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/28 12:00 a.m.•28 views

Cast to uint192 is unsafe

Judge @GalloDaSballo has assessed the 3rd item in QA Report 197 as Medium risk. The relevant finding follows: … Cast to uint192 is unsafe, user trying to deposit more than 2^192 would recevie less deposits balance. depositspidmsg.sender.amount += uint192amount; --- The text was updated...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/27 12:00 a.m.•28 views

first depositor can drain other depositors

Lines of code Vulnerability details in deposit, when the ratio totalSupply / balance is very high, the amount of the minted shares can round down to zero. Proof of Concept Alice is the first one to deposit in LiquidityPool. she deposits 1 basic unit of the token, therefore minting one lp token...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/27 12:00 a.m.•28 views

Oracle data feeds are insufficiently validated

Lines of code Vulnerability details Impact If the oracle price feeds are insufficiently validated, there will be pricing errors leading to the miss-pricing of assets/risk Proof of Concept The code does not verify that answeredInRound = roundID for both cases where an oracle is used, and the...

7.1AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/27 12:00 a.m.•28 views

First xERC4626 deposit exploit can break share calculation

Lines of code Vulnerability details Solmate convertToShares function follow the formula: assetDepositAmount totalShareSupply / assetBalanceBeforeDeposit. The share price always return 1:1 with asset token. If everything work normally, share price will slowly increase with time to 1:2 or 1:10 as...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/21 12:00 a.m.•28 views

ORACLE Data is not properly validated in ChainlinkPriceOracle.sol

Lines of code Vulnerability details Impact Price can be stale which can lead to wrong assetPerBaseInUQ return value Proof of Concept Oracle data feed is insufficiently validated. There is no check for stale price and round completeness. Tools Used Manual review, similar issue was found in yield...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/13 12:00 a.m.•28 views

Update initializer modifier to prevent reentrancy during initialization

Lines of code Vulnerability details Impact The solution uses: "@openzeppelin/contracts": "^4.0.0", "@openzeppelin/contracts-upgradeable": "^4.3.2", These dependencies have a known high severity vulnerability: Which makes these contracts vulnerable: contracts/helpers/CryptoPunksHelper.sol: 19:...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/08 12:00 a.m.•28 views

Undercollateralized loans possible

Lines of code Vulnerability details Impact The setPoolCollateralFactors function does not check that the collateral factor is 100%. It's possible that it's set to 200% and then borrows more than the collateral is worth, stealing from the pool. Recommended Mitigation Steps Disable the possibility ...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/08 12:00 a.m.•28 views

Arbitrary contract call within UniV3LpVault._swap with controllable swapPath

Lines of code Vulnerability details Impact UniV3LpVault.swap utilizes swapRouter.exactInput to perform swaps between two tokens. During swaps, transfer function of each token along the path will be called to propagate the assets. Since anyone can create a uniswap pair of arbitrary assets, it is...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/07 12:00 a.m.•28 views

Malicious users can frontrun borrowers trying to repay loans, causing DoS and possibly a loan default

Lines of code Vulnerability details Impact Attackers can listen for a borrower to call repayAndCloseLoan on a specific loanId, and frontrun their transaction with a call to lend, creating a new loan with an increased amount, causing the borrower's transaction to fail due to the new loanAmount bei...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/05 12:00 a.m.•28 views

NFTLoanFacilitator: Insufficient granularity allows for same-term loans to be accepted

Lines of code Vulnerability details Details & Impact It is possible for the calculated interest rate improvement to be zero if the existing interest rate is low enough ≤ 0.9% with 10% improvement rate. In such cases, lenders can compete to continually buyout each other with the same terms. The...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/04/02 12:00 a.m.•28 views

UserLock information can be found during emergency mode

Lines of code Vulnerability details When the contract is in blocked state emergency mode, the protocol wants to return an empty UserLock info, on calling the function getUserLock. However, there is another way, by which the users can find the same information. The below function is not protected...

6.6AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/30 12:00 a.m.•28 views

Swap Functions Do Not Verify Final Token Matches The Swapped Token

Lines of code Vulnerability details Impact When calling Swapper.executeSwaps there are no checks to ensure the received token matches the final swapped token. If these are different it may result in user funds being locked in the contract. This issue is present in each of the following functions:...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/30 12:00 a.m.•28 views

Improper Token Balance Check on swap()

Lines of code Vulnerability details Improper Token Balance Check on swap Description The swap can be separated in 2 paths, swap native to ERC20, or swap ERC20 to native. The contract performs a fromAssetId balance check before calling swap, mean that the attacker could periodically check for ERC2...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/24 12:00 a.m.•28 views

Use of deprecated Chainlink function latestAnswer

Lines of code Vulnerability details function getCurrentPriceaddress asset external view overrideProviderOracleManager, IProviderOracleManager returns uint256 address assetOracle = getAssetOracleasset; IEACAggregatorProxy aggregator = IEACAggregatorProxyassetOracle; int256 answer =...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/21 12:00 a.m.•28 views

Incorrect implementation of Lender can result in lost tokens

Lines of code Vulnerability details Impact MapleLoanInternals.sendFee should check returnData.length == 32 before decoding, otherwise if it returns bytes data, the abi.decode will return 0x20, result in lost tokens. Proof of Concept This contract can test that when the function returns bytes data...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/17 12:00 a.m.•28 views

Duplicate _tokenNameSuffix and _tokenSymbolSuffix will incorrectly update current Market

Lines of code Vulnerability details Impacted Function: createMarket Description: 1. Owner calls createMarket with tokenNameSuffix S1 and tokenSymbolSuffix S2 which creates a new market M1 with deployedMarketssalt pointing to M1. Here salt can be S which is computed using tokenNameSuffix and...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/03/09 12:00 a.m.•28 views

[WP-H0] When transferring tokens not in whitelist on Ethereum to Terra with CrossAnchorBridge.depositStable(), the funds may get frozen

Lines of code Vulnerability details In the current implementation of CrossAnchorBridge, all require that "Check that token is a whitelisted token" is commented out. As a result, users may send transcations with the non-whitelisted tokens and as they can not be processd properly on the Terra side,...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/23 12:00 a.m.•28 views

settleFunding will exceed block gas with more markets and activity

Lines of code Vulnerability details Impact As the number of supported markets grow, settleFunding will reach a point were it exceeds the block gas limit on Avalanche C-Chain. This will prevent users from calling the function and cause a wide spread Denial of Service. Looking at transactions for t...

6.6AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/23 12:00 a.m.•28 views

[WP-M6] Chainlink's latestRoundData might return stale results

Lines of code Vulnerability details function getUnderlyingPriceaddress underlying virtual external view returnsint256 answer if stablePriceunderlying != 0 return stablePriceunderlying; ,answer,,, = AggregatorV3InterfacechainLinkAggregatorMapunderlying.latestRoundData; answer /= 100; uint80 round,...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/09 12:00 a.m.•28 views

USDMPegRecovery does not account for fees

Lines of code Vulnerability details Curve.fi pools charge fees when adding or removing liquidity. The only time fees are not applied are when withdrawals are done using removeliquidity. USDMPegRecovery keeps track of tokens deposited and withdrawn, but does not keep track of fees assessed on thes...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/09 12:00 a.m.•28 views

Unconstrained fee

Lines of code Vulnerability details Impact Token fee in MasterChef can be set to more than 100%, for example by accident causing all deposit calls to fail due to underflow on subtraction when reward is lowered by the fee, thus breaking essential mechanics. Note that after the fee has been set to...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/09 12:00 a.m.•28 views

Potential for reentrancy on USDMPegRecovery.sol:withdraw()

Lines of code Vulnerability details Impact Re-entrancy Proof of Concept File: USDMPegRecovery.sol 110: function withdrawLiquidity calldata withdrawal external 111: Liquidity memory total = totalLiquidity; 112: Liquidity memory user = userLiquiditymsg.sender; 113: ifwithdrawal.usdm 0 114:...

7.1AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/09 12:00 a.m.•28 views

ConvexStakingWrapper._calcRewardIntegral() Has An Accounting Error When Updating reward.remaining

Lines of code Vulnerability details Impact The ConvexStakingWrapper.sol implementation makes several modifications to the original design. One of the key changes is the way rewards are distributed to stakers. A new ConcurRewardPool.sol contract is used to store rewards, allowing users to claim...

7.2AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/02/09 12:00 a.m.•28 views

Shelter funds can be stolen

Lines of code Vulnerability details Impact Shelter has a function withdraw that lets whitelisted users withdraw a specified amount of some token. The function does not check if the user has already withdrew the tokens. Since, a user can withdraw allowed amount any number of times, stealing all th...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/01/23 12:00 a.m.•28 views

setSherlockCoreAddress can be frontruned.

Handle wuwe1 Vulnerability details Proof of Concept SherDistributionManager.sol and AaveV2Strategy.sol are affected by this. For sdm, attacker can monitor mempool and frontrun the setSherlockCoreAddress . By setting the sherlockCore as a address controlled by attacker. Attacker can call pullRewar...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/01/13 12:00 a.m.•28 views

System Debt Is Not Handled When Insurance Pools Become Insolvent

Handle leastwood Vulnerability details Impact If an incident has occurred where an insurance policy is to be redeemed. The market is put into the MarketStatus.Payingout mode where the insurance.insured account is allowed to redeem their cover and receive a payout amount. Upon paying out the...

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

Users can lock themselves out of being able to convert VETH, becoming stuck with the deprecated asset

Handle TomFrenchBlockchain Vulnerability details I've put this as a medium issue as we're leaking value as users are stuck with assets which are likely to be worth much less as they are deprecated. It could also be low as it's not exploitable by outside parties and the loss isn't taken by the...

6.6AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/12/19 12:00 a.m.•28 views

Owner of the BasketFacet can cause DoS for exitPool(...) function

Handle Czar102 Vulnerability details Impact Provided an owner can add any tokens to the basket, it may add a token, for which the owner can burn tokens from any account. Then, after adding the token to the basket, the owner may burn tokens so that token.balanceofBasketFacet will be below MINAMOUN...

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

Allowing more than 256 epochs leads to loss of funds

Handle cmichel Vulnerability details The TwabRewards contract has an implicit restriction of 256 epochs per promotion as it uses a bitmask in a uint256 to mark claimed epochs 0-255, see isClaimedEpoch. "/// @dev We pack epochs claimed by a user into a uint256. So we can't store more than 255...

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

Basket.sol#publishNewIndex() Lack of input validation may cause fund loss to anyone who bonds an auction

Handle WatchPug Vulnerability details According to the newRatio formula in settleAuction, the maximum value of newRatio is factory.auctionMultiplier basket.ibRatio. However, since there is no validation for the value of minIbRatio when setting it, if the publisher publishes a newIndex with...

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

Extra fees paid for flash loans are unassigned

Handle 0x0x0x Vulnerability details Extra fees paid for flash loan are not included in total collected fees and they create excess balance which can be claimable by streamCreator. Extra fees should also get assigned to factory or atleast it should be clear that extra fees are for streamCreator...

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

Creating rewardTokens without streaming depositTokens

Handle bitbopper Vulnerability details Impact stake and withdraws can generate rewardTokens without streaming depositTokens. It does not matter whether the stream is a sale or not. The following lines can increase the reward balance on a withdraw some time after stake: // accumulate reward per...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/12/01 12:00 a.m.•28 views

RewardReinvestor.provideReinvest and splitReinvest are vulnerable to sandwich attacks as market price isn't checked

Handle hyh Vulnerability details Impact Liquidity provision can happen at a manipulated price which leads to immediate loss for liquidity provider i.e. IL happens right after liquidity provision in this case. This yields direct loss for an LP account owner, for example schematically: 0. Suppose...

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

MEV miner can mint larger than expected UDT total supply

Handle elprofesor Vulnerability details Impact UnlockProtocol attempts to calculate gas reimbursement using tx.gasprice, typically users who falsify tx.gasprice would lose gas to miners and therefore not obtain any advantage over the protocol itself. This does present capabilities for miners to...

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

function mint() No Tokens Will be Transfer to _recipient

Handle Meta0xNull Vulnerability details Impact mintrecipient, amount; At the end of mint, mint seems like responsible to transfer tokens to recipient but there is no code no function of mint in this contract. Thus No Tokens Will be Transfer to recipient. recipient who do not Receive Their Tokens...

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

Improper implementation of slippage check

Handle WatchPug Vulnerability details function redeemIERC20 token, uint amount, uint poolId, int128 idx, uint minOut external defend blockLocked whenNotPaused returnsuint out ibbtc.safeTransferFrommsg.sender, addressthis, amount; Pool memory pool = poolspoolId; if poolId = minOut, "Slippage Check...

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

No way to remove GasThrottle after deployment

Handle TomFrench Vulnerability details Impact Potential DOS on swaps Proof of Concept BasePool and BasePoolV2 make use of a validateGas modifier on swaps which checks that the user's gas price is below the value returned by FASTGASORACLE. Should FASTGASORACLE be compromised to always return zero...

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

TWAPOracle might register with wrong token order

Handle cmichel Vulnerability details The TWAPOracle.registerPair function takes in a factory and token0, token1. The function accepts a factory argument which means any Uniswap-like factory can be used. When using the actual Uniswap factory's IUniswapV2Factoryfactory.getPairtoken0, token1 call, i...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2021/11/15 12:00 a.m.•28 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/10/22 12:00 a.m.•28 views

Transfer function is unreliable

Handle Koustre Vulnerability details Impact Opcode pricing is not stable and should not be relied upon to protect against re-entrancy attacks. Proof of Concept Provide direct links to all referenced code in GitHub. Add screenshots, logs, or any other relevant proof that illustrates the concept...

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

Comptroller rewards can be artificially inflated and drained by manipulating [totalStaked - totalFrozen] (or: wrong rewards calculation)

Handle kenzo Vulnerability details By adding a small of amount of staking to a normal user scenario, and not approving this small amount as a loan for anybody, a staker can gain disproportionate amounts of comptroller rewards, even to the point of draining the contract. For example: Stakers A,B,C...

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

Setting Factory.bondPercentDiv to zero cause Denial of Service in Auction.bondForRebalance()

Handle pants Vulnerability details The function Factory.setBondPercentDiv allows the owner to set the state variable Factory.bondPercentDiv to zero. Impact If Factory.bondPercentDiv equals zero then the function Auction.bondForRebalance will always revert due to a division by zero: bondAmount =...

7.1AI score
SaveExploits0
Total number of security vulnerabilities5000