{"api_version":"1","generated_at":"2026-05-06T03:18:14+00:00","cve":"CVE-2023-27477","urls":{"html":"https://cve.report/CVE-2023-27477","api":"https://cve.report/api/cve/CVE-2023-27477.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2023-27477","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2023-27477"},"summary":{"title":"CVE-2023-27477","description":"wasmtime is a fast and secure runtime for WebAssembly. Wasmtime's code generation backend, Cranelift, has a bug on x86_64 platforms for the WebAssembly `i8x16.select` instruction which will produce the wrong results when the same operand is provided to the instruction and some of the selected indices are greater than 16. There is an off-by-one error in the calculation of the mask to the `pshufb` instruction which causes incorrect results to be returned if lanes are selected from the second vector. This codegen bug has been fixed in Wasmtiem 6.0.1, 5.0.1, and 4.0.1. Users are recommended to upgrade to these updated versions. If upgrading is not an option for you at this time, you can avoid this miscompilation by disabling the Wasm simd proposal. Additionally the bug is only present on x86_64 hosts. Other platforms such as AArch64 and s390x are not affected.","state":"PUBLIC","assigner":"security-advisories@github.com","published_at":"2023-03-08 21:15:00","updated_at":"2023-03-15 16:56:00"},"problem_types":["CWE-193"],"metrics":[],"references":[{"url":"https://docs.rs/wasmtime/latest/wasmtime/struct.Config.html#method.wasm_simd","name":"https://docs.rs/wasmtime/latest/wasmtime/struct.Config.html#method.wasm_simd","refsource":"MISC","tags":[],"title":"Config in wasmtime - Rust","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://groups.google.com/a/bytecodealliance.org/g/sec-announce/c/Mov-ItrNJsQ","name":"https://groups.google.com/a/bytecodealliance.org/g/sec-announce/c/Mov-ItrNJsQ","refsource":"MISC","tags":[],"title":"Upcoming security release for Wasmtime","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/bytecodealliance/wasmtime/commit/5dc2bbccbb363e474d2c9a1b8e38a89a43bbd5d1","name":"https://github.com/bytecodealliance/wasmtime/commit/5dc2bbccbb363e474d2c9a1b8e38a89a43bbd5d1","refsource":"MISC","tags":[],"title":"Merge pull request from GHSA-xm67-587q-r2vw · bytecodealliance/wasmtime@5dc2bbc · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/webassembly/simd","name":"https://github.com/webassembly/simd","refsource":"MISC","tags":[],"title":"GitHub - WebAssembly/simd: Branch of the spec repo scoped to discussion of SIMD in WebAssembly","mime":"text/html","httpstatus":"200","archivestatus":"200"},{"url":"https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-xm67-587q-r2vw","name":"https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-xm67-587q-r2vw","refsource":"MISC","tags":[],"title":"Miscompilation of `i8x16.select` with the same inputs on x86_64 · Advisory · bytecodealliance/wasmtime · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://www.cve.org/CVERecord?id=CVE-2023-27477","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-27477","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"cranelift-codegen","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"},{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"cranelift-codegen","cpe6":"0.92.0","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"},{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"cranelift-codegen","cpe6":"0.93.0","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"},{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"wasmtime","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"},{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"wasmtime","cpe6":"5.0.0","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"},{"cve_year":"2023","cve_id":"27477","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"bytecodealliance","cpe5":"wasmtime","cpe6":"6.0.0","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"rust","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[{"cve":"CVE-2023-27477","qid":"906925","title":"Common Base Linux Mariner (CBL-Mariner) Security Update for rust (25857-1)"},{"cve":"CVE-2023-27477","qid":"996226","title":"Rust (Rust) Security Update for cranelift-codegen (GHSA-xm67-587q-r2vw)"}]},"source_records":{"cve_program":{"data_version":"4.0","data_type":"CVE","data_format":"MITRE","CVE_data_meta":{"ID":"CVE-2023-27477","ASSIGNER":"security-advisories@github.com","STATE":"PUBLIC"},"description":{"description_data":[{"lang":"eng","value":"wasmtime is a fast and secure runtime for WebAssembly. Wasmtime's code generation backend, Cranelift, has a bug on x86_64 platforms for the WebAssembly `i8x16.select` instruction which will produce the wrong results when the same operand is provided to the instruction and some of the selected indices are greater than 16. There is an off-by-one error in the calculation of the mask to the `pshufb` instruction which causes incorrect results to be returned if lanes are selected from the second vector. This codegen bug has been fixed in Wasmtiem 6.0.1, 5.0.1, and 4.0.1. Users are recommended to upgrade to these updated versions. If upgrading is not an option for you at this time, you can avoid this miscompilation by disabling the Wasm simd proposal. Additionally the bug is only present on x86_64 hosts. Other platforms such as AArch64 and s390x are not affected."}]},"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-193: Off-by-one Error","cweId":"CWE-193"}]}]},"affects":{"vendor":{"vendor_data":[{"vendor_name":"bytecodealliance","product":{"product_data":[{"product_name":"wasmtime","version":{"version_data":[{"version_affected":"=","version_value":"cranelift-codegen: >= 0.88.0, < 0.91.1"},{"version_affected":"=","version_value":"cranelift-codegen: >= 0.92.0, < 0.92.1"},{"version_affected":"=","version_value":"cranelift-codegen: >= 0.93.0, < 0.93.1"},{"version_affected":"=","version_value":" wasmtime: >= 0.37.0, < 4.0.1"},{"version_affected":"=","version_value":" wasmtime: >= 5.0.0, < 5.0.1"},{"version_affected":"=","version_value":" wasmtime: >= 6.0.0, < 6.0.1"}]}}]}}]}},"references":{"reference_data":[{"url":"https://docs.rs/wasmtime/latest/wasmtime/struct.Config.html#method.wasm_simd","refsource":"MISC","name":"https://docs.rs/wasmtime/latest/wasmtime/struct.Config.html#method.wasm_simd"},{"url":"https://github.com/webassembly/simd","refsource":"MISC","name":"https://github.com/webassembly/simd"},{"url":"https://groups.google.com/a/bytecodealliance.org/g/sec-announce/c/Mov-ItrNJsQ","refsource":"MISC","name":"https://groups.google.com/a/bytecodealliance.org/g/sec-announce/c/Mov-ItrNJsQ"},{"url":"https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-xm67-587q-r2vw","refsource":"MISC","name":"https://github.com/bytecodealliance/wasmtime/security/advisories/GHSA-xm67-587q-r2vw"},{"url":"https://github.com/bytecodealliance/wasmtime/commit/5dc2bbccbb363e474d2c9a1b8e38a89a43bbd5d1","refsource":"MISC","name":"https://github.com/bytecodealliance/wasmtime/commit/5dc2bbccbb363e474d2c9a1b8e38a89a43bbd5d1"}]},"source":{"advisory":"GHSA-xm67-587q-r2vw","discovery":"UNKNOWN"},"impact":{"cvss":[{"attackComplexity":"HIGH","attackVector":"NETWORK","availabilityImpact":"NONE","baseScore":3.1,"baseSeverity":"LOW","confidentialityImpact":"NONE","integrityImpact":"LOW","privilegesRequired":"LOW","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:N/I:L/A:N","version":"3.1"}]}},"nvd":{"publishedDate":"2023-03-08 21:15:00","lastModifiedDate":"2023-03-15 16:56:00","problem_types":["CWE-193"],"metrics":{"baseMetricV3":{"cvssV3":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"NONE","integrityImpact":"LOW","availabilityImpact":"NONE","baseScore":4.3,"baseSeverity":"MEDIUM"},"exploitabilityScore":2.8,"impactScore":1.4}},"configurations":{"CVE_data_version":"4.0","nodes":[{"operator":"OR","children":[],"cpe_match":[{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:wasmtime:6.0.0:*:*:*:*:rust:*:*","cpe_name":[]},{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:wasmtime:5.0.0:*:*:*:*:rust:*:*","cpe_name":[]},{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:wasmtime:*:*:*:*:*:rust:*:*","versionStartIncluding":"0.37.0","versionEndExcluding":"4.0.1","cpe_name":[]},{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:cranelift-codegen:0.93.0:*:*:*:*:rust:*:*","cpe_name":[]},{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:cranelift-codegen:0.92.0:*:*:*:*:rust:*:*","cpe_name":[]},{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:bytecodealliance:cranelift-codegen:*:*:*:*:*:rust:*:*","versionStartIncluding":"0.84.0","versionEndExcluding":"0.91.1","cpe_name":[]}]}]}},"legacy_mitre":{"record":null,"notes":[]}}}