Lucene search
+L
Code423n4Most viewed

10190 matches found

Code423n4
Code423n4
•added 2022/12/16 12:00 a.m.•27 views

Unreleased locks cause the reward distribution to be flawed in BondNFT

Lines of code Vulnerability details Impact After a lock has expired, it doesn't get any rewards distributed to it. But, unreleased locks cause other existing bonds to not receive the full amount of tokens either. The issue is that as long as the bond is not released, the totalShares value isn't...

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

Storage collision in Collateral.sol

Lines of code Vulnerability details Vulnerability details collateral.sol is an upgradeable contract. Upgradeable contracts should not use the constructor to initialize variables, as these will be set in the contract storage of the implementation contract, instead of the intended contract storage ...

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

Unsafe usage of ERC20 methods

Lines of code Vulnerability details There are many weird ERC20 tokens that don't follow the standard ERC20 interface. Depending on the ERC20 token, some transfer errors may result in passing unnoticed, or some successful transfers may be treated as failed. The current implementation assumes that...

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

Overflow in BinMap can break pool

Lines of code Vulnerability details Impact The BinMap library performs multiplication on int32 values that can potentially overflow and cause the corresponding function calls to revert. The functions in question are used by essential Pool methods such as Pool.addLiquidity or Pool.swap and an...

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

Ownership of EscherERC721.sol contracts can be changed, thus creator roles become useless

Lines of code Vulnerability details Impact creator = has a CREATORROLE in Escher.sol non-creator = doesn't have a CREATORROLE in Escher.sol Currently creating an ERC721 edition via the Escher721Factory.sol contract requires a user to have the CREATORROLE in the main Escher.sol contract. This...

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

LPDA.sol and FixedPrice.sol will lock the funds forever

Lines of code Vulnerability details Impact Possibility of IDs collision The ether will be locked on FixedPrice or LPDA Proof of Concept On the same Escher721 Let’s say the first collection start from id = 0 and end on id = 10 So the next collection of the same Escher721 We can say the next part o...

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

MINTING OF NFT AT WILL

Lines of code Vulnerability details Impact register is an unrestricted public function where any new msg.sender is going to get through the modifier onlyUnregistered. With a non-zero recipient argument passed into the function, a new NFT is going to be minted to the recipient. Consequently, an...

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

Attackers can manipulate ERC4626 price per share to take an unfair share of future users

Lines of code Vulnerability details Impact The attacker can get funds from future users, and the future users will lose their funds. Proof of Concept A malicious early user can deposit with 1 wei of asset token and get 1 wei of shares. Then he/she can send 10000e18 - 1 of asset tokens and inflate...

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

Add reward token existence check in order to avoid user reward lost.

Lines of code Vulnerability details Impact The user can lost his rewards if the reward token is removed from the producerTokensproducerToken.rewardTokens list. If the reward token is removed, the rewardToken length is going to be zero, the user rewards going to be zero and the for statement will...

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

Bidder can abuse the bidIndices[] in finalize()

Lines of code Vulnerability details Impact finalize could be called by anyone, and the input array bidIndices is not sanity checked. Some malicious bidder can trick the bidIndices to always get the reserveQuotePerBase price. The seller would incur some loss. The other bidders are grieved, wasting...

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

Bid can be cancelled after being finalized

Lines of code Vulnerability details Impact The SizeSealed contract's cancelBid function can be called after auction has been finalized, thereby allowing the bidder to withdraw their quoteToken after bid is finalized This is possible by bypassing the if a.data.lowestQuote != typeuint128.max ||...

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

Owner can bypass reward token protection in recoverERC20 to instantly steal all tokens in contract

Lines of code Vulnerability details Description WardenPledge contract has a sweeping function recoverERC20 to handle mistakenly sent ERC20 tokens: function recoverERC20address token external onlyOwner returnsbool ifminAmountRewardTokentoken != 0 revert Errors.CannotRecoverToken; uint256 amount =...

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

If user sets a low gasPrice the operator would have to choose between being locked out of the pod or executing the job anyway

Lines of code Vulnerability details During the beaming process the user compensates the operator for the gas he has to pay by sending some source-chain-native-tokens via hToken. The amount he has to pay is determined according to the gasPrice set by the user, which is supposed to be the maximum g...

