Lucene search
K
Code423n4Most viewed

10190 matches found

Code423n4
Code423n4
•added 2022/12/05 12:0 a.m.•26 views

Incorrect use of AddressAliasHelper.applyL1ToL2Alias() in _isAuthorized()

Lines of code Vulnerability details Summary In the isAuthorized function, the require statement checks if the msg.sender is equal to the result of calling AddressAliasHelper.applyL1ToL2Alias with relayer as the argument. However, this is incorrect, as AddressAliasHelper.applyL1ToL2Alias is intend...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2022/08/03 12:0 a.m.•26 views

No Storage Gap for Upgradeable Contract Might Lead to Storage Slot Collision

Lines of code Vulnerability details Impact For upgradeable contracts, there must be storage gap to "allow developers to freely add new state variables in the future without compromising the storage compatibility with existing deployments" quote OpenZeppelin. Otherwise it may be very difficult to...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/07/08 12:0 a.m.•26 views

Chainlink's latestRoundData might return stale or incorrect results

Lines of code Vulnerability details Impact latestRoundData is used to fetch the asset price from a Chainlink aggregator, but it's missing additional validations to ensure that the round is complete. If there is a problem with Chainlink starting a new round and finding consensus on the new value f...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2021/09/08 12:0 a.m.•26 views

Incorrect accounting on transfer-on-fee/deflationary tokens in Gravity

Handle shw Vulnerability details Impact The sendToCosmos function of Gravity transfers amount of tokenContract from the sender using the function transferFrom. If the transferred token is a transfer-on-fee/deflationary token, the actually received amount could be less than amount. However, since...

6.9AI score
Exploits0
Code423n4
Code423n4
•added 2023/12/21 12:0 a.m.•25 views

Swap Input Validation

Lines of code Vulnerability details Input Validation: - The swap function assumes that fpos and spos are valid positions within the heap. - Ensure that you are providing valid positions, and consider adding checks to verify that fpos and spos are within the bounds of your heap. requirefpos size &...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/10/20 12:0 a.m.•25 views

The same console addresses on other chains can be captured by compromised or malicious owner

Lines of code Vulnerability details Impact The same order of owners addresses lets generate the same console address on all chains. But any owner from the list can deploy console accounts on other chains with threshold parameter equals 1 and then change owners in these accounts, i.e. capture thes...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/09/06 12:0 a.m.•25 views

the perpetualVaultLP.sol is vulnable by flashloan attack

Lines of code Vulnerability details impact The perpVaultLp contract is susceptible to a flash loan attack. An attacker can exploit the vulnerability by executing flash loan transactions using both the deposit and redeem functions. This allows the attacker to acquire extra rdpx tokens and increase...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/05/29 12:0 a.m.•25 views

CrossDomainMessenger relayMessage Vulnerability

Lines of code Vulnerability details Impact The vulnerability allows an attacker to manipulate the sender address sender parameter when relaying a message from Layer 2 L2 to Layer 1 L1 in a cross-domain scenario. The issue arises due to the use of the L2CrossDomainMessenger contract address...

6.9AI score
Exploits0
Code423n4
Code423n4
•added 2023/02/20 12:0 a.m.•25 views

Function stabilize() might always revert because of overflow since Malt contract use solidity 0.8

Lines of code Vulnerability details Impact MaltDataLab fetched priceCumulative directly from Uniswap V2 pool to calculate price of Malt token. However, it is noticed that Uniswap V2 pool use Solidity 0.5.16, which does not revert when overflow happen. In addition, it is actually commented in...

7.2AI score
Exploits0
Code423n4
Code423n4
•added 2022/10/01 12:0 a.m.•25 views

Frontrunning the initialize function can drain the LP initial deposit

Lines of code Vulnerability details Impact An attacker can frontrun the initialize function in AlgebraPool.sol to set an unexpected price and can cause loss of funds for the initial LP deposit. Proof of Concept function initializeuint160 initialPrice external override requireglobalState.price == ...

7AI score
Exploits0
Code423n4
Code423n4
•added 2022/06/26 12:0 a.m.•25 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
Exploits0
Code423n4
Code423n4
•added 2022/04/21 12:0 a.m.•25 views

UniswapV2PriceOracle.sol currentCumulativePrices() will revert when priceCumulative addition overflow

Lines of code Vulnerability details uint price0Cumulative, uint price1Cumulative, uint32 blockTimestamp = addresspair.currentCumulativePrices; Because the Solidity version used by the current implementation of UniswapV2OracleLibrary.sol is =0.8.7, and there are some breaking changes in Solidity...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/14 12:0 a.m.•24 views

Unintended or Malicious Use of Prize Winners' Hooks

