Lucene search
K
Code423n4Recent

10190 matches found

Code423n4
Code423n4
added 2023/08/10 12:0 a.m.14 views

GaugeController.sol isn't updated when voting power is delegated, enabling users to arbitrarily increase gauge weight

Lines of code Vulnerability details Impact A malicious user can arbitrarily increase any gauge's weight, resulting in loss of rewards for lenders of other gauges. Proof of Concept Note that the below code snippet from GaugeController.voteforgaugeweights called by users to cast and change votes...

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

receive function allows any user to lose funds

Lines of code Vulnerability details Impact Lending ledger receive function allows for any user to send funds and lose them forever. Proof of Concept Any user that sends funds to the Lending Ledger contract through the receive function, can't withdraw their funds meaning they would be stuck in...

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

User don't have to deposit for a week into the market to get his weekly reward from the LendingLedger

Lines of code Vulnerability details Impact In the LendingLedger contract, a user is rewarded with CANTO tokens depending on how long he has his deposit in the market. Rewards are distributed for each week during which the deposit was inside the market. However, the user can cheat this condition...

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

Missing access control for whitelisted smart contract

Lines of code Vulnerability details Impact Because this contract is a copy from the curve side, the verwa side is missing the check of a whitelisted/blacklisted smart contract. If the "blacklist" check is not added or implemented within the function, then the contract would lack the necessary...

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

Any of the role setter , nominee Vetter should not be a council (cohort) member.

Lines of code Vulnerability details Impact The privileged cohort membercouncil member can influence the member addition, removal, rotating the nominee and excluding the nominee. The function of election can be rigged, arbitrary proposals can be passed. This is easy by the council member who has...

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

LendingLedger.sol sends ETH instead of CANTO

Lines of code Vulnerability details Impact In the documentations for the contest it is clearly stated that LendingLedger contract is expected to send CANTO to the user when they call the claim function but in reality it transfers ETH. This could be problematic if the user is a contract that expec...

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

[M-01] SecurityCouncilNomineeElectionGovernor.includeNominee(): Missing check adhering to constitution when nominee vetter include nominee

Lines of code Vulnerability details Impact SecurityCouncilNomineeElectionGovernor.solL290-L317 function includeNomineeuint256 proposalId, address account external onlyNomineeVetter ProposalState state = stateproposalId; if state != ProposalState.Succeeded revert ProposalNotSucceededStatestate; if...

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

If the length of owners in the safe array is too large, may experience out of gas revert

Lines of code Vulnerability details Proof of Concept Function requireSafesEquivalent in SecurityCouncilMgmtUpgradeLib.sol checks whether the addresses in the two safe arrays are the same and of the same length. If the arrays are too large, like there are many addresses that manages a gnosis safe,...

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

SecurityCouncilMemberSyncAction : perform function can be continually DOSed which will prevent the valid update the members of the gnosis safe

Lines of code Vulnerability details Impact The securityCouncil update will be prevented by continuously calling the perform function. Since the function rely on the nonce value, this function can be continuously called and nonce value is updated. This would prevent the valid security council upda...

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

Signatures can be replayed in castVoteWithReasonAndParamsBySig() to use up more votes than a user intended

Lines of code Vulnerability details Bug Description In the SecurityCouncilNomineeElectionGovernor and SecurityCouncilMemberElectionGovernor contracts, users can provide a signature to allow someone else to vote on their behalf using the castVoteWithReasonAndParamsBySig function, which is in...

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

Malicious user can drastically boost their voting power by increase a dust amount in lock

Lines of code Vulnerability details Impact A user's weight on a gauge weight voting by design decay with time. However, a user can simply bypass the decay by increasing a dust amount in their lock in VotingEscrow.sol. I think this is high severity due to easy and cheap manipulation. Proof of...

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

SecurityCouncilMemberElectionGovernor Owner Can Change votingPeriod During an Active Election

Lines of code Vulnerability details Impact In SecurityCouncilMemberElectionGovernor contract : relay function enables the contract owner from making calls to any contract address. And in SecurityCouncilMemberElectionGovernorCountingUpgradeable contract: setFullWeightDuration can be accessed only ...

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

