Skip to content

Immunefi

Anvil

Every publicly disclosed report for Anvil and what kind of bugs they were.

disclosed reports
17
most reported class
Business logic
bug classes found
5
first disclosure
2024
Find Anvil on bugbounty.fyi Current scope, rewards and status, if it runs a public program.

Disclosed reports

Newest first. Only what Anvil chose to make public.

Access control

Anyone can cancel anyone's LOC

The cancelLOC function's authorisation check can be bypassed when a letter of credit has expired, allowing anyone to cancel any expired LOC. This prevents the legitimate creator from using createLOCFromExpired, because the LOC is deleted before they can act.

Anvil

Informational
DoS

DoS for the user's calling stake and stakeReleasableTokensFrom function

The CollateralVault contract allows anyone to call modifyCollateralizableTokenAllowanceWithSignature directly, so an attacker can front-run a user's stake transaction and consume the user's signature, causing the user's transaction to revert with an invalid signature error. This griefing attack repeatedly blocks the user's stake and stakeReleasableTokensFrom calls.

Anvil

Medium
Business logic

Users can withdraw funds at incorrect fee rate

A missing check in the CollateralVault contract allows a user to act as their own Collateralizable Contract, so they can create and modify reservations to lock in a historical withdrawal fee rate. An attacker could then withdraw funds at a lower fee than the current rate, reducing protocol revenue.

Anvil

Informational
Race condition

Frontrun to invalidate collateralizable approval signature

A staker's signed approval for a collateral pool could be submitted by anyone, so an attacker could front-run the staker's stake transaction with the same signature. This consumed the signer's nonce and made the staker's own transaction revert, causing griefing with no profit.

Anvil

Medium
Race condition

Signature Front-Running Vulnerability in CollateralVault

The CollateralVault contract's signature-based allowance modification uses a nonce that increments on each use, and anyone can call the function to consume the nonce. An attacker can front-run a user's stake transaction by calling the same function first, causing the original transaction to revert.

Anvil

Medium
Race condition

Token allowance signature can be front-run

A token allowance signature used when staking can be consumed by anyone who sees it, because the signature-consuming function is callable by any address. An attacker can front-run the user's stake transaction, causing the user's transaction to revert with an invalid signature error.

Anvil

Medium
DoS

Contract TimeBasedCollateralPool will be unable to process new user transactions and user funds are temporary frozen if a user unstake transaction of TimeBasedCollateralPool execute

When a pool reset transaction lands before a user's unstake transaction, the unstake still records pending unstake units against an account whose units were already zeroed. After the unstake completion timestamp, every user transaction reverts in the collateral reservation check, temporarily freezing funds in the pool.

Anvil

Low
Smart contracts

Typehash Discrepancy in CollateralizableTokenAllowanceAdjustment

The interface and implementation contracts define different type hashes for the CollateralizableTokenAllowanceAdjustment struct, with the implementation omitting the chainId and approver fields. This mismatch could cause signature verification to fail, potentially leading to a temporary freezing of funds.

Anvil

Informational
Business logic

Attackers can cause griefing attack to cause stake transactions of TimeBasedCollateralPool of users to always revert by front-running the user transaction to make the provided si

A signature-based allowance adjustment function can be called by anyone, so an attacker can front-run a user's stake transaction that includes a signed message, consume the signature, and cause the user's transaction to revert. This is a griefing attack that wastes the user's gas and causes a denial of service for staking.

Anvil

Medium
Race condition

Stake with signature can be front-run lead to user's stake failed

A user's stake transaction that includes a signed allowance approval can be front-run by an attacker who submits the same signature directly to the collateral vault, consuming the nonce and causing the user's stake to fail. The user must then make another transaction, and if the token's approval state has changed, they may be unable to stake again.

Anvil

Medium
Smart contracts

Tokens can be stuck forever in UniswapLiquidator because function retrieveTokens always reverts for USDT and all tokens that have transfer function that do not return boolean

The retrieveTokens function in UniswapLiquidator calls IERC20.transfer, which expects a boolean return value, but tokens like USDT do not return a value, so the call always reverts. As a result, USDT sent to the contract becomes permanently frozen and cannot be recovered by the owner.

Anvil

Informational
DoS

Collateralizable Contracts May Retain Status Unconditionally

A contract holding the collateralizableContract role can return an excessively large amount of data from its supportsInterface function, causing the owner's call to upsertCollateralizableContractApprovals to revert. This lets the malicious contract keep its privileged role indefinitely and may block approval of other contracts.

Anvil

Informational