Lucene search
K
Code423n4Recent

10190 matches found

Code423n4
Code423n4
added 2022/08/15 12:0 a.m.9 views

Some ERC20 tokens don't return bool values

Lines of code Vulnerability details Impact VotingEscrow will not work for such tokens. Proof of Concept This issue is same as a previous contest. In the implementation of token transfer, the return value is checked after token transfer. But some tokens do not return bool values. After DM, I know...

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

Deposit does not verify if tokens are transfered successfully

Lines of code Vulnerability details please find below one report encapsulating 2 M bugs which are the exact same bug found in two seperate functions within the same .sol file M1 No Return Value on transferFrom VotingEscrow.sol makes checks to be sure that the transferFrom function is sending to t...

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

Use safetransfer/safetransferFrom consistently instead of transfer/transferFrom

Lines of code Vulnerability details Impact Its a good to add require statement to checks the return value of token transfer or using safetransfer or safetransferFrom on Openzeppelin to ensure the token revert when transfer failure. Failure to do so will cause silent failures of transfer and affec...

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

The toLocked.end >= fromLocked.end in delegate function is inconsistent with design.

Lines of code Vulnerability details Impact The condition of toLocked.end = fromLocked.end in function delegate is inconsistent with design in veFDT Checkpoint Math Proof of Concept In VotingEscrow.sol. L589 requiretoLocked.end = fromLocked.end, "Only delegate to longer lock"; But In veFDT...

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

Users can create an un-bannable contract

Lines of code Vulnerability details Impact Users can create an un-bannable contract by working from a contract's constructor and then self-destructing on each instantiation. Users can also deterministically deploy the contract to the same address every time they want to interact with fiatDAO...

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

The current implementation of the VotingEscrow contract doesn't support fee on transfer tokens

Lines of code Vulnerability details Impact Some ERC20 tokens implemented so a fee is taken when transferring them, for example STA and PAXG. The current implementation of the VotingEscrow contract will mess up the accounting of the locked amounts if token will be a token like that, what will lead...

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

Exposure of critical functions

Lines of code Vulnerability details Impact AdminRole mixin exposes critical functions without any restrictions like grantAdmin revokeAdmin Proof of Concept Criticial functions like grantAdmin can be externally accessed changing the critical roles like admin. // for eg: function grantAdminaddress...

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

VotingEscrow Owner Can Give Power to Force Undelegate

Lines of code Vulnerability details Impact As the owner can change the blocklist to anything, a malicious or compromised owner has the ability to set blocklist to an EOA which could directly call forceUndelegate on any number of users. This could be used in bad faith to distort voting. Recommende...

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

the 1st creator can get a little amount or 0 creatorShares

Lines of code Vulnerability details Impact On line 513 the MarkerFees.getFees function if there is more than one creatorRecipients it will loop through them and set there payment after that it will subtract creatorRev - totalRoyaltiesDistributed and set it to the the 1st creatorRecipients...

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

Unsafe typecasting can lead to tokens being locked in the contract

Lines of code Vulnerability details Impact In the createLock function the amount is calculated by casting the uint256 value to int128 in an unsafe way. Specifically the locked.amount is calculated as: locked.amount += int128int256value; could result in a negative value for locked.amount. For...

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

No check for nftcollection address leads to the user's loss in NFTDropMarket

Lines of code Vulnerability details Impact There is no check for nftContract address in function createFixedPriceSale of NFTDropMarketFixedPriceSale.sol. The seller can deploy a malicious NFT collection contract, everything is very like the collection produced by NFTCollectionFactory except the...

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

Wrong logic in increaseUnlockTime() function in case undelegated lock and call _checkpoint()

Lines of code Vulnerability details Impact In increaseUnlockTime function, in case it’s undelegated lock, it calls checkpoint for msg.sender with oldLocked and locked. But actually, these 2 locks oldLocked and locked are the same. It makes the logic in checkpoint function works incorrectly. Proof...

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

VotingEscrow Ownership Management Lacks Basic Protections

Lines of code Vulnerability details Impact A comment saying "Owner should always be a timelock contract" is not sufficient protection for something as critical as ownership. There should be: a zero address check on addr a propose/transfer method of ownership transfer, not a unilateral transfer...

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

Malicious creator can create different NFT drop collections with NFTs that will be revealed to correspond to same ipfs token URI

Lines of code Vulnerability details Impact The following createNFTDropCollection function with different name, symbol, and nonce can be called to create different NFT drop collections. function createNFTDropCollection string calldata name, string calldata symbol, string calldata baseURI, bytes32...

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

User can have full voting power with virtually no lockup using multiple locks and delegation

Lines of code Vulnerability details Impact User receives voting power of max lock but only locks for a minimal amount of time Proof of Concept In VotingEscrow.solcheckpoint, the duration of the delegatee and the total delegated tokens are used to determine the amount of voting power that a lock...

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