_scheduleUpdate() should be called during initialize ing the SecurityCouncilManager

Lines of code Vulnerability details Impact Updates will not be scheduled through timelocks and target upgrade executors by the scheduleUpdate call. Initial set of cohort members will not be scheduled. Proof of Concept In SecurityCouncilManager whenever a new member is added, or removed or swapped...

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

Misaligned Epoch Calculation for Reward Claims

Lines of code Vulnerability details Impact When users attempt to claim rewards, the contract calculates the claimEnd and subsequently updates the userClaimedEpoch using claimEnd + WEEK. This might result in misaligned epochs in scenarios where claimUpToTimestamp is less than or more than a week. ...

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

LendingLedger Lack of method to rescue accidentally sent Canto

Lines of code Vulnerability details Impact There is no function to rescue Canto accidentally sent to LendingLedger so if governance fat-finger those Canto could be lost forever. Proof of Concept There is no function to transfer native token out of LendingLedger Tools Used Manual inspection...

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

Proposals will not be submitted in SecurityCouncilMemberElectionGovernor.sol and SecurityCouncilNomineeElectionGovernor.sol

Lines of code Vulnerability details Impact SecurityCouncilNomineeElectionGovernor::execute and SecurityCouncilNomineeElectionGovernor::createElection will always revert, since the form of description at the proposal is not compliant to the format required at GovernorUpgradable of Openzeppelin...

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

Lenders can deposit at anytime during the week and still claim rewards for that week

Lines of code Vulnerability details Impact Anytime a user deposits during an epoch i.e a week he immediately is eligible to earn from the rewards for that lending market that week. This occurs because when the lending pool calls syncledger, LendingLedger adds the deposit to the users deposit for...

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

Fixed locking period of 5 years doesn't allow the delegator to withdraw funds for atleast another 5 years

Lines of code Vulnerability details Details Let's first understand how the process of delegation, withdraw and increaseAmount works 1. Rule 1: To delegate to some user A, A.lock.end needs to be longer than msg.sender.lock.end and A.Lock.end block.timestampLock mustn't be expired...

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

Undelegation logic doesn't work as expected, duo to that an owner of a lock would be enforced to extend their lock time for another 5 years.

Lines of code Vulnerability details Impact Undelegation logic doesn't work as expected, duo to that an owner of a lock would be enforced to reset his lock time for another 5 years through the function increaseAmount in order to successfully undelegate. Proof of Concept There are few differences...

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

_removeMemberFromCohortArray FUNCTION REDUCES THE cohort ARRAY LENGTH BY ONE THUS DoS THE addMember FUNCTIONALITY

Lines of code Vulnerability details Impact The SecurityCouncilManager.removeMemberFromCohortArray function is used to remove a member from a specific cohort. The function will replace the removing member with the last element of the cohort array and will pop the last element of the array as shown...

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

Contrary to sponsor's intent, the gauge's weight will not be updated properly if governance do not change weight before any voting

Lines of code Vulnerability details Impact This is the intended procedure based on Sponsor's answer in discord: Q: when we add new gauge we don't set any weight point or any data for it, did the new gauge will get the weight and power by time when users vote for it ?! A: Yes, the idea is that the...

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

GaugeController allows for quick vote and withdraw voting strategy

Lines of code Vulnerability details Summary The GaugeController voting can be abused to apply all of the user's weight in every gauge's vote. GaugeController's voting changes the weight of the gauge. Each user can split their voting weight power between the gauges function...

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

Invalid startDate check in SecurityCouncilNomineeElectionGovernorTiming contract

Lines of code Vulnerability details Summary The SecurityCouncilNomineeElectionGovernorTiming contract has an invalid startDate check in the SecurityCouncilNomineeElectionGovernorTiminginit function. The check ensures that the startDate is in the future, but it does not check that the startDate is...

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

TEST EDITING

Lines of code L1 Vulnerability details Impact Detailed description of the impact of this finding. 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 Recommended Mitigation Steps Assess...

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

