Lucene search
K
Code423n4Most viewed

10190 matches found

Code423n4
Code423n4
added 2024/01/26 12:0 a.m.16 views

nextEpoch is incorrect

Lines of code Vulnerability details Impact Rewards and voting weights are aligned on a weekly basis. However, nextEpoch is calculated incorrectly, which may break the invariant "The total rewards that are sent for one block should never be higher than the rewards that were configured for this...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2024/01/08 12:0 a.m.16 views

changeRegistries() from the Tokenomics contract changes different registries at the same time.

Lines of code Vulnerability details Impact In a case where either one of the agent, component or service registry are deprecated, attempting to replace the compromised registry necessitates an overall replacement of all the other registries. This not only utilizes excess gas but can also bring...

7.2AI score
Exploits0
Code423n4
Code423n4
added 2024/01/08 12:0 a.m.16 views

Attacker can call initializeTokenomics in the tokenomics implementation contract and self destruct afterwards

Lines of code Vulnerability details Impact Malicious actor can front run any attempts to initialize the implementation contract of tokenomics and self destruct the contract. This makes us to re-deploy proxy as the upgradable logic is within the proxy as well. Proof of Concept 1. Implementation is...

7.2AI score
Exploits0
Code423n4
Code423n4
added 2024/01/08 12:0 a.m.16 views

CM can exploit a pause in GuardCM to gain permanent unrestricted access

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. Under specific circumstances, the protocol allows the guard to be paused, which temporarily pauses the guard and...

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

The entire AuctionHouse contract can be disabled by a wrong creator bps sum.

Lines of code Vulnerability details Vulnerability details Description There is a potential for a DoS in the AuctionHouse contract related to the buyToken call from the ERC20TokenEmitter. This is due to the buyToken requiring the bpsSum to be equal to 10000, but there is no restriction when creati...

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

Using block.timestamp as the deadline/expiry invites MEV

Lines of code 307 Vulnerability details Passing block.timestamp as the expiry/deadline of an operation does not mean "require immediate execution" - it means "whatever block this transaction appears in, I'm comfortable with that block's timestamp". Providing this value means that a malicious mine...

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

Reentrancy in mint function leads to various problems

Lines of code Mint function in minter contract: Mint function in core contract: Vulnerability details Bug Description When minting NFTs, users will using the mint function. This function will mint a NFT using the safeMint function. The problem is that this mint will be done before crucial variabl...

7.1AI score
Exploits0
Code423n4
Code423n4
added 2023/11/10 12:0 a.m.16 views

Send Ether will call instead of transfer

Lines of code Vulnerability details Impact transfer automatically forwards exactly 2300 gas to the receiving contract. This limitation can restrict smart contract's ability to interact with other contracts that require more gas for their operations like receiving eth, leading to failed transactio...

7.6AI score
Exploits0
Code423n4
Code423n4
added 2023/10/26 12:0 a.m.16 views

Incompatibility with Rebase tokens

Lines of code Vulnerability details Impact Borrowers can choose whatever token they want to be the underlying token for a market. The problem comes when those tokens are Rebasing tokens such as Ampleforth. The balances of those tokens are changed rebased by a certain algorithm depending on the...

7.1AI score
Exploits0
Code423n4
Code423n4
added 2023/10/20 12:0 a.m.16 views

ExecutorPlugin missing payable when execute the transaction

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. Proof of Concept executeTransaction in ExecutorPlugin is meant to execute transaction but in executeTxnAsModule function executeTxnAsModuleaddress account, Types.Executable memory executable internal...

7.6AI score
Exploits0
Code423n4
Code423n4
added 2023/10/11 12:0 a.m.16 views

Possible hash collision in retrieveProxyContractAddress()

Lines of code Vulnerability details Impact implemention of keccak256abi.encodePackeda, b with both dynamic types or same type with dynamic nature leads to collision in hash. Proof of Concept From the sol docs:link. i.e If you use keccak256abi.encodePackeda, b and both a and b are dynamic types, i...

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

User can selectively turn on the fallback flag to take all ETH on the agent contract as layerzero fee refund

Lines of code Vulnerability details Impact performFallbackCall can revert sliently when refundee is not capable of taking ETH refund from layerzero side Proof of Concept In RootBridgeAgent.sol when the has fall back toggle flag is on, the smart contract aim to perform a fallback call to notify th...

7.2AI score
Exploits0
Code423n4
Code423n4
added 2023/09/27 12:0 a.m.16 views

AfEth price calculation doesn't factor locked tokens held in contract balance

