CVE-2023-26489 Vulnerability Analysis & Exploit Details

CVE-2023-26489
Vulnerability Scoring

9.9
/10
Critical Risk

As a catastrophic security flaw, CVE-2023-26489 has severe implications, demanding immediate intervention.

Attack Complexity Details

  • Attack Complexity: Low
    Exploits can be performed without significant complexity or special conditions.
  • Attack Vector: Network
    Vulnerability is exploitable over a network without physical access.
  • Privileges Required: Low
    Some privileges are necessary to exploit the vulnerability.
  • Scope: Changed
    Successful exploitation can impact components beyond the vulnerable component.
  • User Interaction: None
    No user interaction is necessary for exploitation.

CVE-2023-26489 Details

Status: Modified

Last updated: 🕢 21 Nov 2024, 07:51 UTC
Originally published on: 🕗 08 Mar 2023, 20:15 UTC

Time between publication and last update: 623 days

CVSS Release: version 3

CVSS3 Source

security-advisories@github.com

CVSS3 Type

Secondary

CVSS3 Vector

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H

CVE-2023-26489 Vulnerability Summary

CVE-2023-26489: wasmtime is a fast and secure runtime for WebAssembly. In affected versions wasmtime's code generator, Cranelift, has a bug on x86_64 targets where address-mode computation mistakenly would calculate a 35-bit effective address instead of WebAssembly's defined 33-bit effective address. This bug means that, with default codegen settings, a wasm-controlled load/store operation could read/write addresses up to 35 bits away from the base of linear memory. Due to this bug, however, addresses up to `0xffffffff * 8 + 0x7ffffffc = 36507222004 = ~34G` bytes away from the base of linear memory are possible from guest code. This means that the virtual memory 6G away from the base of linear memory up to ~34G away can be read/written by a malicious module. A guest module can, without the knowledge of the embedder, read/write memory in this region. The memory may belong to other WebAssembly instances when using the pooling allocator, for example. Affected embedders are recommended to analyze preexisting wasm modules to see if they're affected by the incorrect codegen rules and possibly correlate that with an anomalous number of traps during historical execution to locate possibly suspicious modules. The specific bug in Cranelift's x86_64 backend is that a WebAssembly address which is left-shifted by a constant amount from 1 to 3 will get folded into x86_64's addressing modes which perform shifts. For example `(i32.load (i32.shl (local.get 0) (i32.const 3)))` loads from the WebAssembly address `$local0 << 3`. When translated to Cranelift the `$local0 << 3` computation, a 32-bit value, is zero-extended to a 64-bit value and then added to the base address of linear memory. Cranelift would generate an instruction of the form `movl (%base, %local0, 8), %dst` which calculates `%base + %local0 << 3`. The bug here, however, is that the address computation happens with 64-bit values, where the `$local0 << 3` computation was supposed to be truncated to a a 32-bit value. This means that `%local0`, which can use up to 32-bits for an address, gets 3 extra bits of address space to be accessible via this `movl` instruction. The fix in Cranelift is to remove the erroneous lowering rules in the backend which handle these zero-extended expression. The above example is then translated to `movl %local0, %temp; shl $3, %temp; movl (%base, %temp), %dst` which correctly truncates the intermediate computation of `%local0 << 3` to 32-bits inside the `%temp` register which is then added to the `%base` value. Wasmtime version 4.0.1, 5.0.1, and 6.0.1 have been released and have all been patched to no longer contain the erroneous lowering rules. While updating Wasmtime is recommended, there are a number of possible workarounds that embedders can employ to mitigate this issue if updating is not possible. Note that none of these workarounds are on-by-default and require explicit configuration: 1. The `Config::static_memory_maximum_size(0)` option can be used to force all accesses to linear memory to be explicitly bounds-checked. This will perform a bounds check separately from the address-mode computation which correctly calculates the effective address of a load/store. Note that this can have a large impact on the execution performance of WebAssembly modules. 2. The `Config::static_memory_guard_size(1 << 36)` option can be used to greatly increase the guard pages placed after linear memory. This will guarantee that memory accesses up-to-34G away are guaranteed to be semantically correct by reserving unmapped memory for the instance. Note that this reserves a very large amount of virtual memory per-instances and can greatly reduce the maximum number of concurrent instances being run. 3. If using a non-x86_64 host is possible, then that will also work around this bug. This bug does not affect Wasmtime's or Cranelift's AArch64 backend, for example.

Assessing the Risk of CVE-2023-26489

Access Complexity Graph