Anyone can become owner of GnosisSafe(securityCouncil) contracts

Lines of code Vulnerability details Impact Member roles in SecurityCouncilManager contract can change owners of GnosisSafesecurityCouncil contracts by schedulinig a perform call to ArbitrumTimelock contract. However the contract that handles updating ownerssecurity council members with perform...

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

test-submitting edit 24

Lines of code L1 Vulnerability details Testing to see if I can edit a finding I don't own Assessed type Access Control --- The text was updated successfully, but these errors were encountered: All reactions...

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

The upgrade executor is granted the canceller role instead of the new emergency security council.

Lines of code Vulnerability details Impact In L1SCMgmtActivationAction.sol, the perform function is not granting role to the new emergency security council. It instead grants it to the upgrade executor. This logic doesn't align with the function inline comment and can prevent the perform function...

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

Insufficient input validation can lead to loss of funds

Lines of code Vulnerability details Impact The VaultBooster.sol contract allows someone to liquidate tokens for a vault and improve the vault's chance of winning. The prizePool.prizeToken is set in the constructor and liquidationPair set in the setBoost function. However, the external deposit...

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

It is possible that function rngComplete() does not iterate through all rewards

Lines of code Vulnerability details Impact In RngRelayAuction.sol we have rngComplete: function rngComplete uint256 randomNumber, uint256 rngCompletedAt, address rewardRecipient, uint32 sequenceId, AuctionResult calldata rngAuctionResult external returns bytes32 if...

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

Incorrect Target Amount Calculation with Different Decimals in OptionPositionManager Contract

Lines of code Vulnerability details Bug Description In the OptionPositionManager contract, at line 524, there is a calculation error in the implementation of the getTargetAmountFromOracle function. This function calculates the target amount amountB based on the prices of assets A and B obtained...

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

Vulnerability: Donation Attacks can Cause Loss of Liquidity and/or Undesired Prices Rebalance / Contract: GeVault / Function: withdraw

Lines of code Vulnerability details Impact Donation attack can cause loss of users liquidity or undesired tick rebalance by price manipulation. Proof of Concept An attacker can cause constant rebalancing, instability, and along with the vulnerability of slot0 in the getTokenAmountsExcludingFees...

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

swapExactTokensForTokens and swapTokensForExactTokens in OptionsPositionManager.sol uses UniswapV2Router01 which doesn't exist on Arbitrum

Lines of code Vulnerability details Impact The functions swapExactTokensForTokens and swapTokensForExactTokens are using UniswapV2Router01 to make swaps in different functions like closeDebt, withdrawOptionAssets or swapTokens, but that would not be possible and those function would revert. Proof...

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

PRBMATH SD59x18.exp() reverts on hugely negative numbers.

Lines of code Vulnerability details Impact ContinuousGDA.sol inherits a version of PRB Math that contains a vulnerability in the SD59x18.exp function, which can be reverted on hugely negative numbers. SD59x18.exp is used for calculations in ContinuousGDA.solpurchasePrice ,...

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

_computeRewardFraction logic looks susceptible to manipulation around the edges.

Lines of code Vulnerability details Impact if auctionElapsedTime is 0, it returns the full reward fraction Proof of Concept The RewardLib.fractionalReward calculates the reward fraction linearly based on the elapsed time. When auctionElapsedTime is 0, fractionalReward will return 1 full rewards...

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

swapExactAmountOut() does not have deadline which allows pending transactions to be maliciously executed

Lines of code Vulnerability details Impact In LiquidationRouter.sol, swapExactAmountOut function has no deadline for the transaction when swapping. File: src/LiquidationRouter.sol function swapExactAmountOut LiquidationPair liquidationPair, address receiver, uint256 amountOut, uint256 amountInMax...

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

function rngComplete is unpprotected

Lines of code Vulnerability details Impact The rngComplete is a function Called by the relayer to complete the Rng relay auction. However it has zero access control. Proof of Concept The function makes calls to the prizepool to close a draw, it also withdraws from a reserve. All these are done wi...

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