Lines of code Vulnerability details Impact The setHooks function in Vault.sol allows users to set arbitrary hooks, potentially enabling them to make external calls with unintended consequences. This vulnerability could lead to various unexpected behaviors, such as unauthorized side transactions...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/06/09 12:0 a.m.•24 views

Cross contract reentrancy attack through changing the xDomainMsgSender

Lines of code Vulnerability details Impact The use of the guaranteed safe CrossDomainMessenger for withdrawals can result in permanent blockages when the recipient address interacts with external addresses, which is an important feature for interoperability and is expected to be widely utilized...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/02/02 12:0 a.m.•24 views

SubprotocolRegistry is vulnerable to malicious names

Lines of code Vulnerability details Impact A malicious subprotocol can register a name that looks the same as any other protocol. Users may use the malicious subprotocol because they can't distinguish the names, and be cheated out of subprotocolFee. Proof of Concept Any subprotocol can be...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/10/12 12:0 a.m.•24 views

Cached EIP-712 domain separator may lead to replay attacks

Lines of code Vulnerability details Impact The usage of a cached DOMAINSEPARATOR present in the initializer of the GraphTokenUpgradeable contract may lead to replay attacks in the case of an eventual fork of the chain, since the cached domain separator is constructed with an initial chainId that...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/06/29 12:0 a.m.•24 views

redeemFresh does not work

Lines of code Vulnerability details Impact The CNote contract uses the CToken contract's redeemFresh function to perform redeem operations. However, since the CNote contract does not hold note tokens, the getCashPrior returns 0 and is less than the redeemAmount, causing the redeemFresh function t...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/06/16 12:0 a.m.•24 views

no slippage check

Lines of code Vulnerability details in the function swapAndAddLiquidity it makes a call swapExactTokensForTokens with slippage hard coded to 1 this could lead to the user receiving much less tokens than expected due to being frontrun / sandwiched which will result in a loss of funds recommend...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/05/09 12:0 a.m.•24 views

ERC20 tokens with before/afterTokenTransfer hooks can be manipulated to cause submitBatch to fail

Lines of code Vulnerability details Impact Currently submitBatch processes a batch of Cosmos to Ethereum transactions. As part of this method ERC20 tokens are transferred to the desired destination from the Gravity bridge, as approved by the current validator set. For ERC20 tokens without a...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/03/30 12:0 a.m.•24 views

[WP-H8] Admin of the upgradeable proxy contract (the diamond contract) can rug users

Lines of code Vulnerability details Use of Upgradeable Proxy Contract Structure The Diamond Structure allows the logic of the contract to be arbitrarily changed. This allows the proxy admin to perform malicious actions e.g., taking funds from users' wallets up to the allowance limit. This action...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2021/08/26 12:0 a.m.•24 views

Arbitrary Logic Enables ERC20 Theft

Handle ElliotFriedman Vulnerability details Severe Issue: ERC20 Token Theft Using Arbitrary Logic There are 2 ways that this bug can be used to drain funds from the bridge. Both are catastrophic and result in total loss of funds. The 1st method is horrible, the second method is diabolical as it c...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2024/01/08 12:0 a.m.•23 views

Wrong invocation of Whirpools's updateFeesAndRewards will cause it to always revert

Lines of code Vulnerability details Impact Deposits will be unwithdrawable from the lockbox Proof of Concept If the entire liquidity of a position has been removed, the withdraw function calls the updateFeesAndRewards function on the Orca pool before attempting to close the position. function...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/12/12 12:0 a.m.•23 views

Excess funds sent via msg.value not refunded

Lines of code 201 Vulnerability details The code below allows the caller to provide Ether, but does not refund the amount in excess of what's required, leaving funds stranded in the contract. The condition should be changed to check for equality, or the code should refund the excess. File:...

7.2AI score
Exploits0
Code423n4
Code423n4
•added 2023/11/15 12:0 a.m.•24 views

Missing sanity checks in Chainlink response

Lines of code Vulnerability details Summary Chainlink responses from price feeds are being used without any sanity checks. Impact The ChainlinkPriceOracle contract is used to interface with the Chainlink price feeds for the different LST assets in scope in the protocol. The current implementation...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/10/06 12:0 a.m.•23 views

Gas that was sent by LayerZero can get stuck in the contract in some cases

Lines of code Vulnerability details If a tx on the destination chain calls back the chain from where the transaction was initiated by the user, the first transaction on the source chain needs to "airdrop" gas to the destination chain so it is able to call back the source chain. The problem is tha...

7.3AI score
Exploits0
Code423n4
Code423n4
•added 2023/08/07 12:0 a.m.•23 views

rngComplete() function is vulnerable to an array out of bounds error

Lines of code Vulnerability details Impact A malicious actor can manipulate the AuctionResult passed to RewardLib.rewards to make it return a short rewards array Proof of Concept The issue is that there is no check that i stays within the bounds of rewards. If rewards is shorter than expected, th...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/05/11 12:0 a.m.•23 views

