Lucene search
K
Code423n4Recent

10190 matches found

Code423n4
Code423n4
•added 2023/07/21 12:0 a.m.•8 views

Permits may be reused after token upgrade

Lines of code Vulnerability details Impact The StandardizedToken contract inherits the ERC20Permit contract which in the case of an upgradable/proxied Token would allow permits for a previous version of the Token to be used on any subsequent version of it. NOTE that ERC20Permit is not explicitly ...

7.2AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/21 12:0 a.m.•5 views

newer tx can remain un approved due nto previous tx not passing

Lines of code Vulnerability details Impact Newer transaction will not get approved because previous on es have not been approved or rejected Proof of Concept Let's say two out of 3 addresses sign a transaction which requires 3 signers then after some time the 3 now sign another transaction it won...

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

Users do not get charged for the value their proposal will need

Lines of code Vulnerability details Impact Depending on whether the destination chain InterchainProposalExecutor's native token balance the transaction will either steal funds or will fail. Proof of Concept Users can provide an amount of native tokens they want to send to the call they will make ...

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

[H] Users can lose their funds if the transaction reverts on destination chain

Lines of code Vulnerability details Impact The transmitSendToken function in the contract facilitates cross-chain token transfers. For contracts involving ERC20 tokens it is also expected that, should a contract call fail, one's tokens are not lost/transferred elsewhere. However, the function doe...

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

Accepted proposal may be recreated at the same address with a malicious proposal if there's a self destruct function in the accepted proposal

Lines of code Vulnerability details Impact A malicious proposal can take over the contract address of the accepted proposal through self-destruct Proof of Concept This issue is regarding the Tornado cash hack, whereby the attacker deploys different contracts at the same address. If the proposal...

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

M-07 Unmitigated

Lines of code Vulnerability details Original Issue code-423n4/2023-06-angle-findings8 Details This issue shows users may get fewer tokens than expected when the collateral list order changes. As mitigation, it recommends checking the length of minAmountsOut and ts.collateralList as well as the...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/18 12:0 a.m.•8 views

Upgraded Q -> 2 from #392 [1689707598962]

Judge has assessed an item in Issue 392 as 2 risk. The relevant finding follows: 4 - The liquidator can be frontrunned while is depositing prizeTokens to the prizePool The liquidator should introduce prizeTokens to the prizePool before he calls the Vault.liquidate function. The problem is that a...

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

M-07 Unmitigated

Lines of code Vulnerability details The fix addresses the scenarios when collaterals are removed between the crafting of the minAmountsOut list and the submission of the transaction. Then, we will have amounts.length minAmountOuts.length, meaning that the following line causes a revert: if...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/18 12:0 a.m.•8 views

M-04 Unmitigated

Lines of code Vulnerability details While the fix improves the APR estimation for the case that is described in the finding, it significantly worsens it for other scenarios which may happen in practice when we assume underlying staking protocols with relatively constant APRs. For instance, consid...

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

Upgraded Q -> 2 from #93 [1689707967381]

Judge has assessed an item in Issue 93 as 2 risk. The relevant finding follows: L-01 - no check on the deployedVaults mapping in the VaultFactory can lead to duplicate vaults being created Mitigation - add an if check to not recreate the same vault: ifdeployedVaultsvault revert.... --- The text w...

6.9AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/18 12:0 a.m.•9 views

Attacker can brick redemptions by donating a small amount

Lines of code Vulnerability details Impact While the fix properly fixes the issue of collateralization ratio overflows that can no longer occurs, it enables DoS attacks on the redemption mechanism: Issue description Consider the example that was already provided code-423n4/2023-06-angle-findings9...

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

Upgraded Q -> 2 from #422 [1689707351452]

Judge has assessed an item in Issue 422 as 2 risk. The relevant finding follows: 01 In the function PrizePool.setDrawManager, anyone can frontrun it and become the drawManager Reading the documentation of the Prize Pool contract, the following is specified: The Prize Pool allows a 'draw manager'...

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

Guardian can brick SavingsVest contract accidentally

Lines of code Vulnerability details Impact The fix to M-06 introduces a new vulnerability, as it turns a missing validation that previously was recoverable i.e., only a minor thing into an irrecoverable error, resulting in a permanent loss of funds. Proof of Concept Consider the scenario where th...

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

