{"id":"CVE-2020-35921","aliases":["CVE-2020-35921","GHSA-jrcf-4jp8-m28v","RUSTSEC-2020-0080"],"related":[],"kind":"vulnerability","state":"published","title":"miow invalidly assumes the memory layout of std::net::SocketAddr","summary":"An issue was discovered in the miow crate before 0.3.6 for Rust. It has false expectations about the std::net::SocketAddr memory representation.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"An issue was discovered in the miow crate before 0.3.6 for Rust. It has false expectations about the std::net::SocketAddr memory representation.","source":"cvelist"},{"lang":"en","text":"The miow crate has assumed std::net::SocketAddrV4 and std::net::SocketAddrV6 have the same memory layout as the system C representation sockaddr. It has simply casted the pointers to convert the socket addresses to the system representation. The standard library does not say anything about the memory layout, and this will cause invalid memory access if the standard library changes the implementation. No warnings or errors will be emitted once the change happens.","format":"markdown","source":"ghsa"},{"lang":"en","text":"The [`miow`](https://crates.io/crates/miow) crate has assumed `std::net::SocketAddrV4`\nand `std::net::SocketAddrV6` have the same memory layout as the system C representation\n`sockaddr`. It has simply casted the pointers to convert the socket addresses to the\nsystem representation. The standard library does not say anything about the memory\nlayout, and this will cause invalid memory access if the standard library\nchanges the implementation. No warnings or errors will be emitted once the\nchange happens.","format":"markdown","source":"rustsec"},{"lang":"es","text":"Se detectó un problema en la crate miow versiones anteriores a 0.3.6 para Rust.&#xa0;Presenta falsas expectativas sobre la representación de la memoria de la función std::net::SocketAddr.","source":"nvd"}],"published":"2020-11-13T12:00:00.000Z","modified":"2026-06-17T03:14:36.610Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},{"scorer":"RustSec Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:L/AC:L/Au:N/C:N/I:N/A:P","score":2.1,"rating":"LOW"}],"cwes":["CWE-188"],"affected":[{"ranges":[{"version":"n/a","status":"affected"}],"source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0.3.0","status":"affected","fixed":"0.3.6"}],"ecosystem":"crates.io","package":"miow","purl":"pkg:cargo/miow","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.0.0-0","status":"affected","fixed":"0.2.2"},{"type":"semver","introduced":"0.3.0-0","status":"affected","fixed":"0.3.6"}],"ecosystem":"crates.io","package":"miow","purl":"pkg:cargo/miow","source":"rustsec"},{"ranges":[{"status":"affected","fixed":"0.2.2"},{"status":"affected","introduced":"0.3.0","fixed":"0.3.6"}],"vendor":"miow_project","product":"miow","cpe":"cpe:2.3:a:miow_project:miow:*:*:*:*:*:rust:*:*","source":"nvd"}],"references":[{"url":"https://rustsec.org/advisories/RUSTSEC-2020-0080.html","tags":["advisory","exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","rustsec","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2020-35921","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/yoshuawuyts/miow/issues/38","tags":["report","web"],"sources":["ghsa","rustsec"]},{"url":"https://github.com/yoshuawuyts/miow/pull/39","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/yoshuawuyts/miow/pull/40","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/yoshuawuyts/miow","tags":["package"],"sources":["ghsa"]},{"url":"https://crates.io/crates/miow","tags":["package"],"sources":["rustsec"]}],"credits":[],"assigner":"mitre","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2020-35921","url":"https://www.cve.org/CVERecord?id=CVE-2020-35921","licence":"CVE Terms of Use","modified":"2024-08-04T17:16:13.252Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-jrcf-4jp8-m28v","url":"https://github.com/advisories/GHSA-jrcf-4jp8-m28v","licence":"CC-BY-4.0","modified":"2023-11-08T04:03:39.469Z"},{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2020-0080","url":"https://rustsec.org/advisories/RUSTSEC-2020-0080.html","licence":"CC0-1.0","modified":"2023-11-08T04:03:39.469Z"},{"source":"nvd","name":"NVD","id":"CVE-2020-35921","url":"https://nvd.nist.gov/vuln/detail/CVE-2020-35921","licence":"Public domain","modified":"2026-06-17T03:14:36.610Z"}],"updatedAt":"2026-11-25T22:57:56.657Z","epss":{"score":0.00395,"percentile":0.35828,"date":"2026-12-01T12:00:22.000Z"}}