Lucene search
+L
Code423n4Recent

10190 matches found

Code423n4
Code423n4
•added 2022/09/19 12:0 a.m.•11 views

Should call triggerEndEpoch() or triggerDepeg() first before withdrawing in testOwnerAuthorize()

Lines of code Vulnerability details Detail In Tests section, sponsors said they would like to assess if testOwnerAuthorize are failed due to a logic fault in the contracts or in testing. In this test case, it wants to check if users can approve to other address to help them call withdraw on Vault...

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

Previously nominated delegate can reset the delegation

Lines of code Vulnerability details burn allows for previously recorded delegate to set himself to be contributor's delegate even if another one was already chosen. This can be quite material as owner choice for the whole voting power is being reset this way to favor the old delegate. Proof of...

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

Lack of check if token is a contract

Lines of code Vulnerability details Impact solmate won't check if the token is a contract or not. It's possible for an attacker to the create a vault for a non existing token with a deterministic address. The problem occurs if the token gets deployed later, and another user tries to use this toke...

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

PegOracle reported fraction price is constructed to favor the depeg

Lines of code Vulnerability details Depeg event is defined as linked asset price being below the strike price in the terms of the underlying asset. However, the PegOracle aimed to report the fraction of the pegged asset to the underlying always reports the number below 1, no matter how prices are...

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

If noone deposit in one Vault, assets deposited to the other Vault will be locked.

Lines of code Vulnerability details Impact In each Vault epoch, idFinalTVL and idClaimTVL values is only set when someone call triggerDepeg or triggerEndEpoch from Controller. In case of depeg, we will swap assets of hedge and risk Vault. But if one Vault has noone deposited, idFinalTVL will be...

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

recoverERC20() in StakingRewards shouldn't allow transfer of rewardToken because it belongs to users who stacked their funds and owner shouldn't be able to immediately withdraw those users funds

Lines of code Vulnerability details Impact rewardToken balance in StakingRewards contract is belongs to staking users and owner shouldn't be able to withdraw all balance of rewardToken immediately, because this can cause users to lose their funds if owner perform this action by intention or by...

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

Problems with PegOracle

Lines of code Vulnerability details Impact There are at least a few problems with the PegOracle. I am grouping them into one submission because some of them are not that significant but the last one I believe deserves a higher severity. 1. Function latestRoundData queries getOracle2Price but...

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

[NAZ-H1] First depositor can break minting of shares

Lines of code Vulnerability details Impact The attack vector and impact is the same as TOB-YEARN-003, where users may not receive shares in exchange for their deposits if the total asset amount has been manipulated. Proof of Concept In SemiFungibleVault.solL143, the allocation of shares is...

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

Admin can prevent deposits by manipulating timewindow

Lines of code Vulnerability details Impact The protocol is open to an administrator's maliciousness. Proof of Concept As we can see in this line, the contracts in this project has some sanity checks even for admin only calls. However, the administrator is free to change a hedge/risk pair timewind...

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

Hash result truncation

Lines of code Vulnerability details Description There is function hashFixedGovernanceOpts in Crowdfund contract and function getDistributionHash in TokenDistributor contract. The first one truncates the hash result to 16 bytes, the second to 15 bytes. Impact It is possible to find a collision for...

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

Using transferfrom on ERC721 tokens

Lines of code Vulnerability details Impact In the function createParty of contract Crowdfund.sol, when transferring the acquired NFTs to the new party, the transferFrom function is called instead of safeTransferFrom. If the addressparty is a contract address that doesn't support ERC721 tokens , t...

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

Improper access control in withdraw at Vault.sol

Lines of code Vulnerability details Impact Anyone can withdraw on behalf of approved user Proof of Concept Function withdraw at Vault.sol has incorrect access control. As the owner is passed as a parameter anyone can call withdraw to a approved receiver. This is the same logic used in...

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

PartyGovernance.disableEmergencyExecute() permanently disables emergencyExecute()

