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

Marked Undetermined or Informational by the firm. Not counted as findings.

InformationalApplication Monitoring Can Be Improved by Emitting More EventsAcknowledged

In order to validate the proper deployment and initialization of the contracts, it is a good practice to emit events. Also, any important state transitions can be logged, which is beneficial for monitoring the contract, and also tracking eventual bugs or hacks. There is currently no event indicating an update of `VAIVault`'s pending rewards.

InformationalUnlocked PragmaAcknowledged

Every Solidity file specifies in the header a version number of the format `pragma solidity (^)0.8.*`. The caret (`^`) before the version number implies an unlocked pragma, meaning that the compiler will use the specified version _and above_, hence the term "unlocked".

InformationalVAI Losing 1$ Peg May Lead to a Drained `VAIVault` and Destabilize the XVS Token and VaultAcknowledged

The [VAI token is an algorithmic stable coin](https://github.com/VenusProtocol/venus-protocol/#venus-protocol) and pegged to 1 USD, similar to [MakerDAO's DAI](https://developer.makerdao.com/dai/1/). However, it is not guaranteed to always hold its peg to 1 USD under all circumstances. Should the token lose its peg and be (much) less valuable than 1 USD it could lead to a high increase of users depositing their `VAI` tokens in the `VAIVault` and earning `XVS` tokens as interest at a (high) discount. This could lead to an unexpectedly quick depletion of `XVS` funds in the `VAIVault` and in turn destabilize the `XVS` token value and all its associated pools in the `XVSVault`.

Undetermined`VRTVault` May Be Operated and Used Past the Last Accruing BlockFixed

The `VRTVault` has a built-in deprecation through variable `lastAccruingBlock`, which dictates after which block number no more rewards will be accrued. There are three scenarios when and how it can be changed: 1. When calling it the first time it can be set arbitrarily in the future or the past. 1. Once initialized but not yet reached, it can be set to an arbitrary block number in the future, or a value between the current block number and the current value of `lastAccruingBlock`. 1. **Once reached/passed it, it can be changed to be at an arbitrary number in the past or the future and thereby re-enable `deposit()`.**

UndeterminedVaults May Be Insufficiently FundedMitigated

All three vaults `VAIVault.sol`, `VRTVault.sol` and `XVSVault.sol` do not guarantee to hold sufficient funds at all times to cash out accrued rewards, as all three do not have automatic funding/minting mechanisms, but rather get funded manually by Venus at certain intervals. In particular reward tokens used in the `XVSVault.sol` and `VAIVault.sol` contracts may pay out until the reward tokens supplies run dry, but will however take in the full deposited value (Due to `XVSStore.safeRewardTransfer()` and `VAIVault.safeXVSTransfer()`, respectively).

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