7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/25 12:00 a.m.•27 views

deployHolographableContract() uniqueness

Lines of code Vulnerability details Impact The holographable smart contract deployment can not guarantee the uniqueness. A malicious user could deploy multiple duplicate contracts, then the brigeIn could not make sure the uniqueness of the minted or burned NFT. Proof of Concept The salt and...

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

Optimistic bridging pattern, can lead to bridge exploitation

Lines of code Vulnerability details Impact Zero deposit Bridging. Wherease users can fake the depositing process but can mint multiple tokens in the destination chain. The bridging is optimistic, whereas the validation restricts to just checking the function selector and a no-error pattern, this...

7.2AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/01 12:00 a.m.•27 views

Type Error

Lines of code Vulnerability details Impact Type Error Proof of Concept Provide direct links to all referenced code in GitHub. Add screenshots, logs, or any other relevant proof that illustrates the concept. Tools Used Foundry - Forge Recommended Mitigation Steps Consider changing uint to int and ...

7.2AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/01 12:00 a.m.•27 views

computeAddress does not follow the standard procedure to compute the address. The contract can not create pool for some pairs due to hash collision

Lines of code Vulnerability details Impact Poor source of randomness, an attacker can easily decipher the computed address. The contract can be easily tricked. This can cause hash collision, due to this, for some pairs, the contract can not create pool. Proof of Concept AlgebraFactory.solL123 : T...

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

Tokens with fee on transfer are not supported

Lines of code Vulnerability details Impact There are ERC20 tokens that charge fee for every transfer or transferFrom. If this tokens are unsupported, ensure there is proper documentation about it. Proof of Concept 6 instances in 2 files: contracts/shutdown/fuse/RariMerkleRedeemer.sol...

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

Add to Blacklist function

Lines of code Vulnerability details L-2. Add to Blacklist function Description: Cryptocurrency mixing service, Tornado Cash, has been blacklisted in the OFAC. A lot of blockchain companies, token projects, NFT Projects have blacklisted all Ethereum addresses owned by Tornado Cash listed in the US...

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

Call() should be used instead of transfer() on an address payable

Lines of code Vulnerability details Impact The use of the deprecated transfer function for an address will inevitably make the transaction fail when : 1. The withdrawer smart contract does not implement a payable fallback function. 2. The withdrawer smart contract implements a payable fallback...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/07/17 12:00 a.m.•27 views

There is no method to unignore any ignored pair.

Lines of code Vulnerability details Impact The Witch contract uses setIgnoredPair function to prevent the liquidation of accepted pairs on the governance level. However, there is no method to remove these pairs from the ignoredPairs mapping. Proof of Concept Imagine there are vaults with UST/fyUS...

6.7AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/06/26 12:00 a.m.•27 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/19 12:00 a.m.•27 views

Rescue ETH at InfinityStaker.sol is incorrectly implemented

Lines of code Vulnerability details Impact Admins are unable to recover any ETH locked in the contract PoC The function rescueETHInfinityStaker.sol is incorrectly implemented. It is using msg.value instead of the balance of the contract /// @dev Admin function to rescue any ETH accidentally sent ...

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

getCurrentPrice will be return a higher value than expected due to insufficient check in isTimeValid

Lines of code Vulnerability details The Boolean value will always return true if start price is zero. The condition will be sufficiently fulfilled since a time will be set in the future but no time is set in the past or at current time: sumCurrentPrices uses the returned value of getCurrentPrice...

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

Swap routes are hardcoded for pools that do not exist yet.

Lines of code Vulnerability details Impact The route for swapping auraBAL to AURA is hardcoded and does not allow any flexibility. Proof of Concept The route for this swap is hardcoded to auraBAL - BAL/ETH BPT - WETH - AURA, with specific pool IDs. This seems to be done for the sake of simplicity...

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

RewardHandler.burnFees() will work only once and revert after that if burnedAmount is different.

Lines of code Vulnerability details Impact RewardHandler.burnFees will work only once and revert after that if burnedAmount is different. Proof of Concept OpenZeppelin’s safeApprove will revert if the account already is approved and the new safeApprove is done with a non-zero value. Tools Used...

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

