Lucene search
K
Code423n4Recent

10190 matches found

Code423n4
Code423n4
added 2022/08/07 12:0 a.m.6 views

MIMOVaultActions Tokens with fee on transfer are not supported

Lines of code Vulnerability details MIMOVaultActions Tokens with fee on transfer are not supported Vulnerability details There are ERC20 tokens that charge fee for every transfer / transferFrom. MIMOVaultActions.soldepositAndBorrow assumes that the received amount is the same as the transfer...

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

Caller is able to set management params in a MIMOManagedRebalance proxy he doesn't own

Lines of code Vulnerability details Impact A caller is able to set management params with any MIMOManagedRebalance proxy as long as the caller is a vault owner, the caller has deployed a proxy, and the caller is set as a manager of said vault. Proof of Concept Using the MIMOProxy's multi-call, ca...

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

The lazy update of _currentProxies results in non-owners being able to execute functions that require owner privileges

Lines of code Vulnerability details Impact In the MIMOProxyRegistry contract, the getCurrentProxy function returns the address of the mimoProxy contract corresponding to the owner's address in currentProxies. function getCurrentProxyaddress owner external view override returns IMIMOProxy proxy...

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

ProxyFactory can circumvent ProxyRegistry

Lines of code Vulnerability details Impact The deployFor function in MIMOProxyFactory.sol can be called directly instead of being called within MIMOProxyRegistry.sol. This results in the ability to create many MIMOProxies that are not registered within the registry. The proxies deployed directly...

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

MIMOProxy: The execute function needs to verify that _initialized > 0

Lines of code Vulnerability details Impact In order to avoid changing the owner during the delegatecall, the execute function of the MIMOProxy contract will check the owner before and after the delegatecall. But if initialized is changed to 0 during the delegatecall process, the MIMOProxy contrac...

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

Delegate call can manipulate minGasReserve and the _permissions mapping.

Lines of code Vulnerability details Impact When the proxy delegatecalls the target contract the target contracts code runs in the proxy’s storage. This means the target code has access to all of proxy’s storage including internal mappings. As a result, the target contracts code can manipulate...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.5 views

minGasReserve of MIMOProxy can be overwritten

Lines of code Vulnerability details Impact While there is a check that owner is not changed in a delegatecall, such a check is missing for minGasReserve, which means that the variable can be changed either maliciously or accidentally because of a storage slot collision. The consequences of this a...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.8 views

Builder can reduce his debt more than expected by replaying signature

Lines of code Vulnerability details Impact A builder can, after it convened with the lender and an external agent to reduce his debt through escrow, reuse the signature and pass it again to escrow many times. This allows him to reduce his debt more than expected, leaving the lender at a loss. Pro...

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

Owner of project NFT has no purpose

Lines of code Vulnerability details Owner of project NFT has no purpose Impact Creating a new project mints a NFT to the sender builder. The builder of a project has special permissions and is required to perform various tasks. However, if the minted NFT is transferred to a different address, the...

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

Add members to the not yet created community

Lines of code Vulnerability details Impact There is a addMember function in the Community. The function accepts data that should be signed by the community.owner and newMemberAddr. // Compute hash from bytes bytes32 hash = keccak256data; // Decode params from data uint256 communityID, address...

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

New subcontractor can be set for a SCConfirmed task without current subcontractor consent

Lines of code Vulnerability details Malicious builder/contractor can change the subcontractor for any task even if all the terms was agreed upon and work was started/finished, but the task wasn't set to completed yet, i.e. it's SCConfirmed, getAlertstaskID2 == true. This condition is not checked ...

6.6AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.8 views

Project.changeOrder() might reinitialize already completed task.

Lines of code Vulnerability details Impact changeOrder can be used to change subcontractor. But if a project builder approves the signature by fault or the contractor is delegated, a malicious contractor and subcontractor might reinitialize an already completed task and complete again to receive...

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

Unclaimed interest is 0 within 24 hours since the last time that loan is lent or interest is earned for project

Lines of code Vulnerability details Impact When returnToLender is called, the unclaimed interest is calculated as below. uint256 noOfDays = block.timestamp - communityProject.lastTimestamp / 86400; // 246060 /// Interest formula = principal APR days / 365 1000 // prettier-ignore uint256...

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

Anyone can create disputes if contractor is not set

Lines of code Vulnerability details Impact Disputes enable an actor to arbitrate & potentially enforce requested state changes. However, the current implementation does not properly implement authorization, thus anyone is able to create disputes and spam the system with invalid disputes. Proof of...

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

Calculating project cost is vulnerable to reaching block gas-limit

Lines of code Vulnerability details Impact The function Project.projectCost calculates the project costs by calculating the sum of all project task costs. However, due to the unbound for loop, iterating over a potentially large amount of project tasks, this function can potentially DoS due to...

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

Ownership transfer not correctly handled for flash loans

Lines of code Vulnerability details Impact In response to a flashloan, proxyRegistry.getCurrentProxyowner is used to retrieve the correct user proxy and check that this proxy has initiated the flash loan. This can be problematic after ownership transfers of the proxy, where...

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

Malicious callers can replay disputes