The exploitability of CVE-2023-26489 depends on two key factors: attack complexity (the level of effort required to execute an exploit) and privileges required (the access level an attacker needs).

Exploitability Analysis for CVE-2023-26489

CVE-2023-26489 presents an accessible attack vector with minimal effort required. Restricting access controls and implementing security updates are critical to reducing exploitation risks.

Understanding AC and PR

A lower complexity and fewer privilege requirements make exploitation easier. Security teams should evaluate these aspects to determine the urgency of mitigation strategies, such as patch management and access control policies.

Attack Complexity (AC) measures the difficulty in executing an exploit. A high AC means that specific conditions must be met, making an attack more challenging, while a low AC means the vulnerability can be exploited with minimal effort.

Privileges Required (PR) determine the level of system access necessary for an attack. Vulnerabilities requiring no privileges are more accessible to attackers, whereas high privilege requirements limit exploitation to authorized users with elevated access.

CVSS Score Breakdown Chart

Above is the CVSS Sub-score Breakdown for CVE-2023-26489, illustrating how Base, Impact, and Exploitability factors combine to form the overall severity rating. A higher sub-score typically indicates a more severe or easier-to-exploit vulnerability.

CIA Impact Analysis

Below is the Impact Analysis for CVE-2023-26489, showing how Confidentiality, Integrity, and Availability might be affected if the vulnerability is exploited. Higher values usually signal greater potential damage.

  • Confidentiality: High
    Exploiting CVE-2023-26489 can result in unauthorized access to sensitive data, severely compromising data privacy.
  • Integrity: High
    CVE-2023-26489 could allow unauthorized modifications to data, potentially affecting system reliability and trust.
  • Availability: High
    CVE-2023-26489 can disrupt system operations, potentially causing complete denial of service (DoS).

Exploit Prediction Scoring System (EPSS)

The EPSS score estimates the probability that this vulnerability will be exploited in the near future.

EPSS Score: 0.185% (probability of exploit)

EPSS Percentile: 56.86% (lower percentile = lower relative risk)
This vulnerability is less risky than approximately 43.14% of others.

CVE-2023-26489 References

External References

CWE Common Weakness Enumeration

CWE-787

Vulnerable Configurations

  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.84.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.84.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.3:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.85.3:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.86.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.86.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.86.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.86.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.87.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.87.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.87.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.87.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.88.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.89.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.89.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.89.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.89.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.90.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.90.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.91.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.91.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.92.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.92.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:cranelift-codegen:0.93.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:cranelift-codegen:0.93.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.37.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.37.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.38.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.38.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.38.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.38.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.38.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.38.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.38.3:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.38.3:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.39.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.39.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.39.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.39.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.40.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.40.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:0.40.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:0.40.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:1.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:1.0.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:1.0.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:1.0.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:1.0.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:1.0.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:2.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:2.0.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:2.0.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:2.0.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:2.0.2:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:2.0.2:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:3.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:3.0.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:3.0.1:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:3.0.1:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:4.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:4.0.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:5.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:5.0.0:*:*:*:*:rust:*:*
  • cpe:2.3:a:bytecodealliance:wasmtime:6.0.0:*:*:*:*:rust:*:*
    cpe:2.3:a:bytecodealliance:wasmtime:6.0.0:*:*:*:*:rust:*:*

Protect Your Infrastructure against CVE-2023-26489: Combat Critical CVE Threats

Stay updated with real-time CVE vulnerabilities and take action to secure your systems. Enhance your cybersecurity posture with the latest threat intelligence and mitigation techniques. Develop the skills necessary to defend against CVEs and secure critical infrastructures. Join the top cybersecurity professionals safeguarding today's infrastructures.

Other 5 Recently Published CVEs Vulnerabilities

  • CVE-2025-2129 – A vulnerability was found in Mage AI 0.9.75. It has been classified as problematic. This affects an unknown part. The manipulation leads to insecur...
  • CVE-2025-2127 – A vulnerability was found in JoomlaUX JUX Real Estate 3.4.0 on Joomla. It has been classified as problematic. Affected is an unknown function of th...
  • CVE-2025-2126 – A vulnerability was found in JoomlaUX JUX Real Estate 3.4.0 on Joomla and classified as critical. This issue affects some unknown processing of the...
  • CVE-2025-2125 – A vulnerability has been found in Control iD RH iD 25.2.25.0 and classified as problematic. This vulnerability affects unknown code of the file /v2...
  • CVE-2025-2124 – A vulnerability, which was classified as problematic, was found in Control iD RH iD 25.2.25.0. This affects an unknown part of the file /v2/custome...