Hardcoded slippage of 95% may not be ideal if liquidity is low or during market volatility, may result in revert when depositing or withdrawing

Lines of code Vulnerability details Impact Larger Deposits and/or withdraw may not work with a 95% slippage parameter. If there are many swaps going on, the slippage should be less restrictive to allow for deposits/withdraws. Proof of Concept In TokenisableRange.sol, the slippage is hardcoded at...

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

Unchecked Call Return Value

Lines of code Vulnerability details Impact The functions do not check the return value of low-level calls. This can lock Ether in the contract if the call fails or may compromise the contract if the ownership is being changed. The following calls were detected without return value validations -...

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

Assets from the old step are not properly transferred to a new TR position

Lines of code Vulnerability details Impact The transferAssetsIntoStep function's intent is to serve two purposes: transferring aAssets to a target TR position and moving assets from an old step to a target TR position. However, in practice, assets removed from the old step are not integrated into...

6.8AI 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/08/07 12:0 a.m.12 views

Missing access control in RngRelayAuction::rngComplete()

Lines of code Vulnerability details For a draw auction to complete, a bot must relay a completed RNG result to the Prize Pool. This is done by calling rngComplete and the data must originate from the relayer. However the rngComplete function is missing a check that the msg.sender is the relayer s...

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

Use of slot0 to get sqrtPriceLimitX96 can lead to price manipulation

Lines of code Vulnerability details Impact The contracts functions have used UniswapV3.slot0 to get the value of sqrtPriceX96 which it use to perform the swap, however the sqrtPriceX96 gotten from Uniswap.slot0 is the most recent data point and can be manipulated easily via MEV bots & Flashloans...

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

The treasury address can be updated by the contract owner to point to a malicious address after deployment

Lines of code ttps://github.com/code-423n4/2023-08-goodentry/blob/71c0c0eca8af957202ccdbf5ce2f2a514ffe2e24/contracts/GeVault.solL58 Vulnerability details Impact Any fees or funds sent to the treasury could potentially be stolen or manipulated Proof of Concept The treasury address can be updated b...

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

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

Lines of code Vulnerability details Impact The use of the transfer function for sending ETH to an address will inevitably make the transaction fail when: The claimer smart contract does not implement a payable function. The claimer smart contract does implement a payable fallback which uses more...

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

The absence of proper Access Control in RngRelayAuction::rngComplete() enables anyone to prematurely conclude the Auction Process.

Lines of code Vulnerability details Explanation For the DrawAuction to be successfully completed, a specific sequence of actions must be followed, and each step holds significance. This demands a carefully designed execution flow that considers both the procedure's requirements and the authorized...

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

the _rngCompletedAt timestamp passed to rngComplete() can be manipulated by the caller to increase their reward

Lines of code Vulnerability details Impact This will result in a larger reward fraction, allowing the caller to unfairly claim more of the rewards. Proof of Concept The rngCompletedAt timestamp is controlled by the caller. They can make auctionElapsedSeconds smaller by providing a higher...

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

RangeManager.initRange does not refund leftover underlying assets to the contract owner

Lines of code Vulnerability details Impact The initRange function in the RangeManager contract has a vulnerability where leftover underlying assets from the tokenizable range are not properly refunded to the contract owner. This can lead to a situation where the owner's funds are stuck in the...

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

Risk of silent overflow in rngComplete rewards cast

Lines of code Vulnerability details Impact The rngComplete function uses the rewards function from the RewardLib library to calculates the rewards that should be given, the rewards returned by the rewards function are of type uint256 but before proceeding to the reward transfer the call to...

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

GeVault#poolMatchesOracle is extemely easy to manipulate due to how it calculates underlying token balances

Lines of code Vulnerability details Impact GeVaultpoolMatchesOracle uses the UniV3Pool.slot0 to determine the number of tokens it has in it's position. slot0 is the most recent data point and is therefore extremely easy to manipulate. Given that the protocol specializes in leverage, the effects o...

6.8AI 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
Total number of security vulnerabilities10190