Lines of code Vulnerability details Unlike some of the other signature based operations in the Rigor system, dispute signatures do not include a nonce and are vulnerable to replay attacks. This is similar to my finding in 339, but lower severity, since it is more of a spamming/griefing vector...

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

Malicious callers can replay change orders

Lines of code Vulnerability details Unlike some of the other signature based operations in the Rigor system, change order signatures do not include a nonce and are vulnerable to replay attacks. A number of exploits are possible using replayed change orders, including subcontractors extracting...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.32 views

Upgradeable contract is missing a __gap[50] storage variable to allow for new storage variables in later versions

Lines of code Vulnerability details Upgradeable contract is missing a gap50 storage variable to allow for new storage variables in later versions Impact For upgradeable contracts, there must be storage gap to "allow developers to freely add new state variables in the future without compromising t...

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

Community can lose interest because interest was calculated by days instead of seconds

Lines of code Vulnerability details Impact Community's owner lose amount of interest from project up to half of total interest Proof of concept When builder repay any loan amount by function repayLender or community call function lendToProject, function claimInterest in contract Community will be...

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

Lack of storage gap for upgradable contracts

Lines of code Vulnerability details Impact Safe usage of upgradable contract should include a storage gap to allow the addition of new state. OpenZeppelin docs Proof of Concept The following contracts on the project are using upgradable contracts from OpenZeppelin. File: contracts/Community.sol...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.14 views

No storage gap for Upgradable contract might lead to storage slot collision

Lines of code Vulnerability details Impact For Upgradable 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.9AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.9 views

Divide before multiply may create unexpected values on interests

Lines of code Vulnerability details Divide before multiply may create unexpected values on interests Impact Solidity integer division might truncate. As a result, performing divide before multiply can sometimes create loss of precision. Details If for example we have an operation: 2/33 The expect...

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

It should not submit a project with no total budget. Requires at least one task with cost > 0

Lines of code Vulnerability details Impact When publishing a project, there is still possibility the project doesn't have any task or 0 budget. Proof of Concept According to contest guideline, there is an information says "Note that you cannot submit a project with no total budget. Therefore it...

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

Community's escrow allows for signature replay

Lines of code Vulnerability details checkSignatureValidity verification by signature do not utilize nonces and can be tricked by using owner / builder signatures from earlier calls. Namely, while checkSignatureValidity's approvedHashes based way can used only once as it deletes the corresponding...

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

the lenderFee must be multiplied with 10

Lines of code Vulnerability details There is no check to ensure if the lenderFee is multiplied by 10 Finding: File: /blob/main/contracts/HomeFi.sol 115: lenderFee = lenderFee; // the percentage must be multiplied with 10 194: lenderFee = newLenderFee; --- The text was updated successfully, but...

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

No check if 'ecrecover()' fails

Lines of code Vulnerability details Impact addMember function makes a call to 'ecrecover' to grab the 'community owner' & 'new member'. The problem is that if 'ecrecover' fails it will return a 0 which is currently not guarded against. This was a problem in the famous Polygon Matic token bug. The...

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

updateProjectHash does not check project address

Lines of code Vulnerability details In Project.sol, function updateProjectHash L162, data which is signed by builder and/or contractor does not contain a reference to the project address. In all other external functions of Project.sol, data contains the address of the project, used in this check:...

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

Automation / management can be set for not yet existing vault

Lines of code Vulnerability details Impact & Proof Of Concept vaultOwner returns zero for a non-existing vaultId. Similarly, proxyRegistry.getCurrentProxymsg.sender returns zero when msg.sender has not deployed a proxy yet. Those two facts can be combined to set automation for a vault ID that doe...

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

Unexpected use of array indexes in HomeFi.sol

Lines of code Vulnerability details Unexpected use of array indexes in HomeFi.sol Impact Elements in array are expected to start from 0 when regular indexes are used, however, cause of the order of operations in the HomeFi.createProject function, the element 0 will never be used as index in...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.5 views

Mathematical impossibility in Modifier

Lines of code Vulnerability details Impact In the resolvable modifier, there is a mathematical check for disputeID disputeCount, and unless this is true, the modifier will revert. The default value of the variable disputeCount, which must be mathematically large, is 0 and its value is never...

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

Old owner can still set automation / management for vaults after ownership transfer

Lines of code Vulnerability details Impact When the ownership of a user proxy is transferred, proxyRegistry.getCurrentProxy does not reflect this and still returns the proxy for the previous owner. This can be exploited in the access check of setAutomation. Because setManagement has the same chec...

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

Vault rebalancing can be exploited if two vaults rebalance into the same vault

Lines of code Vulnerability details Impact User funds stolen Proof of Concept Swap data is completely arbitrary and can be used to swap though malicious ERC20 tokens allowing control transfer. This control transfer would allow the attacker to call rebalance on a second vault and exploit both as...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.9 views

Missing upper limit definition in replaceLenderFee() of HomeFi.sol

Lines of code Vulnerability details Missing upper limit definition in replaceLenderFee of HomeFi.sol Impact The admin of the HomeFi contract can set lenderFee to greater than 100%, forcing calls to lendToProject to all projects created in the future to revert. Proof of Concept Using the function...

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

