Venus protocol (vaults)

QuantstampRepository at commit f1426f0

Audit

Part of Quantstamp’s series

Quantstamp reviewed Venus Protocol (Venus protocol (vaults)) on 19 May 2023: 16 findings, 0 critical; 10 marked fixed, 4 acknowledged, 2 open; 4 more marked mitigated.

No open critical findings
Open the reportOpen Venus Protocol’s security record

Report hosted on certificate.quantstamp.com.

Trustblock does not review code.

Findings25

Statuses are the security firm’s own, from its report.

SeverityOpenAcknowledgedFixedMitigated
Critical0000
High0030
Medium0040
Low2434

The firm marks these findings Mitigated. They are not counted as open, acknowledged or fixed.

LowConsiderations on Claiming Rewards for Other Users for the VAI and XVS VaultsMitigated

The XVS Vault allows anyone to `claim()` a user's interest in any pool. Typically, this is not an issue when the pool has enough rewards to be claimed. However, the XVS vault is limited in its ability to distribute rewards by the number of rewards available in `XVSStore`. If there are not enough rewards at the time the staker claims, they will get fewer rewards than they should. If the rewards are insufficient, stakers would rather wait until they become enough to claim. However, anyone can claim them and force them to lose some part of their rewards. A similar issue exists when claiming the XVS rewards in the VAI vault.

LowInaccurate Calculation of Stake Amount for XVS Vault PoolsMitigated

According to the code comments, the `getStakeAmount()` function ``` @notice Get the XVS stake balance of an account (excluding the pending withdrawals) ``` However, the returned stake amount only accounts for the pool whose pool and rewards tokens are both XVS. In other words, deposits in pools whose pool token is XVS but the rewards token is not XVS are not considered valid XVS stake balance.

LowMissing Input ValidationMitigated

It is important to validate inputs, even if they only come from trusted addresses, to avoid human error. The following functions do not have a proper validation of input parameters: 1. `XVSVault.add()` does not check: 1. that parameters `_rewardToken` and `_token` are different from `address(0)`. 1. that parameters `_rewardPerBlock` and `_lockPeriod` are non-zero. 1. `XVSVault.setXvsStore()` does not check: 1. that parameters `_xvs` and `_xvsStore` are different from `address(0)`. 1. `XVSStore.setPendingAdmin()` does not check: 1. that parameter `_admin` is different from `address(0)`. 1. that parameter `_admin` is different from the previous admin address. 1. `XVSStore.setNewOwner()` does not check: 1. that parameter `_owner` is different from the previous owner address.

LowVaults May Not Deliver Full PayoutsMitigated

The function `VAIVault.safeXVSTransfer()` transfers whatever XVS it can given the contract's balance, but `VAIVault._withdraw()` and `VAIVault.deposit()` both update the `user.rewardDebt` as if the full payout was delivered. `XVSStore.safeRewardTransfer()` and its usages exhibit the same behavior.

Contracts in scope

No deployed address is recorded for this audit.

The report names a repository or files. Open the report to see its scope.

Repository and files the report names (7)

  • https://github.com/VenusProtocol/venus-protocol/contracts/XVSVault/XVSVaultStorage.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/Vault/VAIVaultStorage.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/VRTVault/VRTVaultStorage.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/Vault/VAIVault.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/XVSVault/XVSVault.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/XVSVault/XVSStore.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a
  • https://github.com/VenusProtocol/venus-protocol/contracts/VRTVault/VRTVault.sol at commit f1426f07b44f9b557059a0e364ce5d90e18f997a

Part of Venus Protocol’s security record

Venus Protocol
Audits67 audits by 7 firmsLast audit Sep 2025, by Quantstamp.
Critical findingsNo open critical findingsAcross the 67 reports, 4 critical findings were reported. Each is marked fixed by the firm that reported it.
IncidentIncident 12 May 2022Source: De.Fi incident database.
Open Venus Protocol’s security record

Security firm

Quantstamp

240 projects reviewed · 338 reports · latest Nov 2026

See Quantstamp’s audits

Something wrong on this page? A missing report, a wrong date, a finding that was fixed since. Tell us and we check it against its source.

Tell us