{"id":"CVE-2026-54552","published":"2026-08-18T17:37:40Z","modified":"2026-08-18T18:44:38Z","title":"sh _uid does not drop supplementary groups (incomplete privilege drop)","vendor":"amoffat","product":"sh","tier":"tail","description":{"text":"sh provides Python process launching. Prior to 2.2.4, the _uid option in sh.py performs an incomplete privilege drop on Linux and Unix-like systems. When sh runs from an elevated process and launches a command with _uid set to an unprivileged user, the child changes its UID but can retain the parent process's supplementary groups because the privilege-drop sequence does not fully establish the target user's UID, primary GID, and supplementary groups. The child can therefore retain access to files or resources granted to privileged groups such as root, docker, disk, shadow, or sudo, violating the expected _uid privilege boundary. This issue is fixed in version 2.2.4.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.9,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00169,"percentile":0.06478,"provenance":"source"},"cwes":[{"id":"CWE-273","name":"Improper Check for Dropped Privileges"}],"references":[{"url":"https://github.com/amoffat/sh/security/advisories/GHSA-q38v-wp89-2w55","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/amoffat/sh/pull/776","tags":["x_refsource_MISC"]},{"url":"https://github.com/amoffat/sh/commit/3d855daba91f87a089b490c0d1cf1df3faace2f1","tags":["x_refsource_MISC"]},{"url":"https://github.com/amoffat/sh/releases/tag/2.2.4","tags":["x_refsource_MISC"]}],"priority":{"score":6.8,"factors":[{"name":"EPSS percentile","points":1.3},{"name":"CVSS severity","points":5.53}]},"vendorSlug":"amoffat","affectedVersions":[{"vendor":"amoffat","product":"sh","versions":["< 2.2.4"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total","timestamp":"2026-08-18T18:44:23.350805Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"sh","vulnerableRanges":["<2.2.4"],"patched":["2.2.4"],"from":["GHSA-q38v-wp89-2w55","PYSEC-2026-3540"],"provenance":"source"}],"summary":{"text":"The sh Python process-launching library, prior to version 2.2.4, performs an incomplete privilege drop in its _uid option on Linux and Unix-like systems: the child process changes its UID but can retain the parent's supplementary groups, such as root, docker, disk, shadow, or sudo. An attacker with local access and high privileges in the calling process can exploit this when sh launches a command with _uid set to an unprivileged user, gaining access to files or resources reserved for those privileged groups, which violates the intended privilege boundary.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T22:14:12Z"},"euvd":{"id":"EUVD-2026-61127","exploited":false,"provenance":"source"}}