Project party can unilaterally change price payed at task completion

Lines of code Vulnerability details Impact If there has been more than a change in a task's cost through mulitple calls to changeOrder, signatures previously passed can be replayed by one party to change the price payed for the task without consent of the other parties by frontrunning call to...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.15 views

Multicall does not check if the owner has changed after calls has been made(msg.sender misuse)

Lines of code Vulnerability details Impact The multicall doesn't check if the owner has changed after call or calls has been made. The transferOwnerShip contracts/proxy/MIMOProxy.sol/ requires that the owner is the msg.sender, before ownership can be changes, which is exactly what multicall can d...

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

PTP-03: Unsafe logic in repayLender() function

Lines of code Vulnerability details PTP-03: Unsafe logic in repayLender function Impact reduceDebt internal function is called before the actual transfer of tokens, meaning that it doesn't matter if the transaction fails or succeeds for any reason, debt will be reduced, causing a loss for the...

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

New owner of user proxy can prevent old owner from using the system

Lines of code Vulnerability details Impact In deployFor, owner is called if there is already an entry for the provided address. This can be exploited by a sophisticated attacker to make the system completely unusable for a user. Proof Of Concept Alice transfers her proxy to Bob through...

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

Contract name will point to old implementation

Lines of code Vulnerability details Impact The owner can update implementation of contract Name. However it was observed that the updation is not done correctly and contract fails to update contractAddresscontractName variable which mean contract name will still point to old implementation Proof ...

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

Lack of check for fee tokens

Lines of code Vulnerability details Impact The lendToProject function will receive the cost as an argument. However, some tokens will charge a fee, which might cause the balance of the token in the contract mismatch the cost. File: contracts/Project.sol /// @inheritdoc IProject function...

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

the customers can’t just trust the admin

Lines of code Vulnerability details The users can’t just trust the admin eve with multi-sig. So the admin can on anytime change the lenderFee to 100% just by calling replaceLenderFee Recommended Mitigation Steps Add a maximum value for lenderFee to ensure that the admin can’t update the lenderFee...

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

Use call() instead of transfer() when transferring ETH in DebtToken

Lines of code Vulnerability details Impact When transferring ETH, use call instead of transfer. The transfer function only allows the recipient to use 2300 gas. If the recipient uses more than that, transfers will fail. In the future gas costs might change increasing the likelihood of that...

7AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.9 views

Project.raiseDispute() doesn't use approvedHashes - meaning users who use contracts can't raise disputes

Lines of code Vulnerability details Impact In case users are using a contract like a multisig wallet to interact with a project, they can't raise a dispute. The sponsors have added the approveHash function to support users who wish to use contracts as builder/GC/SC. However, the...

6.9AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.8 views

Possible DOS in lendToProject() and toggleLendingNeeded() function because unbounded loop can run out of gas

Lines of code Vulnerability details Impact In Project contract, the lendToProject function might not be available to be called if there are a lot of Task in tasks list of project. It means that the project cannot be funded by either builder or community owner. This can happen because lendToProjec...

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

Signature Replay Attack - Signatures are reusable

Lines of code Vulnerability details checkSignatureValidity performs a check to verify that the signer is the correct address. In the case of Community this is done on the following data: uint256 communityID, address builder, address lender, address agent, address project, uint256 repayAmount, byt...

6.8AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.8 views

Registry not updated when proxy ownership is transferred

Lines of code Vulnerability details Impact When the ownership of a MIMOProxy instance is transferred using the transferOwnership function, the MIMOProxyRegistry contract is not updated, although it is the main entry point of all the workflows, as described in the README.md file. Even after the...

6.7AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.5 views

Logic error

Lines of code Vulnerability details Impact This could result in ignoring a task from allocating. Also this could cause in incorrect memory of array. Proof of Concept // Local instance of lastAllocatedChangeOrderTask. To save gas. uint256 i = lastAllocatedChangeOrderTask; // Local instance of...

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

Functions transferFrom() and transfer() will fail because of commented code

Lines of code Vulnerability details Impact These 2 functions will fail just because the dev forgot to remove the commented code ex / sender / wich is very bad for users. Proof of Concept Tools Used visual Recommended Mitigation Steps remove the / and /. --- The text was updated successfully, but...

7.1AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.7 views

projectCost may be reverted due to out of gas problem if having too many tasks. lendToProject and recoverTokens may always revert because of this.

Lines of code Vulnerability details Impact projectCost may be reverted due to out of gas problem if having too many tasks. lendToProject and recoverTokens may always revert because of this. If lendToProject always revert, community owner won't be able to lends fund to the published project. Tasks...

6.5AI score
Exploits0
Code423n4
Code423n4
added 2022/08/06 12:0 a.m.14 views

Missing EIP-155 replay attack protection

Lines of code Vulnerability details Impact publishProject/addMember/escrow in Community and inviteContractor/updateProjectHash/addTasks/setComplete/changeOrder in Project use ecrecover for signed messages to check access. However, all signed messages that is used to check access do not include an...

6.8AI score
Exploits0
Total number of security vulnerabilities10190