{"id":"RUSTSEC-2026-0149","revision":null,"records":[{"revision":"51085cb0842440e781e9631425551758","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-47261","aliases":[],"title":"Wasmtime: WASI path_open(TRUNCATE) bypasses `FilePerms::WRITE` host restriction","description":"Wasmtime is a runtime for WebAssembly. In versions prior to 24.0.9, 36.0.10, and 44.0.2, when a filesystem preopen is given DirPerms::all() and FilePerms::READ without FilePerms::WRITE, this access control mechanism can be bypassed via the wasip2 descriptor.open-at or wasip1 path_open interfaces by opening a file with only the OpenFlags::TRUNCATE oflag. The root cause is that the clause handling OpenFlags::TRUNCATE in crates/wasi/src/filesystem.rs (Dir::open_at, lines 967–969) did not set open_mode |= OpenMode::WRITE;, which is later used for the access control check against FilePerms to determine whether opening the file is permitted; the single-line fix adds that missing assignment, after which the affected calls correctly fail with error-code.not-permitted and ERRNO_PERM respectively. Only wasmtime-wasi embeddings that combine DirPerms::MUTATE with FilePerms::READ are affected by this bug. In particular, the Wasmtime project's wasmtime-cli's use of wasmtime-wasi is not affected, because it always sets FilePerms::all() for all preopens. This issue has been fixed in versions 24.0.9, 36.0.10 and44.0.2.","state":0,"publishedAt":"2026-06-15T19:47:40.366+00:00","modifiedAt":"2026-06-16T12:46:04.26+00:00","affected":[{"ecosystem":"Vendor product","name":"wasmtime","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"bytecodealliance\",\n                    \"product\": \"wasmtime\",\n                    \"versions\": [\n                        {\n                            \"version\": \">= 37.0.0, < 44.0.2\",\n                            \"status\": \"affected\"\n                        },\n                        {\n                            \"version\": \">= 25.0.0, < 36.0.10\",\n                            \"status\": \"affected\"\n                        },\n                        {\n                            \"version\": \"< 24.0.9\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"severity":"HIGH"}],"references":["https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-2r75-cxrj-cmph","https://github.com/bytecodealliance/wasmtime/releases/tag/v24.0.9","https://github.com/bytecodealliance/wasmtime/releases/tag/v36.0.10","https://github.com/bytecodealliance/wasmtime/releases/tag/v44.0.2","https://github.com/bytecodealliance/wasmtime/releases/tag/v45.0.0"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-47261","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-47261","identifiers":["CVE-2026-47261"]},"retained":false,"historicalAffected":[]},{"revision":"b94b1a8027524be380c35efcf178ceab","observedAt":"2026-11-07T10:40:25.739+00:00","statement":{"source":"euvd","id":"EUVD-2026-37001","aliases":["CVE-2026-47261","GHSA-2r75-cxrj-cmph"],"title":"Wasmtime is a runtime for WebAssembly. In versions prior to 24.0.9, 36.0.10, and 44.0.2, when a filesystem preopen is given DirPerms::all() and FilePerms::READ without FilePerms::WRITE, this access control mechanism can be bypassed via the …","description":"Wasmtime is a runtime for WebAssembly. In versions prior to 24.0.9, 36.0.10, and 44.0.2, when a filesystem preopen is given DirPerms::all() and FilePerms::READ without FilePerms::WRITE, this access control mechanism can be bypassed via the wasip2 descriptor.open-at or wasip1 path_open interfaces by opening a file with only the OpenFlags::TRUNCATE oflag. The root cause is that the clause handling OpenFlags::TRUNCATE in crates/wasi/src/filesystem.rs (Dir::open_at, lines 967–969) did not set open_mode |= OpenMode::WRITE;, which is later used for the access control check against FilePerms to determine whether opening the file is permitted; the single-line fix adds that missing assignment, after which the affected calls correctly fail with error-code.not-permitted and ERRNO_PERM respectively. Only wasmtime-wasi embeddings that combine DirPerms::MUTATE with FilePerms::READ are affected by this bug. In particular, the Wasmtime project's wasmtime-cli's use of wasmtime-wasi is not affected, because it always sets FilePerms::all() for all preopens. This issue has been fixed in versions 24.0.9, 36.0.10 and44.0.2.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"severity":null}],"references":["https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-2r75-cxrj-cmph","https://github.com/bytecodealliance/wasmtime/releases/tag/v24.0.9","https://github.com/bytecodealliance/wasmtime/releases/tag/v36.0.10","https://github.com/bytecodealliance/wasmtime/releases/tag/v44.0.2","https://github.com/bytecodealliance/wasmtime/releases/tag/v45.0.0"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2026-37001","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"Jun 15, 2026, 7:47:40 PM","dateUpdated":"Jun 16, 2026, 12:46:04 PM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2026-37001","identifiers":["EUVD-2026-37001","CVE-2026-47261","GHSA-2r75-cxrj-cmph"]},"retained":false,"historicalAffected":[]},{"revision":"16c55c32bc0745c8b7638bea72ebcc13","observedAt":"2026-10-27T13:11:48.565+00:00","statement":{"source":"nvd","id":"CVE-2026-47261","aliases":[],"title":"Wasmtime is a runtime for WebAssembly. In versions prior to 24.0.9, 36.0.10, and 44.0.2, when a filesystem preopen is given DirPerms::all() and FilePerms::READ without FilePerms::WRITE, this access control mechanism can be bypassed via the …","description":"Wasmtime is a runtime for WebAssembly. In versions prior to 24.0.9, 36.0.10, and 44.0.2, when a filesystem preopen is given DirPerms::all() and FilePerms::READ without FilePerms::WRITE, this access control mechanism can be bypassed via the wasip2 descriptor.open-at or wasip1 path_open interfaces by opening a file with only the OpenFlags::TRUNCATE oflag. The root cause is that the clause handling OpenFlags::TRUNCATE in crates/wasi/src/filesystem.rs (Dir::open_at, lines 967–969) did not set open_mode |= OpenMode::WRITE;, which is later used for the access control check against FilePerms to determine whether opening the file is permitted; the single-line fix adds that missing assignment, after which the affected calls correctly fail with error-code.not-permitted and ERRNO_PERM respectively. Only wasmtime-wasi embeddings that combine DirPerms::MUTATE with FilePerms::READ are affected by this bug. In particular, the Wasmtime project's wasmtime-cli's use of wasmtime-wasi is not affected, because it always sets FilePerms::all() for all preopens. This issue has been fixed in versions 24.0.9, 36.0.10 and44.0.2.","state":0,"publishedAt":"2026-06-15T21:17:11.153+00:00","modifiedAt":"2026-10-25T23:10:00.167+00:00","affected":[],"metrics":[{"system":"CVSS 3.1 · security-advisories@github.com · Secondary","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":7.5,"severity":"HIGH"}],"references":["https://github.com/bytecodealliance/wasmtime/releases/tag/v24.0.9","https://github.com/bytecodealliance/wasmtime/releases/tag/v36.0.10","https://github.com/bytecodealliance/wasmtime/releases/tag/v44.0.2","https://github.com/bytecodealliance/wasmtime/releases/tag/v45.0.0","https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-2r75-cxrj-cmph"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-47261","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Analyzed","weaknesses":["CWE-284","NVD-CWE-noinfo"],"productCriteria":["cpe:2.3:a:bytecodealliance:wasmtime:*:*:*:*:*:rust:*:*"],"sourceDates":{"published":"2026-06-15T21:17:11.153","lastModified":"2026-10-25T23:10:00.167"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-47261","identifiers":["CVE-2026-47261"]},"retained":false,"historicalAffected":[]},{"revision":"2eb12311a9564de0bd7c2fd49f3584c4","observedAt":"2026-10-24T13:19:54.901+00:00","statement":{"source":"osv","id":"GHSA-2r75-cxrj-cmph","aliases":["CVE-2026-47261","RUSTSEC-2026-0149"],"title":"wasmtime-wasi: WASI path_open(TRUNCATE) bypasses `FilePerms::WRITE` host restriction","description":"## Summary\n\nIn `wasmtime-wasi`, when a filesystem preopen is given `DirPerms::all()` and `FilePerms::READ` without `FilePerms::WRITE`,  this wasmtime-wasi enforced access control mechanism can be bypassed by using the wasip2 `descriptor.open-at` or wasip1 `path_open` interfaces by opening a file with `OpenFlags::TRUNCATE` oflag only, for example:\n\n```rust\ndir_descriptor.open_at(\n   PathFlags::empty(),\n   FILENAME,\n   OpenFlags::TRUNCATE,\n   DescriptorFlags::READ,\n)\n```\n\n```rust\nwasip1::path_open(\n    dir_fd,\n    0,\n    FILENAME,\n    wasip1::OFLAGS_TRUNC,\n    wasip1::RIGHTS_FD_READ,\n    0,\n    0\n)\n```\n\nThe root cause is that the clause that considered `OpenFlags::TRUNCATE` did not set `open_mode |= OpenMode::WRITE;`, used later in that function for the access control check against `FilePerms` for whether opening that file is permitted. With the bug corrected, these calls to `open-at` and `path_open` fail with `error-code.not-permitted` and `ERRNO_PERM` respectively.\n\nThe bug in `crates/wasi/src/filesystem.rs`, `Dir::open_at`, lines 967–969:\n\n```rust\nif oflags.contains(OpenFlags::TRUNCATE) {\n    opts.truncate(true).write(true);\n}\n```\nand the single line fix is:\n```rust\nif oflags.contains(OpenFlags::TRUNCATE) {\n    opts.truncate(true).write(true);\n    open_mode |= OpenMode::WRITE;\n}\n```\n\nOnly wasmtime-wasi embeddings that use a combination of DirPerms::MUTATE with FilePerms::READ are affected by this bug, e.g. those that use in the `WasiCtxBuilder`:\n```rust\nbuilder.preopened_dir(\"readonly\", \"readonly\", DirPerms::READ | DirPerms::MUTATE, FilePerms::READ);\n```\n\nIn particular, the Wasmtime project's `wasmtime-cli`'s use of wasmtime-wasi is not affected, because it always sets `FilePerms::all()` for all preopens.","state":0,"publishedAt":"2026-06-05T15:47:02+00:00","modifiedAt":"2026-09-10T03:51:07.5202257+00:00","affected":[{"ecosystem":"crates.io","name":"wasmtime-wasi","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"37.0.0"},{"kind":"fixed","version":"44.0.2"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"crates.io","name":"wasmtime-wasi","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"25.0.0"},{"kind":"fixed","version":"36.0.10"}]}],"versions":[],"rawVersionEvidence":null},{"ecosystem":"crates.io","name":"wasmtime-wasi","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"24.0.9"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-2r75-cxrj-cmph","https://nvd.nist.gov/vuln/detail/CVE-2026-47261","https://github.com/bytecodealliance/wasmtime","https://github.com/bytecodealliance/wasmtime/releases/tag/v24.0.9","https://github.com/bytecodealliance/wasmtime/releases/tag/v36.0.10","https://github.com/bytecodealliance/wasmtime/releases/tag/v44.0.2","https://github.com/bytecodealliance/wasmtime/releases/tag/v45.0.0","https://rustsec.org/advisories/RUSTSEC-2026-0149.html"],"sourceUrl":"https://github.com/advisories/GHSA-2r75-cxrj-cmph","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-2r75-cxrj-cmph","identifiers":["GHSA-2r75-cxrj-cmph","CVE-2026-47261","RUSTSEC-2026-0149"]},"retained":false,"historicalAffected":[]},{"revision":"5ec30ba2e6c348df9c0f614db100504e","observedAt":"2026-10-24T13:19:54.901+00:00","statement":{"source":"osv","id":"RUSTSEC-2026-0149","aliases":["CVE-2026-47261","GHSA-2r75-cxrj-cmph"],"title":"WASI path_open(TRUNCATE) bypasses `FilePerms::WRITE` host restriction","description":"This is an entry in the RustSec database for the Wasmtime security advisory\nlocated at\nhttps://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-2r75-cxrj-cmph\nFor more information see the GitHub-hosted security advisory.","state":0,"publishedAt":"2026-05-21T12:00:00+00:00","modifiedAt":"2026-10-12T18:00:09.2366934+00:00","affected":[{"ecosystem":"crates.io","name":"wasmtime-wasi","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0.0.0-0"},{"kind":"fixed","version":"24.0.9"},{"kind":"introduced","version":"25.0.0"},{"kind":"fixed","version":"36.0.10"},{"kind":"introduced","version":"37.0.0"},{"kind":"fixed","version":"44.0.2"},{"kind":"introduced","version":"45.0.0"},{"kind":"fixed","version":"45.0.0"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N","score":null,"severity":null}],"references":["https://crates.io/crates/wasmtime-wasi","https://rustsec.org/advisories/RUSTSEC-2026-0149.html","https://github.com/bytecodealliance/wasmtime/pull/13429"],"sourceUrl":"https://osv.dev/vulnerability/RUSTSEC-2026-0149","license":"OSV · upstream source license applies","key":"osv:RUSTSEC-2026-0149","identifiers":["RUSTSEC-2026-0149","CVE-2026-47261","GHSA-2r75-cxrj-cmph"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-08T21:02:31.8931850+00:00","complete":true,"records":1769,"lastAttemptAt":"2026-11-08T21:02:31.893185+00:00","lastSuccessAt":"2026-11-08T21:02:32.2143877+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:32.2146388+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-eaa64dac63caa79c8d4905619258c41c51b39e461b996124e1a21b5e85e7e738-ea572f75aa62c370f36c9951285f437791ed77e310a361fa98b48744b8a4f391","complete":true,"records":421267,"lastAttemptAt":"2026-11-08T21:02:31.4333443+00:00","lastSuccessAt":"2026-11-08T20:47:19.8933196+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:31.4333443+00:00","snapshotPublishedAt":"2026-11-08T20:26:57+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-45d47722bca14f09ac26662adb699591","complete":true,"records":13654,"lastAttemptAt":"2026-11-08T21:02:36.7086981+00:00","lastSuccessAt":"2026-11-08T20:47:46.939+00:00","error":null,"lastVerifiedAt":"2026-11-08T20:47:46.939+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13706,"expectedIdentifiers":13706,"failedIdentifiers":0},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-08T21:02:31.8931850+00:00","complete":true,"records":1096,"lastAttemptAt":"2026-11-08T21:02:31.893185+00:00","lastSuccessAt":"2026-11-08T21:02:32.3894193+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:32.38942+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-ddc095a411c54633beb68aaff30b70cb","complete":true,"records":13666,"lastAttemptAt":"2026-11-08T21:02:34.4952279+00:00","lastSuccessAt":"2026-11-08T21:02:34.481+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:34.481+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13706,"expectedIdentifiers":13706,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-980593e6977a6d1b4fb1eed5a1ffe88a468736f89f0a06f710924ad59132c023","complete":true,"records":9914,"lastAttemptAt":"2026-11-08T21:02:31.7841816+00:00","lastSuccessAt":"2026-11-08T11:07:07.068788+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:31.7841816+00:00","snapshotPublishedAt":"2026-11-08T11:02:46+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-fde804134ecdda0ddd5ff5c26ee1fff5a6fa659311f7ef2e51c6ad54964db0e2","complete":true,"records":1971,"lastAttemptAt":"2026-11-08T21:02:31.5325642+00:00","lastSuccessAt":"2026-11-06T19:03:17.0399903+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:31.5325642+00:00","snapshotPublishedAt":"2026-11-06T18:17:57+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-964c14035e6f0f6478b2870fad6a7ef9f6045876d4a12af2c2e514521e54b6af","complete":true,"records":3055,"lastAttemptAt":"2026-11-08T21:02:31.8040207+00:00","lastSuccessAt":"2026-11-08T11:07:12.1927025+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:31.8040207+00:00","snapshotPublishedAt":"2026-11-08T11:02:46+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-f8647d7ba64b1ba0dfdc7130944766d5b36d5b77d18fff0c79e651a4cff3c2b9","complete":true,"records":231293,"lastAttemptAt":"2026-11-08T21:02:31.6506398+00:00","lastSuccessAt":"2026-11-08T11:06:56.2918717+00:00","error":null,"lastVerifiedAt":"2026-11-08T21:02:31.6506398+00:00","snapshotPublishedAt":"2026-11-08T11:02:50+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}