USE SAFETRANSFER()/SAFETRANSFERFROM() INSTEAD OF TRANSFER()/TRANSFERFROM()

Lines of code Vulnerability details Impact It is a good idea to add a require statement that checks the return value of ERC20 token transfers or to use something like OpenZeppelin’s safeTransfer/safeTransferFrom unless one is sure the given token reverts in case of a failure. Failure to do so wil...

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

User Funds are Locked in the VotingEscrow Contract When Delegated User Withdraws

Lines of code Vulnerability details Description There exists an issue when a delegated user attempts to withdraw the locked funds after a lock duration is expired, as a result the funds for the original user who triggered the delegation is lost within the contract. Impact This is an issue because...

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

Malicious creator can create different NFT collections with NFTs corresponding to same ipfs token URI

Lines of code Vulnerability details Impact A creator can call the following createNFTCollection function with different name, symbol, and nonce to create different NFT collections. function createNFTCollection string calldata name, string calldata symbol, uint256 nonce external returns address...

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

Upgraded Q -> H from 275 [1660349121925]

Judge has assessed an item in Issue 275 as High risk. The relevant finding follows: --- The text was updated successfully, but these errors were encountered: All reactions...

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

Upgraded Q -> H from 54 [1660349227136]

Judge has assessed an item in Issue 54 as High risk. The relevant finding follows: --- The text was updated successfully, but these errors were encountered: All reactions...

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

Upgraded Q -> H from 210 [1660349369322]

Judge has assessed an item in Issue 210 as High risk. The relevant finding follows: --- The text was updated successfully, but these errors were encountered: All reactions...

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

Operator can use reentrancy within mintFromFixedPriceSale to bypass limitPerAccount.

Lines of code Vulnerability details Impact An operator can pass a contract as the buyReferrer parameter. When distributeFunds is called it sends ETH to the contracts' receive function. After transferring any NFTs the contract may have to another contract it calls mintFromFixedPriceSale passing a...

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

Take over of MinterRole contract

Lines of code Vulnerability details Impact Any user can call the grantMinter or revokeMinter method and take the mint control of the contract. Proof of Concept The grantMinter and revokeMinter methods are not protected by any type of authentication restriction, when they should have the...

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

Take over of AdminRole contract

Lines of code Vulnerability details Impact Any user can call the grantAdmin or revokeAdmin method and take control of the contract. Proof of Concept The grantAdmin and revokeAdmin methods are not protected by any type of authentication restriction, when they should have the onlyAdmin modifier. So...

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

safeIncreaseAllowance may fail on USDT case

Lines of code Vulnerability details Impact safeIncreaseAllowance may fail on USDT case. If a swap completed with dust fund. Consequence swap will always revert due to non-zero allowance on USDT token. Proof of Concept function safeIncreaseAllowanceIERC20 token, address spender, uint256 value...

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

[H1] MIMOProxy can be PWNED by malicious delegate call

Lines of code Vulnerability details Impact PBR proxy owner change protection can bypassed / DoS PoC PRBProxy has a protection to prevent malicious delegatecall to overwrite owner. function executeaddress target, bytes calldata data public payable override returns bytes memory response ... ... //...

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

MIMOProxy.sol can change owner, but not all contracts expect it. Registry.getCurrentProxy() can give wrong outputs.

Lines of code Vulnerability details Impact Registry.getCurrentProxy is expected to return the individual Proxy.sol for a user EOA. But Proxy.sol can change its owner, and Registry will not know it. Thus Registry.getCurrentProxy only show a deployers, and it means nothing for the project. Also,...

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

QA Report

Prevent possible future storage collisions The target action contracts of MIMOProxy.sol use storage slot 0 for immutable addresses, which doesn't currently pose an issue; however, if in future additional contracts are added which allow this slot in storage to be modified then it could open the...

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

Malicious targets can manipulate MIMOProxy permissions

Lines of code Vulnerability details The MIMOProxy contract stores per-caller, per-target, per-selector permissions in a nested internal mapping. MIMOProxy.solL21: /// INTERNAL STORAGE /// /// @notice Maps envoys to target contracts to function selectors to boolean flags. mappingaddress =...

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

MIMOAutoRebalance#rebalance can be used to drain vault due to reentrancy

Lines of code Vulnerability details Impact Vault is drained instead of rebalanced Proof of Concept The caller of rebalance is allowed to supply arbitrary swapData when calling rebalance. The can be used to swap into a malicious ERC20 token that transfers control to the attacker. This opens the...

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

Manager is able to charge an excessive fee by taking out a larger than necessary flash loan

Lines of code Vulnerability details Impact The manager's fee is determined by the flash loan amount he takes out. A manager can take out a large flash loan to increase the fee due to him. Proof of Concept Manager needs to rebalance a vault. Manager only needs 50k flash loan. Manager takes out 2m...

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

Double spend in execute function from the MIMOProxy