withdraw() and merge() functions of VotingEscrow won't work when an approved user(not owner) calls because _burn() function fails.

Lines of code Vulnerability details Impact withdraw and merge functions of VotingEscrow won't work when an approved usernot owner calls. Proof of Concept withdraw and merge functions call burn function inside and burn function calls removeTokenFrom using msg.sender. But removeTokenFrom requires...

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

BathToken.sol A malicious early user/attacker can manipulate the vault's pricePerShare to take an unfair share of future users' deposits

Lines of code Vulnerability details function deposituint256 assets, address receiver internal returns uint256 shares uint256 pool = underlyingBalance; uint256 before = underlyingToken.balanceOfaddressthis; // Assume caller is depositor underlyingToken.transferFrommsg.sender, addressthis, assets;...

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

UNISWAP_FEE is hardcoded which will lead to significant losses compared to optimal routing

Lines of code Vulnerability details Impact In YieldManager, UNISWAPFEE is hardcoded, which reduce significantly the possibilities and will lead to non optimal routes. In particular, all swaps using ETH path will use the wrong pool as it will use the ETH / USDC 1% one due to this line. Proof of...

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

Setting a high feeRate can block exercise or cause negative flow of funds

Lines of code Vulnerability details Impact When an admin intentionally or unintentionally sets a feeRate greater than 1e18 100%, The exercise function can fail with arithmetic operation underflow at line 289 In the case, when beneficiary is connected to multiple vaults, the exercise function will...

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

Users Can Prevent Excess Tokens From Being Withdrawn By The Pool Creator In withdrawExcessRewards()

Lines of code Vulnerability details Impact Because pools will likely never be fully utilised by stakers while active, the following assumption in withdrawExcessRewards can be broken by preventing any receipt withdrawal: requirepool.totalDepositsWei == 0, 'Cannot withdraw until all deposits are...

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

FlywheelCore.setBooster() can be used to steal unclaimed rewards

Lines of code Vulnerability details Impact A malicious authorized user can steal all unclaimed rewards and break the reward accounting Even if the authorized user is benevolent the fact that there is a rug vector available may negatively impact the protocol's reputation. Furthermore since this...

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

In ERC20Gauges, contribution to total weight is double-counted when incrementGauge is called before addGauge for a given gauge.

Lines of code Vulnerability details Impact The impact depends really on how gauges are used by other contracts. The most obvious consequence I can imagine is that some other contract distributes rewards based on calculateGaugeAllocation. However, because getStoredWeighttotalWeight, currentCycle i...

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

mintBorrowTicketTo can be a contract with no onERC721Received method, which may cause the BorrowTicket NFT to be frozen and put users' funds at risk

Lines of code Vulnerability details IERC721MintableborrowTicketContract.mintmintBorrowTicketTo, id; function mintaddress to, uint256 tokenId external override loanFacilitatorOnly mintto, tokenId; If mintBorrowTicketTo is a contract that does not implement the onERC721Received method, in the curre...

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

NonCustodialPSM.mint ignores mint buffer reduced amount, mostly disabling mint rate control

Lines of code Vulnerability details Impact VOLT minting rate control doesn't happen when RateLimited's doPartialAction is true as NonCustodialPSM doesn't use the returned amount value, minting the full amount even when it was reduced by current mint buffer size limitation. There are two issues wi...

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

Block delays can be bypassed with two flash loans instead of one

Lines of code Vulnerability details The README.md states: Withdrawals must be requested in a prior block via initiateWithdrawaluint256 amount . The number of blocks until a request expires is settable by the vault owner . This is mainly for mitigating the feasibility of a flash loan attack. Impac...

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

[WP-H4] Input should be validated on-chain to avoid fund loss caused by admin's misinput

Lines of code Vulnerability details In the current design/implementation, the admin of BribeVault is a super privileged role of the system. However, the inputs of the admin to some of the most critical methods are not being validated properly. This can lead to loss of funds to users caused by the...

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

Wrong reward token calculation in MasterChef contract

Lines of code Vulnerability details Impact When adding new token pool for staking in MasterChef contract function addaddress token, uint allocationPoints, uint16 depositFee, uint startBlock All other, already added, pools should be updated but currently they are not. Instead, only totalPoints is...

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

