{"id":"CVE-2025-47737","aliases":["EUVD-2025-14091","GHSA-6x45-r4pr-5362","RUSTSEC-2025-0163"],"status":"published","title":"trailer mishandles allocating with a size of zero","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","severity":{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.00562,"percentile":0.46996,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":false},"cwes":["CWE-762"],"published":"2025-05-04T12:00:00Z","modified":"2026-10-28T02:30:27Z","affected":[{"source":"ghsa","ecosystem":"crates.io","package":"trailer","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"0.1.2"}]}]},{"source":"osv","ecosystem":"crates.io","package":"trailer","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"last_affected":"0.1.2"}]}]},{"source":"osv","ecosystem":"crates.io","package":"trailer","ranges":[{"type":"SEMVER","events":[{"introduced":"0.0.0-0"}]}]}],"products":[{"vendor":"geal","product":"trailer"},{"vendor":"unhandledexpression","product":"trailer"}],"references":[{"url":"https://github.com/Geal/trailer/issues/2","tags":["exploit","Exploit","Issue Tracking","report","web"]},{"url":"https://crates.io/crates/trailer","tags":["Product","web","package"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-47737","tags":["advisory"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2025-0163.html","tags":["web","advisory"]},{"url":"https://github.com/advisories/GHSA-6x45-r4pr-5362"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/47xxx/CVE-2025-47737.json","tags":["advisory"]},{"url":"https://github.com/Geal/trailer","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2025-47737","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T00:00:00Z","modified":"2025-05-09T15:54:31.213Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low","assessor":"cna"}],"cwes":["CWE-762"],"updated_at":"2026-11-02T14:32:26.320248Z"}],"euvd":[{"id":"EUVD-2025-14091","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T00:00:00Z","modified":"2025-05-09T15:54:31Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low"}],"updated_at":"2026-11-02T20:32:50.734545Z"}],"ghsa":[{"id":"GHSA-6x45-r4pr-5362","title":"trailer mishandles allocating with a size of zero","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T06:32:36Z","modified":"2026-06-09T11:57:43Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low"}],"cwes":["CWE-762"],"updated_at":"2026-11-02T14:40:23.739691Z"}],"nvd":[{"id":"CVE-2025-47737","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T05:15:51.877Z","modified":"2026-06-17T09:28:37.83Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low","assessor":"secondary"},{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"primary"}],"cwes":["CWE-762"],"updated_at":"2026-11-02T14:11:06.085152Z"}],"osv":[{"id":"CVE-2025-47737","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T00:00:00Z","modified":"2026-10-28T02:30:27.833492314Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low"}],"cwes":["CWE-762"],"updated_at":"2026-11-02T15:44:49.707645Z"},{"id":"GHSA-6x45-r4pr-5362","title":"trailer mishandles allocating with a size of zero","description":"lib.rs in the trailer crate through 0.1.2 for Rust mishandles allocating with a size of zero.","status":"published","published":"2025-05-09T06:32:36Z","modified":"2026-06-09T12:00:11.697474009Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low"}],"cwes":["CWE-762"],"updated_at":"2026-11-02T15:46:40.308826Z"},{"id":"RUSTSEC-2025-0163","title":"Unsound issue in Trailer","description":"Our static analyzer find a potential unsound issue\nin the construction of Trailer, where it doesn't\nprovide enough check to ensure the soundness.\n\ntrailer/src/lib.rs, Lines 18 to 25 in d474984:\n```\n pub fn new(capacity: usize) -\u003e Trailer\u003cT\u003e { \n     unsafe { \n         let trailer = Trailer::allocate(capacity); \n         let ptr = trailer.ptr as *mut T; \n         ptr.write(T::default()); \n         trailer \n     } \n } \n```\n\nThe constructor does not check the T is not a ZST in\nrust, and allocating with size 0 is considered\nas undefined behaviors in Rust. A poc code like\nbelow can work:\n\n```\nuse trailer::Trailer;\n#[derive(Default)]\nstruct Zst;\n\nfn main() {\n    let mut a = Trailer::\u003cZst\u003e::new(0);\n    drop(a);\n}\n```\n\nThe trailer crate is unmaintained and this security issue\nwill not be fixed.","status":"published","published":"2025-05-04T12:00:00Z","modified":"2026-06-10T06:13:29Z","cvss":[{"version":"3.1","score":2.9,"vector":"CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"low"}],"updated_at":"2026-11-02T15:53:40.430679Z"}]}}