Lines of code Vulnerability details There is batch function in MIMOProxy smart contract. The function is inherited from the BoringBatchable contract. The function accept an array of bytes - call parameters, and do delegate call to addressthis for each of the call parameters. There also is execute...

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

Any permission can be used to execute any code in MimoProxy

Lines of code Vulnerability details Impact If a permission is given in MimoProxy to any function, it can then be abused to whitelist any other msg.sender/function by modifying the permissions mapping. There is a check that the owner was not modified, but no check on permissions which makes sense...

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

Unchecked Call Return Value

Lines of code Vulnerability details Impact The return value of a message call is not checked. Execution will resume even if the called contract throws an exception. If the call fails accidentally or an attacker forces the call to fail, this may cause unexpected behaviour in the subsequent program...

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

[H3] Persisted msg.value in a loop of delegate calls can be used to drain ETH from your proxy

Lines of code Vulnerability details Impact msg.value in a loop can be used to drain proxy funds PoC While BoringBatchable is out of the scope, this bug affects seriously MIMOProxy as it inherits. Some time ago I read a report about an auditor called samczsung . I believe that you are having the...

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

Everyone can perform emptyVaultOperation. Everyone can steal leftover par after repaying the loan from any vault. This pattern also applied to other files.

Lines of code Vulnerability details Impact Everyone can perform emptyVaultOperation. Everyone can steal leftover par after repaying the loan from any vault. It is intended to only be able to call from executeOperation through MIMOProxy callback but in fact everyone can execute it. Proof of Concep...

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

When a user is given the owner privilege of multiple MIMOProxy through transferOwnership, the user cannot choose which MIMOProxy to use as the current Proxy

Lines of code Vulnerability details Impact currentProxies is only set when the user calls the deployFor function of the MIMOProxyRegistry contract, function deployForaddress owner public override returns IMIMOProxy proxy IMIMOProxy currentProxy = currentProxiesowner; // Do not deploy if the proxy...

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

msg.sender lending pool and initiator can be forged in executeOperationin MImoLeverage

Lines of code Vulnerability details Impact Detailed description of the impact of this finding. the function signature is function executeOperation address calldata assets, uint256 calldata amounts, uint256 calldata premiums, address initiator, bytes calldata params external override returns bool...

7AI 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.15 views

Overwriting storage slots in MIMOProxy

Lines of code Vulnerability details Impact The MIMOProxy allows you to delegate a call to another contract from a permission of owner. With a delegate call, the entire storage layout is kept the same as it is on MIMOProxy. It means that if the delegate call will be made for smart contract with...

6.7AI score
Exploits0
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.8 views

Malicious manipulation of gas reserve can deny access to MIMOProxy

Lines of code Vulnerability details The MIMOProxy contract defines a minGasReserve value as a storage variable: MIMOProxy.solL18: /// @inheritdoc IMIMOProxy uint256 public override minGasReserve; The execute function uses this minGasReserve value to calculate a gas stipend to provide to the targe...

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

vaultOwner Can Front-Run rebalance() With setAutomation() To Lower Incentives

Lines of code Vulnerability details Impact A vaultOwner who is "not confident enough in ourselves to stay up-to-date with market conditions to know when we should move to less volatile collateral to avoid liquidations." They can open their vault to other users who pay attention to the markets and...

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

The MIMOVaultActions contract cannot withdraw assets to the user

Lines of code Vulnerability details Impact The MIMOVaultActions contract provides users with the functions of depositing, withdrawing and borrowing assets, which is called by the delegatecall of the MIMOProxy contract. But when borrowing or withdrawing assets, there is no function provided to giv...

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

Manager is able to use swapData.dexTxData to Perform Reentrancy

Lines of code Vulnerability details Impact Reentrancy here allows a manager to perform multiple operations on a given pool beyond the max limit. Proof of Concept A Manager, using swapData.dexTxData, can reenter MIMO actions performed on the vault he is managing. The manager deploys a FAKE token a...

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

rbData.toCollateral address can be different than the token address set in swapData.dexTxData.

Lines of code Vulnerability details Impact rbData.toCollateral address can be different than the token address set in swapData.dexTxData. A manager can supply toCollateral address of the collateral within the contract but supply a different address in swapParams.dexTxData such that the contract...

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

Incorrect implementation of access control in MIMOProxy:execute

Lines of code Vulnerability details Description There is a function execute in MIMOProxy smart contract. The function performs a delegate call to the user-specified address with the specified data. As an access control, the function checks that either it was called by the owner or the owner has...

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

If a MIMOProxy owner destroys their proxy, they cannot deploy another from the same address

Lines of code Vulnerability details When deploying a new MIMOProxy, the MIMOProxyRegistry first checks whether a proxy exists with the same owner for the given address. If an existing proxy is found, the deployment reverts: MIMOProxyRegistrydeployFor function deployForaddress owner public overrid...

6.7AI score
Exploits0
Total number of security vulnerabilities10190