It is possible to liquidate not existing account

Handle 0x0x0x Vulnerability details It is possible to liquidate an address for any product when collateral = maintenance = 0. So in other words, if a user have never used a product and deposited collateral, the user can get liquidated blacklisted from the product by anyone, since a liquidated...

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

Reentrancy vulnerability in Basket contract's initialize() method.

Handle broccolirob Vulnerability details A malicious "publisher" can create a basket proposal that mixes real ERC20 tokens with a malicious ERC20 token containing a reentrancy callback in it's approve method. When the initialize method is called on the newly cloned Basket contract, a method calle...

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

Locke.sol:Stream - arbitraryCall can be used to drain incentive tokens

Handle ScopeLift Vulnerability details Impact Governor can drain incentive balance via arbitraryCall Proof of Concept The Stream contract offers createIncentive and claimIncentive which is the way the contract "expects" incentives to go. Access to claiming incentives is limited to the stream...

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

_addTostakepadding() will return 0 for users who already had a stakepadding but would like to add on top of their previous stake with 'newStakePadding' on line 186-190(AbstractRewardMine.sol)

Handle 0xwags Vulnerability details Impact The handleStakePadding function handles the calculations for users without a prior stake padding and the ones who already had a stakepadding but want to add to their existing stakepadding. The condition within 'newStakePadding' will return false for user...

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

swapExactTokensForTokens in is used with amountOutMin = 0

Handle 0x0x0x Vulnerability details Impact In UniswapHandler.sol two important functions sellMalt and buyMalt use swapExactTokensForTokens with amountOutMin = 0. This is a big problem since miners can exploit this intensively. So miners can strongly manipulate the price, since they can order the...

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

ReferralFeePoolV0.sol#claimRewardAsMochi() Array out of bound exception

Handle WatchPug Vulnerability details function claimRewardAsMochi external IUSDM usdm = engine.usdm; address memory path = new address; path0 = addressusdm; path1 = uniswapRouter.WETH; path2 = addressengine.mochi; usdm.approveaddressuniswapRouter, rewardmsg.sender; // we are going to ingore the...

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

User Fund loss in case of Unsupported Market token deposit

Handle csanuragjain Vulnerability details Impact User funds can be lost as current logic cannot withdraw unsupported market token even though deposit can be done for same Proof of Concept 1. Navigate to 2. Check the function deposit function depositaddress token, uint256 amount external override...

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

return value of 0 from ecrecover not checked

Handle gpersoon Vulnerability details Impact The solidity function ecrecover is used, however the error result of 0 is not checked for. See documentation: "recover the address associated with the public key from elliptic curve signature or return zero on error. " Now you can supply invalid input...

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

Gas griefing attack on the removeUserActiveBlocks function

Handle shw Vulnerability details Impact The consumed gas to remove a user's active block is proportional to the total number of array elements i.e., block numbers. However, the array size can be arbitrarily increased by an attacker with only paying gas fees, causing a gas griefing attack when the...

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

YieldMath.sol / Log2: >= or > ?

Handle gpersoon Vulnerability details Impact The V1 version of YieldMath.sol contains "=" larger or equal, while the V2 version of YieldMath.sol containt "" larger in the log2 function. This change doesn't seem logical and might lead to miss calculations. The difference is present in a number of...

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

Impossible to call withdrawReward fails due to run out of gas

Handle s1m0 Vulnerability details Impact The withdrawReward fails due to the loop at . From my testing the dayDiff would be 18724 and with a gasLimit of 9500000 it stops at iteration 270 due to the fact that lastUpdatedDay is not initialized so is 0. Other than that it could run out of gas also f...

6.8AI score
SaveExploits0
Code423n4
Code423n4
•added 2024/01/08 12:00 a.m.•26 views

tokens can be deposited and immediately withdrawn before the intended lock time by depositing right before expiry

Lines of code Vulnerability details Impact tokens can be deposited and immediately withdrawn before the intended lock time by depositing right before expiry. Proof of Concept There is edge cases around the locking and unlocking periods that are not fully considered in the contract. Specifically,...

7AI score
SaveExploits0
Total number of security vulnerabilities5000