Skip to content
Fencer Intel
medium 4.3

GHSA-rg2q-2jh9-447q json

Gas mispricing in cosmwasm-vm

published 2y ago modified 2y ago also RUSTSEC-2024-0361

cvss
4.3
version 3.1, GitHub
cisa kev
Not listed
not in CISA's catalog
epss
—
no score, EPSS covers CVEs only
public exploits
0
none known

Summary

**Component:** wasmvm **Criticality:** Medium ([ACMv1](https://github.com/interchainio/security/blob/main/resources/CLASSIFICATION_MATRIX.md): I:Moderate; L:Likely) **Patched versions:** wasmvm 1.5.4, 2.0.3, 2.1.2

Some Wasm operations take significantly more gas than our benchmarks indicated. This can lead to missing the [gas target](https://github.com/CosmWasm/cosmwasm/blob/e50490c4199a234200a497219b27f071c3409f58/docs/GAS.md#cosmwasm-gas-pricing) we defined by a factor of ~10x. This means a malicious contract could take 10 times as much time to execute as expected, which can be used to temporarily DoS a chain.

See [CWA-2024-004](https://github.com/CosmWasm/advisories/blob/main/CWAs/CWA-2024-004.md) for more details.

Patch / fix

  • crates.io cosmwasm-vm 1.5.6, 1.5.7, 2.0.5, 2.0.6, 2.1.2, 2.1.3
  • go github.com/CosmWasm/wasmvm/v2 2.0.3, 2.1.2
  • go github.com/CosmWasm/wasmvm 1.5.4

Is GHSA-rg2q-2jh9-447q in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.

Check with Fencer

CVSS scores

assigned by version score vector
GitHub 3.1 4.3 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L

Affected packages

ecosystem package affected fixed in
crates.io cosmwasm-vm
<1.5.6
>=2.0.0, <2.0.5
>=2.1.0, <2.1.2
>=0.0.0-0, <1.5.7
>=2.0.0, <2.0.6
>=2.1.0, <2.1.3
1.5.6
2.0.5
2.1.2
1.5.7
2.0.6
2.1.3
go github.com/CosmWasm/wasmvm/v2
>=2.1.0, <2.1.2
>=2.0.0, <2.0.3
2.1.2
2.0.3
go github.com/CosmWasm/wasmvm
<1.5.4
1.5.4

Classification

Weakness
  • CWE-920 Improper Restriction of Power Consumption

References

Sources

Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.