Using memory instead of storage in 'redeemPositions' will result in incorrect LP Balance

Lines of code Vulnerability details Impact This bug could lead to a situation where a user can 'redeem' their positions without the associated liquidity positions LPs being properly reset. This could result in the user being able to artificially inflate their LP balance, which could lead to...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/03/18 12:0 a.m.•23 views

The Risk of Adding an Incorrect Previous Block Hash Value in a Blockchain Network

Lines of code Vulnerability details Impact There is a risk of adding an incorrect previous block hash value to a block, either intentionally or unintentionally. If the previous block hash value is incorrect, it means that the data in the previous block has been tampered with, and the current bloc...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/01/19 12:0 a.m.•23 views

Attacker can fake an ERC20 token as the paymentToken and call ClearingHouse.safeTransferFrom() to prematurely settle the auction, preventing the actual auction from completing

Lines of code Vulnerability details Impact ClearingHouses are deployed for each new loan and settle payments between Seaport auctions and Astaria Vaults if a liquidation occurs. However, due to the lack of proper data validation in the current implementation, anyone can fake a token and transfer ...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/11/28 12:0 a.m.•23 views

Compounding is vulnerable to sandwich attack

Lines of code Vulnerability details Impact Function compound is called in every deposit/withdraw in AutoPxGmx contract. It claim rewards in form of gmxBaseReward and swap them to gmx token. They used amountOutMinimum from input params gmxAmountOut = SWAPROUTER.exactInputSingle...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/10/24 12:0 a.m.•23 views

LBRouter's swapAVAXForExactTokens is unavailable when any extra AVAX funds supplied

swapAVAXForExactTokens logic includes transferring out the excess amount of the native funds supplied by a caller. However, amountsIn0 - msg.value amount that swapAVAXForExactTokens calculates for transfer out is negative. The reason is the inverted amount calculation, i.e. according to the logic...

6.5AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/08 12:0 a.m.•23 views

Rounding error for low decimal token

Lines of code Vulnerability details Impact Some token has low decimal USDC has only 6, as a result, the rounding may introduce substantial error in stable pair calculation, causing wrong getAmountOut quote, at the end lead to fund loss in swap function. Malicious user can abuse the wrong quote to...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2022/06/21 12:0 a.m.•23 views

WETH.allowance() returns wrong result.

Lines of code Vulnerability details Impact WETH.allowance returns wrong result. I can't find other contracts that use this function but WETH.sol is a base contract and it should be fixed properly. Proof of Concept In this function, the "return" keyword is missing and it will always output 0 in th...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/01/10 12:0 a.m.•23 views

Fee-on transfer tokens not supported

Handle pmerkleplant Vulnerability details Impact There exist ERC20 tokens that charge a fee for every transfer. This kind of token does not work correctly with the PoolTemplate::deposit function. Proof of Concept The PoolTemplate::deposit function mints an amount of iTokens based on the function'...

7AI score
Exploits0
Code423n4
Code423n4
•added 2021/10/18 12:0 a.m.•23 views

Incorrect checking of signature length

Handle JMukesh Vulnerability details Impact signature which have SignatureMode.EthSign/SignatureMode.EIP712 have length 65 , so all signature coming through both mode will be reverted Proof of Concept Tools Used manual review Recommended Mitigation Steps update the correct signature length --- Th...

7AI score
Exploits0
Code423n4
Code423n4
•added 2024/01/08 12:0 a.m.•22 views

CM can delegatecall to any address and bypass all restrictions

Lines of code Vulnerability details Impact The GuardCM contract is designed to restrict the Community Multisig CM actions within the protocol to only specific contracts and methods. This is achieved by implementing a checkTransaction method, which is invoked by the CM GnosisSafe before every...

8.2AI score
Exploits0
Code423n4
Code423n4
•added 2024/01/08 12:0 a.m.•22 views

veOLAS.sol : PointVoting's slope and bias values are reset to zero when depositing for another account.

Lines of code Vulnerability details Impact Since the bias vote weight and slope are reset, the voting power of as user is nullified. Proof of Concept veOLAS.sol is escrow based contract where the OLAs tokens are locked for certain amount of time in order to gain the voting power. This voting powe...

7.4AI score
Exploits0
Code423n4
Code423n4
•added 2023/12/21 12:0 a.m.•22 views

Delegation to address(0) causes permanent loss of voting power

Lines of code Vulnerability details Impact As stated in the comment on line 12 of NontransferableERC20Votes.sol, delegation of vote power can be done through the delegate function or by providing a signature to be used with delegateBySig. However, these functions do not prevent users from...

7AI score
Exploits0
Code423n4
Code423n4
•added 2023/12/08 12:0 a.m.•22 views

Insecure and Inflexible Forwarder Approval Mechanism (Full Access Grant)