Users with DEPLOY permission can grief each other through CREATE2

Lines of code Vulnerability details Bug Description In ERC725XCore.sol, the deployCreate2 function uses Openzeppelin's Create2.deploy to deploy new contracts: ERC725XCore.solL253-L267 function deployCreate2 uint256 value, bytes memory creationCode internal virtual returns bytes memory newContract...

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

Sponsor function allows voiding some elses chance to win

Lines of code Vulnerability details Impact Anyone can delegate someone elses balance to the sponsorship address, increasing their own likelihood of winning, while voiding the victims chance. Proof of Concept The issue is in the call-chain starting with Vault.sponsor: //Vault function sponsoruint2...

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

Balance invariant between individual and total twabs can be broken

Lines of code Vulnerability details Impact An edge case in the TwabController.transferBalance can cause total balance for a vault account to decrease although it did not actually decrease. This will cause the sum of individual delegateBalances for a vault to be greater than the registered total f...

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

Allowed calls in LSP6KeyManager doesn't allow calls with empty calldata

Lines of code Vulnerability details Bug Description Whenever a controller attempts to call a LSP0 account's execute function without the relevant SUPER permissions, LSP6ExecuteModule will check that the call is one of the whitelisted allowed calls. If the controller is trying to perform a call wi...

6.7AI score
Exploits0
Code423n4
Code423n4
•added 2023/07/14 12:0 a.m.•22 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/07/14 12:0 a.m.•7 views

Incorrect Interface ID for LSP0

Lines of code Vulnerability details Impact The interface ID stated for LSP0 in LSP0Constants.sol and LIP-0 is 0x3e89ad98, which will affect related logics. Proof of Concept According to LIP-0, this ID is derived from the XOR of the following: selector of batchCalls IDs of the following standards:...

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

_getNextObservationIndex() Random use of timestamp to determine the currentTime can be manipulated bacause of dangerous strict equalities

Lines of code Vulnerability details Impact The use of strict equalities can be easily manipulated by an attacker. Miners may attempt to manipulate the timestamp. Proof of Concept File: TwabLib.sol Code Link: Code: if newestObservation.timestamp == currentTime File: TwabLib.sol Code Link: Code: if...

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

Malicious user can steal other user's deposits from Vault.sol

Lines of code Vulnerability details Impact When the Vault.withdraw function is called, a maximum of typeuint96.max shares are being burnt subsequently: Vault.withdraw- Vault.withdraw- Vault.burn burns uint96shares, see Vault.sol line 1139. A malicious user can exploit this in the following way: 1...

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

_totalWithdrawn VALUE DOES NOT INCLUDE THE _fee AMOUNT THUS INTRODUCING ACCOUNTING ERROR

Lines of code Vulnerability details Impact In the PrizePool.ClaimPrize function is used to claim the rewards of the verified winner. Here when sending the Prize amount to the winner a fee amount is deducted from it as shown below: uint256 amount = tierLiquidity.prizeSize - fee; And this amount is...

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

The _currentExchangeRate of the Vault contract can't increase, and always be lower than or equal to _assetUnit

Lines of code Vulnerability details Impact The currentExchangeRate of the Vault contract can not increase, and always be lower than or equal to assetUnit. Therefore, when the vault is undercollateralized currentExchangeRate assetUnit, it can't be further collateralized. Proof of concept function...

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

Possible centralization issue in PrizePool.closeDraw

Lines of code Vulnerability details The winning random number is chosen by DrawManager, which will lead to centralization risk. Despite haventt really deep dive in codebase of this issue, but if DrawManager ,can somehow calculate which random number can make their controlled address is winner wit...

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

Allowing delegate call with msg.value in executeBatch() is dangerous

Lines of code Vulnerability details Bug Description ERC725XCore's execute function allows four types of operations: 1. CALL for normal calls 2. DELEGATECALL 3. CREATE/CREATE2 for contract deployment 4. STATICCALL The executeBatch function simply calls execute in a loop to perform multiple calls i...

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

Adding balance to accumulator does not depend on the current drawId, while documentation says it does