Lines of code Vulnerability details Summary When withdrawals are enqueued in AfEth, the implementation will remove the tokens from the caller and lock these in the contract until the withdrawal is made effective. These tokens still count in the supply, and must not be considered during price...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2023/09/11 12:0 a.m.16 views

"rights" stored in memory is overwriting the memory block storing "from" and 32 bytes memory is given to store 20 byes long "contract_"

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. Expected code should keccak over packed encoding of rights, from, to, contract, tokenId but as 'rights' values are overwriting 'from' values and 32 bytes memory block has been allocated to 'contract'...

7.3AI score
Exploits0
Code423n4
Code423n4
added 2023/09/06 12:0 a.m.16 views

Regular bonding incorrectly purchases a reduced amount of Put options due to discount

Lines of code Vulnerability details During rDPX bonding, rdpxV2Core will purchase put options for the rDPX that are used for minting DPXETH. This is for hedging against rDPX price drop to protect the DPXETH peg. The amount of put options to purchase is equivalent to the amount of rDPX that are us...

7.1AI score
Exploits0
Code423n4
Code423n4
added 2023/08/28 12:0 a.m.16 views

_reserveTokenSpecified does not check if price is in allowed range

Lines of code Vulnerability details Impact Price could go out of range Proof of Concept EvolvingProteus defines a price range using 2 constants, MAXM and MINM: int128 constant MAXM = 0x5f5e1000000000000000000; int128 constant MINM = 0x00000000000002af31dc461; These constants are used in...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/08/26 12:0 a.m.16 views

Number of prize tiers may never scale due to aggressive new algorithm

Lines of code Vulnerability details Comments This issue is very similar to M-14 but covers another edge case where the threshold check is not performed when there are currently 14 prize tiers and at least 1 canary tier is claimed. This is due to an early return of MAXIMUMNUMBEROFTIERS. Mitigation...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/08/10 12:0 a.m.16 views

check for the reentrancy attack is missed in the claim function

Lines of code Vulnerability details Impact the function claim in the LendingLedger.sol will send native token $CANTO to the msg.sender by .call which it can be EOA or Contracts, because there is no any RA checks the caller can make double call in the same time to get himself more tokens reward th...

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

Incorrect Import Path Directories

Lines of code Vulnerability details Impact Wrong Import Path Directories of LiquidationPair.sol contract would affect the functionality of the contract as this contract relies of the implementation of this imports Proof of Concept 4. import ILiquidationSource from...

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

Wrong Accruing executed in VaultBooster.sol

Lines of code Vulnerability details Impact Accounting error in accruing at VaultBooster.sol will cause unexpected problems in VaultBooster.sol contract. Proof of Concept The accrue function of VaultBooster.sol at : does not check whether the return variable of computeAvailabletokenOut i.e.,...

6.6AI score
Exploits0
Code423n4
Code423n4
added 2023/08/02 12:0 a.m.16 views

Potential Early Exploit in Morho-Aave ERC4626 Implementation

Lines of code Vulnerability details Impact The issue discovered can be exploited when a vault is initially empty. A malicious actor could frontrun a legitimate user's deposit, contributing a negligible amount to the vault. This allows the actor to own shares while the total asset in the vault is...

6.7AI 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.16 views

Potential Reversion in Transfer due to LSP1 Interface Support Check

Lines of code Vulnerability details SORRY I HAVFE PREVIOUSLY SUBMITTED THIS ISSUE WITHOUT THE FIX... FIRST TIME WARDEN FORGIVE ME Impact The transfer function in LSP7DigitalAssetCore & LSP8DigitalAssetCore includes a mandatory hook, notifyTokenSender, which verifies if the sender supports...

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

Anyone can call Well.sol shift() function and withdraw Contract's extra ERC20 tokens whichever this contract is holding . From Well's contract balance, extra tokens for shifting, calculated amountOut for passed tokenOut token can be withdrawn by attacker.

Lines of code Vulnerability details Impact Whichever type of ERC20 token Well contract is holding it can loose all extra tokens of all types in an amount whatever is the difference reservesj -calcReservewellFunction, reserves, j, totalSupply comes for tokenOut token passed by attacker. Attacker c...

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

Slippage controls for calling bHermes contract's ERC4626DepositOnly.deposit and ERC4626DepositOnly.mint functions are missing

Lines of code Vulnerability details Impact mentions that "if implementors intend to support EOA account access directly, they should consider adding an additional function call for deposit/mint/withdraw/redeem with the means to accommodate slippage loss or unexpected deposit/withdrawal limits,...

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

Reentry restrictions are not properly released

Lines of code Vulnerability details Impact After LSP6KeyManagerCore.execute or LSP6KeyManagerCore.executeRelayCall is executed, non-isSetData methods that call these two methods without re-entry permission cannot be called normally Proof of Concept Tools Used manual review Recommended Mitigation...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/06/26 12:0 a.m.16 views

