Skip to content

Code4rena

Fractional v2 contest

Every publicly disclosed report for Fractional v2 contest and what kind of bugs they were.

disclosed reports
32
most reported class
Business logic
bug classes found
5
first disclosure
2022
Find Fractional v2 contest on bugbounty.fyi Current scope, rewards and status, if it runs a public program.

Disclosed reports

Newest first. Only what Fractional v2 contest chose to make public.

Audit finding

Division rounding can make fraction-price lower than intended (down to zero)

Integer division in the buyout module rounds the fraction price down, so when the buyout price is close to the total supply the fraction price can become zero or half the intended value. An attacker can then buy fractions for free or at a large discount, and the proposer may lose their fractions for little or nothing.

Fractional v2 contest

High
DoS

Forced buyouts can be performed by malicious buyers

A malicious proposer can start a buyout using a contract that cannot receive ERC1155 tokens. If the buyout fails, the end function reverts when trying to send tokens back, preventing any new buyout from starting.

Fractional v2 contest

High
Business logic

Steal NFTs from a Vault, and ETH + Fractional tokens from users.

The withdrawContribution function in Migration.sol refunds a user's ETH and fractional tokens without updating the proposal's totalEth and totalFractions, allowing an attacker to inflate their proposal's totals by repeatedly joining and withdrawing. This lets the attacker steal all ETH and fractional tokens from other proposals and take over the vault's NFTs.

Fractional v2 contest

High
Business logic

Failed proposal can be committed again

The commit function in the Migration contract can be called multiple times for the same proposal if the buyout fails within the 7-day migration period. Combined with a separate flaw where the contract does not account for the actual number of fractions returned from a failed buyout, an attacker can repeatedly commit and steal ETH from the migration contract.

Fractional v2 contest

High
Access control

Malicious Users Can Exploit Residual Allowance To Steal Assets

The vault's batch deposit functions let any caller specify an arbitrary source address, so anyone can pull tokens from a user who has granted the vault an allowance. An attacker could steal the user's remaining approved tokens and NFTs.

Fractional v2 contest

High
Business logic

Migration can permanently fail if user specifies different lengths for selectors and plugins

The migration proposal function did not check that the selectors and plugins arrays had equal lengths. If a proposal was created with more selectors than plugins, the subsequent vault installation would revert with an out-of-bounds error, preventing a new vault from being created and permanently locking assets in the old vault.

Fractional v2 contest

High
Business logic

[Buyout module] Fraction price is not updated when total supply changes

The Buyout module stores a fraction price calculated from the total supply at the moment a buyout starts, and keeps using that stored price for later buys and sells even if the total supply changes. An attacker could inflate the supply during a live buyout and then sell a small share of the new supply to drain the buyout pool while keeping most of the vault.

Fractional v2 contest

Medium
Smart contracts

Use of payable.transfer() may lock user funds

The contract uses payable.transfer() to send Ether, which only forwards 2300 gas and can fail if the recipient is a contract with a costly fallback or a proxy. This can lock user funds because there is no alternative withdrawal address.

Fractional v2 contest

Medium
Access control

Vault implementation can be destroyed leading to loss of all assets

The shared implementation contract behind every vault proxy was left uninitialised, so anyone could become its owner and destroy it with a selfdestruct call. That would make every vault proxy unusable and permanently lock all assets held in them.

Fractional v2 contest

High
Business logic

Migration total supply reduction can be used to remove minority shareholders

The migration contract allows the new total supply to be set arbitrarily low, so when shares are calculated for contributors, rounding down can zero out minority shareholders' shares. An attacker or careless majority could set a very low new supply, causing minority contributors to lose their entire contribution when the migration is committed and a buyout starts.

Fractional v2 contest

Medium
Access control

A vault owner can frontrun a plugin call and change its implementation

A vault owner can overwrite an existing plugin selector with a new implementation, allowing them to frontrun a user's call and change the logic executed. This can also cause confusion when multiple plugins with the same selector are installed, as only the last one remains active.

Fractional v2 contest

Medium
Audit finding

Migration Module: Re-enter commit using custom token

The migration module's commit function updates state after making external calls, allowing a malicious ERC1155 token to reenter and drain ETH. An attacker could repeatedly reenter to steal funds from the migration module.

Fractional v2 contest

High
Business logic

Fund will be stuck if a buyout is started while there are pending migration proposals

A migration proposal's contributed funds can become permanently stuck if another party starts a buyout auction on the same vault. The migration contract's leave and withdraw functions only check the buyout state, not whether the buyout was initiated by the migration contract itself, so contributors cannot withdraw once the buyout is active or successful.

Fractional v2 contest

High
Smart contracts

The FERC1155.sol don’t respect the EIP2981

The FERC1155 contract implements the EIP-2981 royalty getter but does not register the ERC2981 interface in its ERC-165 supportsInterface function. As a result, external marketplaces that check interface support cannot detect that the NFT supports royalties, so royalty enforcement may fail.

Fractional v2 contest

Medium
Business logic

Migration’s leave function allows leaving a committed proposal

The leave function does not check whether a proposal has been committed, so a user can call it after a failed committed proposal and receive their original contribution instead of the adjusted amount from the buyout auction. This can cause a deficit and loss of assets for other users.

Fractional v2 contest

High
Smart contracts

Migration fails when all tokens are joined

When all token holders join a migration proposal, the total fractions equal the total supply, causing a division by zero in the _calculateTotal function. This prevents the migration from proceeding, whereas a buyout in the same situation would not make sense.

Fractional v2 contest

Medium
Access control

fallback() function can bypass permission/auth checks imposed in execute()

The vault's fallback function allows calls to installed plugins without checking caller permissions, unlike the execute function. An attacker who is a previous owner or installs a malicious plugin can use this to transfer NFTs out of the vault without the current owner's consent.

Fractional v2 contest

Medium
Business logic

Migration: no check that user-supplied proposalId and vault match

The Migration contract did not verify that the user-supplied proposalId and vault matched the actual vault for that proposal. An attacker could join a proposal with a worthless token from a different vault, then leave using the original vault to withdraw valuable tokens.

Fractional v2 contest

High
Business logic

The time constraint of selling fractions can be bypassed by directly transferring fraction tokens to the buyout contract

The Buyout contract's end function checks the contract's fraction token balance to decide if a buyout succeeded, without distinguishing tokens deposited through the intended sellFractions function from tokens sent directly. An attacker could start a buyout with almost no tokens, then transfer enough fraction tokens directly to the contract just before calling end, so the buyout is treated as successful and the attacker acquires the NFTs for far less than their value.

Fractional v2 contest

High