Lines of code Vulnerability details Impact The current implementation of the onlyApprovedForwarder modifier in the Ocean smart contract has several negative impacts: 1. Security Risk: Users are exposed to a significant security risk if their forwarder is compromised. An attacker can exploit full...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2023/08/07 12:0 a.m.•22 views

Avoid the use of hard coded slippage

Lines of code Vulnerability details Impact In OptionsPositionManager.sol, swapExactTokensForTokens has used the hardcoded slippage of 1% which is used in withdrawOptionAssets and swapTokens functions. function swapExactTokensForTokensIUniswapV2Router01 ammRouter, IPriceOracle oracle, uint amount,...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/08/07 12:0 a.m.•22 views

A malicious deployer can set auctionTargetTime close to auctionDuration to make it hard or impossible for anyone to win a reward.

Lines of code Vulnerability details Impact A malicious deployer could set auctionTargetTime very close to auctionDuration, making it hard/impossible for anyone to win a reward leading to losses Proof of Concept In the constructor, auctionTargetTime is not validated to be less than auctionDuration...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/05/15 12:0 a.m.•22 views

When borrowRateMantissa is higher than the limit value, VToken contract will be DOS

Lines of code Vulnerability details Impact File: VToken.sol 678 function accrueInterest public virtual override returns uint256 --skip-- 695 uint256 borrowRateMantissa = interestRateModel.getBorrowRatecashPrior, borrowsPrior, reservesPrior; 696 requireborrowRateMantissa borrowRateMaxMantissa. Thi...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2023/05/15 12:0 a.m.•22 views

AMO2 doesn't add the lp balance of the CVXStaker to the withdrawable token amount

Lines of code Vulnerability details Impact The lp tokens held by CVXStaker can't be able to used or withdrew by AMO2. Although the jam is not permanent and the owner of the CVXStaker can use recoverToken function to withdraw them, it will cause the functions about removing liquidity break down in...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/03/30 12:0 a.m.•22 views

sFrxEth may revert on redeeming non-zero amount

Lines of code Vulnerability details Impact Unstaking is blocked. Proof of Concept When unstaking the withdraw of each derivative is called. SfrxEth.withdraw calls IsFrxEthSFRXETHADDRESS.redeemamount, addressthis, addressthis;. This function may revert if amount is low due to the following line in...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/03/19 12:0 a.m.•22 views

[Medium - 1] Ecrecover precompile doesn't behave the same as the one from Ethereum

Lines of code Vulnerability details Impact According to the Ethereum yellow paper and in the specifications of the ecrecover precompile, it is stated that if the ecrecover doesn't return anything denoted by āˆ…, then the return should be 0 as well. If we take a look at the current ecrecover...

6.6AI score
Exploits0
Code423n4
Code423n4
•added 2022/11/09 12:0 a.m.•22 views

Validator can revert block at no cost.

Lines of code Vulnerability details Impact Validator can revert block at no cost. Proof of Concept the validator should only call this function on Executor.sol to revert the unexecuted blocks if the block is not really not executable. /// @notice Reverts unexecuted blocks /// @param newLastBlock...

6.6AI score
Exploits0
Code423n4
Code423n4
•added 2022/10/23 12:0 a.m.•22 views

LBPair swap() can be front-runned, a malicious attacker can call swap with higher gas than a user, getting the user swap amount transferred to the attacker address

Lines of code Vulnerability details Impact In the LBPair.sol contract, when a user calls swap after transferring tokens to the Pair, a malicious attacker can front-run that tx then call swap on the same pair with the parameter to changed to an malicious address of his choice, paying a higher gass...

7AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/25 12:0 a.m.•22 views

xERC4626.sol#beforeWithdraw will fail under certain conditions

Lines of code Vulnerability details Impact Valid withdrawals will fail in certain edge cases Proof of Concept function totalAssets public view override returns uint256 // cache global vars uint256 storedTotalAssets = storedTotalAssets; uint192 lastRewardAmount = lastRewardAmount; uint32...

6.6AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/19 12:0 a.m.•22 views

Unchecked Transfer

Lines of code Vulnerability details High Severity - Unchecked Transfer Line 167 of Vault.sol has an unchecked Transfer. Reference and recommendation from slither. Tools Used: Slither --- The text was updated successfully, but these errors were encountered: All reactions...

6.9AI score
Exploits0
Code423n4
Code423n4
•added 2022/08/17 12:0 a.m.•22 views

Chainlink oracle lacks proper validation

Lines of code Vulnerability details Impact Calls to the Chainlink price oracle via latestRoundData in FraxlendPairCore.sol use the correct function latestRoundData per Chainlink's documentation, but lack the recommended validations to ensure that the round is complete and does not return stale...

6.8AI score
Exploits0
Total number of security vulnerabilities5000