CVE-2026-58494

Wasmtime: WASI hard links bypass wasmtime-wasi's FilePerms for destination

Published Jul 8, 2026 CVSS 3.1 · 6.5 Medium EPSS < 1% KEV · Not listed
Description
Wasmtime is a runtime for WebAssembly. Prior to 24.0.11, 36.0.12, 45.0.3, and 46.0.1, wasmtime-wasi hard-link creation and renaming check directory permissions but not matching FilePerms on source and destination preopens, allowing a WASI guest with a read-only source file capability to overwrite host files exposed as FilePerms::READ through wasip1, wasip2, or wasip3 filesystem interfaces. This issue is fixed in versions 24.0.11, 36.0.12, 45.0.3, and 46.0.1.

Analysis

AI-generated

Technical impact

This vulnerability, classified as CWE‑280, CWE‑281, and CWE‑863, stems from the Wasmtime runtime’s failure to cross‑check matching FilePerms on source and destination preopens during hard‑link creation and renaming. A WASI guest that has read‑only access to a source file but lacks write permissions can therefore bypass intended access controls and overwrite host files exposed with FilePerms::READ. The result is unauthorized modification of host files, which can undermine filesystem isolation and potentially allow privilege escalation if critical files are targeted.

Affected Systems

The flaw affects the Wasmtime runtime from bytecodealliance, specifically all releases earlier than v24.0.11, v36.0.12, v45.0.3, and v46.0.1. Any deployment of Wasmtime that allows WASI guests to access host files via the wasip1, wasip2, or wasip3 filesystem interfaces is vulnerable.

Risk and Exploitability

The CVSS score is 6.5, indicating moderate severity. The EPSS score of < 1% indicates a low probability of exploitation, and the vulnerability is not listed in CISA's KEV catalog. Exploitation requires that the attacker run a WebAssembly module with hard‑link or rename capabilities that target a host file exposed as read‑only, a scenario that can arise in containerized or sandboxed environments that grant the guest filesystem access. Because the flaw circumvents enforced permissions it can be used to modify critical files, but it does not allow arbitrary code execution; thus the risk is significant for environments that rely on filesystem isolation.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Wasmtime to version 24.0.11 or later, which includes the fix for hard‑link creation and rename checks.
  • Limit the file permissions exposed to WASI guests, ensuring that hosts rarely expose files with read permissions unless absolutely necessary.
  • If the runtime offers configuration to disable hard‑link creation or rename operations, enable those controls until an upgrade can be performed.

Generated by OpenCVE AI on August 1, 2026 at 15:36 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-4ch3-9j33-3pmj Wasmtime: WASI hard links bypass wasmtime-wasi's FilePerms for destination
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Bytecodealliance
Bytecodealliance wasmtime
Vendors & Products Bytecodealliance
Bytecodealliance wasmtime
Type Values Removed Values Added
Description Wasmtime is a runtime for WebAssembly. Prior to 24.0.11, 36.0.12, 45.0.3, and 46.0.1, wasmtime-wasi hard-link creation and renaming check directory permissions but not matching FilePerms on source and destination preopens, allowing a WASI guest with a read-only source file capability to overwrite host files exposed as FilePerms::READ through wasip1, wasip2, or wasip3 filesystem interfaces. This issue is fixed in versions 24.0.11, 36.0.12, 45.0.3, and 46.0.1.
Title Wasmtime: WASI hard links bypass wasmtime-wasi's FilePerms for destination
Weaknesses CWE-281
CWE-863
References
Metrics cvssV3_1

{'score': 6.5, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N'}

Weaknesses
  • CWE-280

    Improper Handling of Insufficient Permissions or Privileges

  • CWE-281

    Improper Preservation of Permissions

  • CWE-863

    Incorrect Authorization

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Jul 9, 2026, 1:28 PM
Reserved
Jun 30, 2026, 8:21 PM
Status
Deferred
Published
Jul 8, 2026, 9:16 PM
Modified
Oct 25, 2026, 5:10 PM
Severity
Moderate
Public date
Jul 8, 2026, 8:22 PM