Lines of code Vulnerability details Impact In documentation protocol states that : To compute the allocated contribution for a draw d we'd compute the integral of curve cd=−t∗lnα∗α^d from lastdraw dold to dnew, and which is equal to −t∗ α^dold + t∗ α^dnew. Which clearly shows that contribution on...

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

LSP8CompatibleERC721's approve() deviates from ERC-721 specification

Lines of code Vulnerability details Bug Description The LSP8CompatibleERC721 contract is a wrapper around LSP8 that is meant to function similarly to ERC-721 tokens. One of its implemented functions is ERC-721's approve: LSP8CompatibleERC721.solL155-L158 function approveaddress operator, uint256...

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

Potential Reversion in Transfer due to LSP1 Interface Support Check

Lines of code Vulnerability details Impact The transfer function in LSP7DigitalAssetCore & LSP8DigitalAssetCore includes a mandatory hook, notifyTokenSender, which verifies if the sender supports INTERFACEIDLSP1. However, if a token owner who initially implemented LSP1 interface ceases to support...

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

Avoid using the same ERC-165 interface ID for URDs and their callers

Lines of code Vulnerability details Bug Description Contracts that implement the LSP-1 standard include INTERFACEIDLSP1 in their supportsInterface function. This means that they have a universalReceiver function that calls a Universal Receiver Delegate URD, such as LSP1UniversalReceiverDelegateUP...

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

_winningRandomNumber vartiable used in calculating if caller is winner can be read via web3.getStorageAt() and user can predict if he wins or not before hand

Lines of code Vulnerability details Impact the variable winningRandomNumber used in isWinner to calc if caller has won the tier can be read, and the calculation can be predicted. Proof of Concept that a variable is marked internal doesnt mean it cannot be read Tools Used vs code Recommended...

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

Attacker can steal vault funds through the deposit function.

Lines of code Vulnerability details Impact In the deposit function, a check is made to see if the amount of assets being deposited by the user is greater than the amount of assets the vault currently holds. The vault then transfers the difference between the assets being deposited and the vault’s...

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

_amountOut is representing assets and shares at the same time in the liquidate function

Lines of code Vulnerability details Impact In the liquidate function from the Vault contract, the input argument amountOut is used as if it was representing a value of asset amount and share amount at the same time which is impossible a there a conversion rate between them, this error will make...

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

In LSP6SetDataModule.sol, Infinite loop in _verifyAllowedERC725YDataKeys()

Lines of code Vulnerability details Impact In verifyAllowedERC725YDataKeys there is a great possibility of an Infinite loop. This is because ++ii is an increment inside if condition. This can lead to excessive gas consumption, causing the Ethereum transaction to fail due to the gas limit Proof of...

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

Yield fee can be stolen

Lines of code Vulnerability details Impact The yieldFeeRecipient can claim some of the fees earned in the vault by calling mintYieldFee. The function has no access control so anyone can call the function and claim the yield fee for themselves. Proof of Concept In the below test an attacker Alice...

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

IF THE UNDERLYING ASSET IS A FEE ON TRANSFER TOKEN IT COULD BREAK THE INTERNAL ACCOUNTING OF THE VAULT

Lines of code Vulnerability details Impact The Vault.deposit function is used by the users to deposit assets to the vault and mint vault shares to the recipient address. The amount of assets are transferred to the Vault as follows: SafeERC20.safeTransferFrom asset, caller, addressthis,...

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

CONFIGURING ALLOWANCE TO ZERO FOR THE _previousLiquidationPair CAN BE FRONT RUN

Lines of code Vulnerability details Impact The Vault.setLiquidationPair is used to change the liquidationPair address to a new address. In the process it sets the allowance of the previousLiquidationPair to zero as shown below: if previousLiquidationPair != address0...

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

LSP8Burnable extension incorrectly inherits LSP8IdentifiableDigitalAssetCore

Lines of code Vulnerability details Bug Description The LSP8Burnable contract inherits from LSP8IdentifiableDigitalAssetCore: LSP8Burnable.solL15 abstract contract LSP8Burnable is LSP8IdentifiableDigitalAssetCore However, LSP8 extensions are supposed to inherit LSP8IdentifiableDigitalAsset instea...

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