Lines of code Vulnerability details Impact PartyGovernance.disableEmergencyExecute will permanently disable PartyGovernance.emergencyExecute as there is no other means to toggle emergencyExecuteDisabled back to false. This means emergencyExecute can never be called once Proof of Concept Tools Use...

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

Locked ether

Lines of code Vulnerability details Impact In contract Party.sol there is a receive declared. This means that the contract can accept eth payments. But there is no function defined , to withdraw those sent ether. So if a user accidently sent ether to the contract, the ether would be locked, as...

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

havent specify the solidity compiler version, 8.15 and older version may lead to a mis encoded struct parameter

Lines of code Vulnerability details Impact the structure: struct ExecuteProposalParams uint256 proposalId; bytes proposalData; bytes progressData; bytes extraData; uint256 flags; IERC721 preciousTokens; uint256 preciousTokenIds; there are some unknown length elementbytes, in 8.15 and older...

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

VaultFactory.sol : changeTreasury, changeTimewindow, changeController - all these function will not update the vault parameters as they are read from memory.

Lines of code Vulnerability details Impact Reading the vault in memory and updating its parameters will not update its values permanently. Proof of Concept Tools Used Manual code review. Recommended Mitigation Steps Read vault in storage instead of memory Update in following lines of codes. --- T...

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

Unbounded proposal calls array length could cause DoS

Lines of code Vulnerability details Impact It's possible to render the governance and execution contract inoperable for a period of time and effectively kill some proposals due to execution failure, which will break the governance routine and function. This could be a mistake or on purpose. Proof...

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

Unsafe ERC721 operations

Lines of code Vulnerability details Impact It is recommended to use safeTransfer and safeTransferFrom when transferring ERC721 and ERC20 token Tools Used Manual audit Recommended Mitigation Steps Use the safeTransfer and safeTransferFrom functions to transfer ERC721 and ERC20 tokens --- The text...

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

PegOracle.sol#L59 : Issue with "price1" calculation.

Lines of code Vulnerability details Impact The calculated price1 could be negative or outdated one. This could affects the codes places wherever the latestRoundData is used to determine the price. one of the place is in Controller.solL261 - function getLatestPriceaddress token Proof of Concept...

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

timewindow can be changed unexpectedly that blocks users from calling deposit function

Lines of code Vulnerability details Impact As shown by the following epochHasNotStarted modifier, which is used by the deposit function below, users can only deposit when block.timestamp modifier epochHa...

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

rewarding is not started after StakingRewards contract deployment and there is no specific time set for contract start time of rewarding, users stacked their funds has no way knowing when is rewarding is going to be started

Lines of code Vulnerability details Impact after StakingRewards the constructor logic set value for rewardRate and rewardsDuration but rewarding is not started for stackers and users has no way to find out when is rewarding going to be started. only reward Distributer can start rewarding process...

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

Griefing attack on the Vaults is possible, withdrawing the winning side stakes

Lines of code Vulnerability details Anyone can withdraw to receiver once the receiver is isApprovedForAllowner, receiver. The funds will be sent to receiver, but it will happen whenever an arbitrary msg.sender wants. The only precondition is the presence of any approvals. This can be easily used ...

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

[H1] Improper access control in withdraw at SemifungibleVault.sol

Lines of code Vulnerability details Impact Anyone can withdraw on behalf of approved user Proof of Concept Function withdraw at SemifungibleVault.sol has incorrect access control. As the owner is passed as a parameter anyone can call withdraw to a approved receiver. function withdraw uint256 id,...

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

fee could round down to 0

Lines of code Vulnerability details Impact fee and memberSupply calculation will be inaccurate. Proof of Concept // contracts/distribution/TokenDistributor.sol 352-353: uint128 fee = supply args.feeBps / 1e4; uint128 memberSupply = supply - fee; When supply is low, fee could round down to 0, whic...

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

You can give address(0) _mint(), confused with _burn()

Lines of code Vulnerability details Impact You can give address0 mint, confused with burn Proof of Concept For example, the Initialize of AuctionCrowdfund does not determine whether initialContributor is 0, so the address0 can be Mint tokenid. //contracts/crowdfund/AuctionCrowdfund.sol function...

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