The broker should not be fully disabled by GnosisTrade.reportViolation

Lines of code Vulnerability details Impact GnosisTrade and DutchTrade are two separate auction systems where the failing of either system should not affect the other one. The current design will have Broker.sol disabled when reportViolation is invoked by GnosisTrade.settle if the auction's cleari...

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

The increaseTotalValidatorActiveCount in PermissionedPool incorrectly adds requiredValidators instead of validatorToDeposit

Lines of code Vulnerability details Impact When the Stader Stake Pools Manager calls stakeUserETHToBeacon chain, it does so calculating the requiredValidators that can be added to the pool. The function internally also uses the allocateValidatorsAndUpdaterOperatorId to compute each operator's...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/06/09 12:0 a.m.16 views

stake before unfreeze can take away most of rsr rewards in the freeze period

Lines of code Vulnerability details If the system is frozen, the only allowed operation is stRST.stake. And the payoutRewards is not called during freeze period: if !main.frozen payoutRewards; function payoutRewards external requireNotFrozen; payoutRewards; So the payoutLastPaid stays before the...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2023/06/02 12:0 a.m.16 views

If no funds are deposited at the beginning, L1-L2 cannot be transferred out

Lines of code Vulnerability details Impact If user transfer tokenA-tokenB from L1 to L2, and the L2 depositstokenBtokenA is zero at the beginning.It will cause user lossing his funds. Proof of Concept First, user transfer TokenA, and it will send Message to L2 and L2 will call finalizeBridgeERC20...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/05/30 12:0 a.m.16 views

Rage quitter loses his claimable share of distributed tokens

Lines of code Vulnerability details Impact Rage quitter loses his claimable share of distributed tokens. Proof of Concept PartyGovernanceNFT.rageQuit burns a governance NFT and transfers its share of the balance of ETH and tokens: // Burn caller's party card. This will revert if caller is not the...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/05/30 12:0 a.m.16 views

Governance NFT can be burned to DoS accept()

Lines of code Vulnerability details Impact accept can be DoS'd by burning governance NFTs. Authorities can effectively veto proposals. Proof of Concept The new lastBurnTimestamp reverts PartyGovernance.accept if lastBurnTimestamp == block.timestamp. lastBurnTimestamp is set in...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2023/05/26 12:0 a.m.16 views

AmbireAccount.isValidSignature() does not cover recovery signatures

Lines of code Vulnerability details Impact A recovery key can sign for a recovery but cannot get isValidSignature to return that it is valid. Proof of Concept AmbireAccount.isValidSignature is implemented as follows function isValidSignaturebytes32 hash, bytes calldata signature external view...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2023/05/11 12:0 a.m.16 views

mint() function: an attacker can mint multiple position NFTs for one or more legit Ajna users who have LP in Ajna pools. This should not be possible.

Lines of code Vulnerability details Impact The current implementation of the mint function does not ensure that only the owner of a liquidity pool LP deposit can mint position NFTs. As a result, an attacker can mint multiple position NFTs on behalf of legitimate Ajna users who have LP in Ajna...

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

Contracts are vulnerable to fee-on-transfer-token-related accounting issues

Lines of code Vulnerability details Vulnerability details Impact Without measuring the balance before and after the transfer, there's no way to ensure that enough tokens were transferred, in the cases where the token has a fee-on-transfer mechanic. If there are latent funds in the contract,...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/04/13 12:0 a.m.16 views

Constant product formula is not maintained in deposit() and withdraw() functions.

Lines of code Vulnerability details Impact As constant product formula is not followed, during deposit/withdraw, actualReserves - both actual NFT and BaseToken are updated but virtualReserves are not updated. This could lead to incorrect price deviation for the trader, most reverting their...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/03/30 12:0 a.m.16 views

Burning rETH at the unstake might revert

Lines of code Vulnerability details Impact Unstaking is blocked. Proof of Concept When unstaking the withdraw of each derivative is called. Reth.withdraw withdraws by calling RocketTokenRETHInterfacerethAddress.burnamount. But RocketTokenRETH.burn reverts if the ETH balance is insufficient for th...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/03/20 12:0 a.m.16 views

Bio Protocol - tokenURI JSON injection

Lines of code Vulnerability details Impact The Bio Protocol allows users to mint Bio NFTs that represent user's bio. Once NFT is minted anyone can trigger tokenURI to retrieve JSON data with the bio and generated svg image. Example JSON content decoded from Base64: "name": "Bio 1", "description":...

