Description
A flaw was found in shadow-utils. The newgidmap and newuidmap utilities validate that a caller-supplied file descriptor refers to a directory on the /proc filesystem by comparing device numbers, then open a file by name relative to that directory to write privileged group/user ID mapping data. A local, unprivileged user can use Linux user and mount namespaces to bind-mount an attacker-chosen file over the expected path, defeating the device-number check and causing the helper to overwrite the first five bytes of the attacker-chosen file with fixed content.
Vendor workaround
Disabling the creation of unprivileged user namespaces (for example, by setting the sysctl user.max_user_namespaces to 0) prevents the creation of the namespaces required to carry out this attack. This can affect functionality that relies on unprivileged user namespaces, such as rootless containers, so it should be tested before being applied broadly. Red Hat Enterprise Linux 10 is not expected to require this mitigation, since newgidmap and newuidmap are not installed setuid-root on these releases.
Original text from the vendor's CVE record.
Affected products and versions
CVSS vector, explained
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:L
- Attack vector
- Local
- Attack complexity
- Low
- Privileges required
- Regular user
- User interaction
- Not required
- Scope
- Vulnerable component only
- Confidentiality
- None
- Integrity
- Low impact
- Availability
- Low impact
Weakness type (CWE)
- CWE-59 Improper Link Resolution Before File Access
References
- access.redhat.com/security/cve/CVE-2026-135901
- bugzilla.redhat.com/show_bug.cgi?id=2583156
- github.com/shadow-maint/shadow/releases/tag/4.20.4
Sources: CVE.org (CNA and CISA ADP), CISA KEV, FIRST EPSS. Always check the vendor's official advisory.