Attacker can DOS private party by donating ETH then calling buy

Lines of code Vulnerability details Impact Party is DOS'd and may potentially lose access to NFT Proof of Concept Crowdfund.solL280-L298 party = party = partyFactory .createParty addressthis, Party.PartyOptions name: name, symbol: symbol, governance: PartyGovernance.GovernanceOpts hosts:...

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

First depositor can break share minting

Lines of code Vulnerability details Impact Users will be unable to deposit their wished amount of tokens. Proof of Concept Similar to this ToB yearn audit, an attacker can mint a very small amount of shares and transfer a large amount of WETH to the contract, inflating the share price and making ...

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

splitRecipient resulting voting power tend to be overstated

Lines of code Vulnerability details When burn computes the contributor's share via getFinalContribution and contributor = splitRecipient it transfers the whole share to the splitRecipient in advance, even when not all the voting power were allocated. I.e. some contributors might not burn and the...

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

Fee = 0 in case supply is less then 10

Lines of code Vulnerability details In case supply is less then 10 fee will be always = 0, which is almost impossible with ETH but it's not 100% excludible with an ERC20 token in case it's value is very high and precision is low . A check that supply shall more then 10 shall be set. --- The text...

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

Anyone could steal the funds

Lines of code Vulnerability details Impact Anyone can create a contract. and send all the funds if maximumPrice == 0 or at the list he can get the maximumPrice Proof of Concept Create a contract to send the funds to it Invoke buy on CollectionBuyCrowdfund.sol or BuyCrowdfund And it will transfer...

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

Users can lose funds because It's possible to call withdraw() in Vault without call to endEpoch() by Controller.triggerEndEpoch(),

Lines of code Vulnerability details Impact users shouldn't be allowed to withdraw their funds before epoch settling down, and code should check that endEpoch has been called before allowing withdraw for that epoch. but right now withdraw only checks that epoch has been ended and this would happen...

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

[NAZ-M1] 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/09/19 12:0 a.m.•20 views

# Only part of keccak256() is used as hash, making it susceptible to collision attacks

Lines of code Vulnerability details At 2 places in the code only part of the output of keccak256 is used as the hash: At TokenDistributor - DistributionState.distributionHash15 - uses only a 15 bytes as a hash This one is intended to save storage At Crowdfund.governanceOptsHash a 16 bytes is used...

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

Eth can be stucked in contract when NFT was gifted to party (AuctionCrowdfund.sol)

Lines of code Vulnerability details Impact We can call function finalize, which will claim the NFT if we won. After claiming the NFT, function will check if contract is the owner of NFT or not. if lastBid == 0 // The NFT was gifted to us. Everyone who contributed wins. lastBid = totalContribution...

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

Anyone can initialize contracts

Lines of code Vulnerability details Impact Party.initialize , CollectionBuyCrowdfund.initialize , BuyCrowdfund.initialize , AuctionCrowdfund.initialize are functions called with the onlyConstructor modifier . This allows these functions to only be called by a constructor function in any contract...

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

A majority attack can easily bypass Zora auction stage in OpenseaProposal and steal the NFT from the party.

Lines of code Vulnerability details Description The PartyGovernance system has many defenses in place to protect against a majority holder stealing the NFT. One of the main protections is that before listing the NFT on Opensea for a proposal-supplied price, it must first try to be auctioned off o...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/18 12:0 a.m.•12 views

ArbitraryCallsProposal.sol and ListOnOpenseaProposal.sol safeguards can be bypassed by cancelling in-progress proposal allowing the majority to steal NFT

Lines of code Vulnerability details Note: PartyDAO acknowledges that "canceling an InProgress proposal mid-step can leave the governance party in a vulnerable or undesirable state because there is no cleanup logic run during a cancel" in the "Known Issues / Topics" section of the contest readme. ...

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

Governance NFT Voting power can be distributed unfairly after the party purchase the NFT because voting power distribution depends on the contribution NFT burning order

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. Voting power can be distributed unfairly after the party purchase the NFT because voting power distribution depends on the contribution NFT burning order. For example, the NFT is purchased at price 1.5...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/18 12:0 a.m.•10 views