6.6AI score
Exploits0
Code423n4
Code423n4
added 2023/03/19 12:0 a.m.16 views

[Medium - 2] A force deployed contract may be stuck in the constructor forever

Lines of code Vulnerability details Impact The forceDeployOnAddress function in the ContractDeployer contract may be used to redeploy contracts at a specified address. Very useful in the case of precompiles or system contracts upgrades for instance. In the deployment parameters, multiple values c...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/03/19 12:0 a.m.16 views

Incorrect calculation of gasToPay due to dividing before multiplying, rounding error.

Lines of code Vulnerability details Impact In Solidity, it is an error to divide before multiplying because of lots of rounding errors that can come from that. In this case: uint256 pubdataLen; unchecked pubdataLen = message.length + 31 / 32 32 + 64; uint256 gasToPay = pubdataLen...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2023/03/19 12:0 a.m.16 views

Wrong block number calculation

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. The calculation for the block info is currentBlockNumber + 1 BLOCKINFOBLOCKNUMBERPART + newTimestamp. getBlockNumberAndTimestamp, getBlockTimestamp, getBlockNumber all incorrectly calculate the current...

7AI score
Exploits0
Code423n4
Code423n4
added 2023/03/19 12:0 a.m.16 views

Unsafe cast

Lines of code Vulnerability details Impact In AccountCodeStorage.sol we have function getCodeHash and getCodeSize Due to an insecure cast, it is possible to get an integer overflow. Solidity version 0.8.0 provide SafeMath, but casting operations are not safe and can overflow. Proof of Concept As...

7AI score
Exploits0
Code423n4
Code423n4
added 2023/03/15 12:0 a.m.16 views

Malicious users can claim BYTES rewards after withdrawing all of their LP stake

Lines of code Vulnerability details Impact Users are able to continue claiming BYTES rewards indefinitely on their initials points after withdrawing all of their LP stake. Proof of Concept A user can withdraw all of their LP staked tokens in multiple steps with an amount 1e16. If the amount is...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/03/09 12:0 a.m.16 views

TicketUtils: Number draws are not uniformly distributed

Lines of code Vulnerability details The number selection algorithm in TicketUtils.reconstructTicket "draws" winning numbers using modulo arithmetic and a random seed. However, selected numbers are not uniformly distributed. Due to modulo bias and successive draw logic, higher numbers will be draw...

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

pullCollateralFromBorrowerOperationsOrDefaultPool can fail on if _amount will set to zero

Lines of code Vulnerability details Impact Amount can be zero,as there is not no check in place, while collect modules do attempt to send it in such a case anyway. Some ERC20 tokens do not allow zero value transfers, reverting such attempts. As a result, a combination of a token set as a collect...

7AI score
Exploits0
Code423n4
Code423n4
added 2023/03/05 12:0 a.m.16 views

implementation of the isValidSignature() function in the DAO.sol is invalid

Lines of code Vulnerability details Impact Failure to validate the returned response from the isValidSignature function can cause that invalid signatures to be assumed to be valid. Proof of Concept Currently, externally owned accounts EOAs can sign messages with their associated private keys, but...

7.1AI score
Exploits0
Code423n4
Code423n4
added 2023/02/15 12:0 a.m.16 views

There is no way to recover from error state

Lines of code Vulnerability details Impact There is no way to recover from error state Proof of Concept To address report M-3, in PR, The finishFailedMinipoolByMultisig method removed, while this does not block user from withdraw the fund in the error state in the current implementation. I think...

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

Incorrect computation in MultiRewardStaking changeRewardSpeed() leads to loss of rewards

Lines of code Vulnerability details Impact The changeRewardSpeed function computes rewardsEndTimestamp incorrectly for the case block.timestamp block.timestamp ? prevEndTime : block.timestamp.safeCastTo32, rewardsPerSecond, remainder If the prevEndTime block.timestamp then it can be reduced to...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/02/03 12:0 a.m.16 views

DoS with block gas limit in squeezeDrips

Lines of code Vulnerability details Squeezing drips requires verifying the entire history of that drip. This means iterating over an unbounded loop of the size of the history for uint256 i = 0; i dripsHistory.length; i++ DripsHistory memory drips = dripsHistoryi; bytes32 dripsHash =...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2023/02/03 12:0 a.m.16 views

Multiple people can register the same cidNFTID

Lines of code Vulnerability details Impact Multiple people can register the same cidNFT in a way that the same "canonical on-chain identity" can be shared accross multiple real-life identities. Proof of Concept cidNFTs can be transfered as any ERC721 token. After each transfer the new owner can...

6.7AI score
Exploits0
Total number of security vulnerabilities5000