{"id":"CVE-2025-5791","aliases":["CVE-2025-5791","GHSA-m65q-v92h-cm7q","RUSTSEC-2025-0040"],"related":[],"kind":"vulnerability","state":"published","title":"Users: `root` appended to group listings","summary":"A flaw was found in the user's crate for Rust. This vulnerability allows privilege escalation via incorrect group listing when a user or process has fewer than exactly 1024 groups, leading to the erroneous inclusion of the root group in the access list.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"A flaw was found in the user's crate for Rust. This vulnerability allows privilege escalation via incorrect group listing when a user or process has fewer than exactly 1024 groups, leading to the erroneous inclusion of the root group in the access list.","source":"cvelist"},{"lang":"en","text":"Affected versions append `root` to group listings, unless the correct listing has exactly 1024 groups.\n\nThis affects both:\n\n- The supplementary groups of a user\n- The group access list of the current process\n\nIf the caller uses this information for access control, this may lead to privilege escalation.\n\nThis crate is not currently maintained, so a patched version is not available.\n\nVersions older than 0.8.0 do not contain the affected functions, so downgrading to them is a workaround.\n\n## Recommended alternatives\n- [`uzers`](https://crates.io/crates/uzers) (an actively maintained fork of the `users` crate)\n- [`sysinfo`](https://crates.io/crates/sysinfo)","format":"markdown","source":"ghsa"},{"lang":"es","text":"Se encontró una falla en el crate del usuario para Rust. Esta vulnerabilidad permite la escalada de privilegios mediante una lista de grupos incorrecta cuando un usuario o proceso tiene menos de exactamente 1024 grupos, lo que provoca la inclusión errónea del grupo raíz en la lista de acceso.","source":"nvd"}],"published":"2025-01-15T12:00:00.000Z","modified":"2026-11-23T16:17:23.567Z","severity":{"scorer":"redhat","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N","score":7.1,"rating":"HIGH"},"severities":[{"scorer":"redhat","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N","score":7.1,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N","score":7.1,"rating":"HIGH"}],"cwes":["CWE-266"],"affected":[{"ranges":[{"type":"semver","introduced":"0.8.0","fixed":"0.11.1","status":"affected"}],"package":"rust-users","source":"cvelist"},{"ranges":[{"type":"rpm","introduced":"1.10-1753885668","fixed":"*","status":"unaffected"}],"vendor":"Red Hat","product":"Red Hat OpenShift sandboxed containers 1.10","package":"openshift-sandboxed-containers/osc-rhel9-operator","cpe":"cpe:/a:redhat:confidential_compute_attestation:1.10::el9","source":"cvelist"},{"ranges":[],"vendor":"Red Hat","product":"Red Hat Enterprise Linux 10","package":"rust-ssh-key-dir","cpe":"cpe:/o:redhat:enterprise_linux:10","source":"cvelist"},{"ranges":[],"vendor":"Red Hat","product":"Red Hat Enterprise Linux 9","package":"rust-afterburn","cpe":"cpe:/o:redhat:enterprise_linux:9","source":"cvelist"},{"ranges":[],"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4","package":"kata-containers","cpe":"cpe:/a:redhat:openshift:4","source":"cvelist"},{"ranges":[],"vendor":"Red Hat","product":"Red Hat OpenShift Container Platform 4","package":"rust-afterburn","cpe":"cpe:/a:redhat:openshift:4","source":"cvelist"},{"ranges":[],"vendor":"Red Hat","product":"Red Hat Trusted Profile Analyzer","package":"rhtpa/rhtpa-trustification-service-rhel9","cpe":"cpe:/a:redhat:trusted_profile_analyzer:1","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0.8.0","status":"affected","lastAffected":"0.11.0"}],"ecosystem":"crates.io","package":"users","purl":"pkg:cargo/users","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.8.0","status":"affected"}],"ecosystem":"crates.io","package":"users","purl":"pkg:cargo/users","source":"rustsec"}],"references":[{"url":"https://access.redhat.com/errata/RHSA-2025:12359","tags":["vendor-advisory","x-refsource-redhat"],"sources":["cvelist","nvd"]},{"url":"https://access.redhat.com/security/cve/CVE-2025-5791","tags":["vdb-entry","web","x-refsource-redhat"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2370001","tags":["issue-tracking","web","x-refsource-redhat"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://crates.io/crates/users","tags":["package"],"sources":["cvelist","rustsec","nvd"]},{"url":"https://github.com/ogham/rust-users/issues/44","tags":["report","web"],"sources":["cvelist","ghsa","rustsec","nvd"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2025-0040.html","tags":["advisory","web"],"sources":["cvelist","ghsa","rustsec","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-5791","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/ogham/rust-users","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"redhat","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2025-06-06T13:40:43.009Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-5791","url":"https://www.cve.org/CVERecord?id=CVE-2025-5791","licence":"CVE Terms of Use","modified":"2026-11-23T15:20:19.411Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-m65q-v92h-cm7q","url":"https://github.com/advisories/GHSA-m65q-v92h-cm7q","licence":"CC-BY-4.0","modified":"2026-09-10T03:50:57.706Z"},{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2025-0040","url":"https://rustsec.org/advisories/RUSTSEC-2025-0040.html","licence":"CC0-1.0","modified":"2025-10-28T06:28:57.282Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-5791","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-5791","licence":"Public domain","modified":"2026-11-23T16:17:23.567Z"}],"updatedAt":"2026-11-25T22:58:58.883Z","epss":{"score":0.00205,"percentile":0.11154,"date":"2026-12-01T12:00:22.000Z"}}