Open-Source Security Intelligence

Know every vulnerability
before it knows you.

DevGuard continuously monitors your dependencies and alerts you when CVEs like this one affect your stack — with real-time threat intelligence built for developers.

Search

GHSA-8rc9-vxjh-qjf2

MediumCVSS 6 / 10
Published Jun 20, 2023·Last modified Aug 20, 2024
Affected Components(0)

No affected components available

Description

A vulnerability exists that allows a malicious validator to trick the Vega network into re-processing past Ethereum events from Vega’s Ethereum bridge. For example, a deposit to the collateral bridge for 100USDT that credits a party’s general account on Vega, can be re-processed 50 times resulting in 5000USDT in that party’s general account. This is without depositing any more than the original 100USDT on the bridge.

Despite this exploit requiring access to a validator's Vega key, a validator key can be obtained at the small cost of 3000VEGA, the amount needed to announce a new node onto the network.

The steps to carry out this exploit are as follows:

  1. Cause an Ethereum event on one of the bridge contracts e.g a deposit to the collateral bridge, or the staking bridge
  2. This will result in the Ethereum-event-forwarder of each node to submit a ChainEvent transaction to the Vega network corresponding to that event
  3. Scrape the valid chain event transaction from the Tendermint block data using a node’s Tendermint API
  4. Change the value of the txId field of the ChainEvent to any valid, but different, value
  5. Bundle the tweaked ChainEvent into a new transaction, sign it with a validator key and resubmit to the Vega network
  6. The fraudulent ChainEvent will be processed by Vega as if it were a new ChainEvent even though it did not occur on Ethereum

The key to this exploit is in step 4. The txId field of the ChainEvent is used when checking for ChainEvent resubmission, but NOT during the subsequent on-chain verification of the event. Therefore changing the txId of an existing ChainEvent is enough to by-pass the duplication check and for it to still be verified as a real event.

Impact

The impact of this exploit is dependent on the ChainEvent being manipulated. The below table describes each one:

| Chain Event | Allows | Consequence | | ------------- | ------------- | ------------- | | Deposit | Generation of unlimited funds of any asset | Withdrawal of all assets | | Stake Deposit | Delegate unlimited Vega to a single node | A single node has controlling amount of voting power | | Stake Removed | Force a Validator node to drop below self-stake requirements | Prevents reward payouts | | Bridge Stop | The Vega network to think the bridge is stopped | Prevent anyone from withdrawing funds | | Signer Removed | The Vega network to think a validator nodes is not on the multisig contract | Prevent reward payouts |

Patches

v0.71.6

Workarounds

No work around known, however there are mitigations in place should this vulnerability be exploited:

  • there are monitoring alerts, for mainnet1, in place to identify any issues of this nature including this vulnerability being exploited
  • the validators have the ability to stop the bridge thus stopping any withdrawals should this vulnerability be exploited

References

N/A

Risk Scores
Base Score
6.0

The vulnerability requires physical access to the device to be exploited. It is difficult for an attacker to exploit this vulnerability and may require special conditions. An attacker needs high-level or administrative privileges. The attacker needs the user to perform some action, like clicking a link. The vulnerability can affect other systems as well, not just the initial system. There is a high impact on the confidentiality of the information. There is a low impact on the integrity of the data. There is a low impact on the availability of the system.

Threat Intelligence
5.5

Exploitation attempts have been detected. Elevated vigilance and prompt remediation are advised.

EPSS
0.49%

The exploit probability is very low. The vulnerability is unlikely to be exploited in the next 30 days.

Exploit
Not available

We did not find any exploit available. Neither in GitHub repositories nor in the Exploit-Database.

Browse More

Scan your project

Continuously monitor your dependencies and get alerted when vulnerabilities like this one affect your stack.

Checkout DevGuard