BuyCrowdfund.buy lacks access control

Lines of code Vulnerability details Impact Anyone can call BuyCrowdfund.buy and BuyCrowdfund.buy will call any function at any address and can send eth up to maximumPriceWhen maximumPrice is 0, all ETH in the contract can be sent. Consider maximumPrice = 70 ETH, the current seller's listing price...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/17 12:0 a.m.•6 views

Why emergencyExecute() is required?

Lines of code Vulnerability details Impact Now PartyDAO multisig can steal all funds from all PartyGovernance instances If malicious user will get control over PartyDAO multisig, he will steal of funds from all projects Tools Used vs code Recommended Mitigation Steps Remove this funtion --- The...

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

TokenDistributor: ERC777 tokensToSend hook can be exploited to drain contract

Lines of code Vulnerability details Impact TokenDistributor.createERC20Distribution can be used to create token distributions for ERC777 tokens which are backwards-compatible with ERC20. However, this introduces a reentrancy vulnerability which allows a party to get the tokens of another party. T...

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

Malicious party active member can approve malicious contract to spend and steal party ERC1155 nft and ERC20 tokens via arbitrary proposal execution

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. Let's look into the implementation in ArbitraryCallsProposal.sol // Check that the call is not prohibited. if !isCallAllowedcall, isUnanimous, preciousTokens, preciousTokenIds revert...

7.2AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/15 12:0 a.m.•17 views

ERC721Votes: Token owners can double voting power through self delegation

Lines of code Vulnerability details The owner of one or many ERC721Votes tokens can double their voting power once and only once by delegating to their own address as their first delegation. Scenario This exploit relies on the initial default value of the delegation mapping in ERC721Votes, which ...

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

Users can grief the auction and win it

Lines of code Vulnerability details Impact Users can grief the auction and win it anytime. Proof of Concept A malicious actor who create bids through his/her smart contract can grief the Auction.sol's createBid function. Let's say that the attacker's contract has a fallback function that griefs t...

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

Users retain votes from their delegated tokens

Lines of code Vulnerability details Impact When a user has undelegated tokens and delegates them to another user, the owner retains all votes for their tokens, while the delegatee also gains those votes. By chaining this attack together, this could allow a user to generate unlimited votes, taking...

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

founderPct variable cast

Lines of code Vulnerability details Description There is a function addFounders in Token contract. It accepts array of FounderParams as an input. For each of founders it uses founderPct as an variable to store percent ownership for such founder. It is unsafe to cast it to from uint256 to uint8 in...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/15 12:0 a.m.•5 views

Founders may not receive their vesting allocations

Lines of code Vulnerability details Impact In addFounders the vesting allocations are distributed among the first one hundred nouns according to their ownership percentage. These first one hundred represent the token ID:s modulo 100 that should be minted to the nounders, which is how it is...

6.8AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/15 12:0 a.m.•9 views

Potential of token lost permanently when highest bid is made by a Contract

Lines of code Vulnerability details Impact When auction is happening, there is no checks on who can participate to createBid. In order to work well, contract need to confirm that the Bidder is capable of receiving ERC721 or else their token may be permanently lost. After a bidder decided to be th...

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

Auction.sol : Treasury(payable) typecasting is missed before setting the treasury address

Lines of code Vulnerability details Impact The contract address will not be set with relevant properties, like payable and contract type. Proof of Concept Auction.solL79 : settings.treasury = treasury; Whereas, in Governor.sol, it is set properly. refer the line, Governor.solL74 : settings.treasu...

7.1AI score
Exploits0
Code423n4
Code423n4
•added 2022/09/15 12:0 a.m.•8 views

Proposal can be executed unlimited number of times

Lines of code Vulnerability details There is no executed flag for the proposals, so one can be executed an arbitrary number of times. This will have critical impact, for example a proposal to send out 10 ETH can be run 10 times, transferring 100 ETH. Apart from the malicious Owner case, this also...

7.1AI score
Exploits0
Total number of security vulnerabilities10190