Depositors might lose funds due to the lack of zero share check

Lines of code Vulnerability details Impact Depositors might lose funds due to the lack of checking whether the shares to be minted is equal to zero. When this happens, the assets will be deposited into the vault, but the depositors will receive zero shares. This is independent from the initial...

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

balanceOf method can be manipulate to liquidated vault

Lines of code Vulnerability details Impact Deriving price from balanceOf can be manipulated to liquidate vault see example Attacker can provide ERC20 token to the vaultAsset and mint vault shares. The deposited tokens will then be withdrawn with having same shares in the vault. The shares then wi...

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

Vault.mintYieldFee FUNCTION CAN BE CALLED BY ANYONE TO MINT Vault Shares TO ANY RECIPIENT ADDRESS

Lines of code Vulnerability details Impact The Vault.mintYieldFee external function is used to mint Vault shares to the yield fee recipient. The function is an external function and can be called by anyone since there is no access control. The function will revert only under following two...

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

Malicious yield vault owners can manipulate the interaction between the vault and yield vault

Lines of code Vulnerability details Impact Malicious yield vault owners can steal depositor's assets. Proof of Concept yieldVault is the Address of the ERC4626 vault in which assets are deposited to generate yield. After tokens are deposited into the vault, the deposit function of yieldVault is...

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

Claim failure can result to loss of funds

Lines of code Vulnerability details Impact Caller will lose funds through gas fees when claim fails Proof of Concept The claimPrize function allows any caller to claim a prize by providing the necessary parameters: winner address of the winner, tier prize tier, prizeIndex prize index,...

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

Missing Input Validation

Lines of code Vulnerability details Impact The below situations do not have checks on their inputs: When bytes12inputDataKey == LSP6KEYADDRESSPERMISSIONSPERMISSIONSPREFIX: // AddressPermissions:Permissions: if bytes12inputDataKey == LSP6KEYADDRESSPERMISSIONSPERMISSIONSPREFIX // controller already...

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

FIRST DEPOSITOR ATTACK IS PRESENT IN THE Vault.sol CONTRACT

Lines of code Vulnerability details Impact The Vault.deposit function is vulnerable to first depositor attack. It can be described as follows: A malicious early depositor can deposit with 1 wei of asset token as the first depositor of the Vault, and get 1 wei of shares. Then the first depositor c...

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

initialize function can be front run

Lines of code Vulnerability details Impact Initialize function have the potential of front running by a malicious actor. An attacker can front-run the deployer and takeover the contract by setting itself as the owner in the Contract. Taking ownership will result in carrying out malicious acts tha...

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

Deposit transaction is prone to being front-run by bad actors.

Lines of code Vulnerability details Impact It is possible for an attacker to front-run a user's deposit transaction while transferring fewer amount of assets than the user and minting an equivalent amount of shares as the user could have. Proof of Concept The scenario described below is for the...

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

Malicious Yield Vault could deny Pool Together withdrawing assets

Lines of code Vulnerability details Impact Since vaults can be created by anyone as long as they provide an ERC-4626 compliant yield source, an attacker could set up a malicious ERC-4626 contract and set that as the yield source for a newly created Vault. The attacker could then have the maliciou...

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

Anyone can mint to themselves type(uint96).max if _isVaultCollateralized() returns true

Lines of code Vulnerability details Impact There is no check that ensures the caller to mint is a trusted one. Moreover, there is a flaw which lets anyone to mint typeuint96.max number of shares Proof of Concept First, the mint function does not implement any check for the caller to be someone wi...

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

mintYieldFee function does not check for the maxMint amount.

Lines of code Vulnerability details Impact Theoretically, it is possible to mint more than the maxMint amount using the mintYieldFee function in the Vault contract. Proof of Concept The functions in Vault contract like mint, mintWithPermit call the beforeMint function which checks whether shares...

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

Permit does not revert for tokens that do not implement it.

Lines of code Vulnerability details Impact Callers should not rely on permit to revert for arbitrary tokens especially if permit is used as a security check. Tokens which do not revert on permit either do not implement it or have a non-reverting fallback function. Most notable among them is WETH...

7AI score
Exploits0
Total number of security vulnerabilities10190