Every CVE Search/ Get API key

CVE-2026-35339

uutils coreutils chmod False Success Exit Code in Recursive Mode

5.5 MediumFix available

CVE-2026-35339 is a medium vulnerability (CVSS 5.5) in Uutils Coreutils, published April 22, 2026. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.14%, the 3rd percentile. Fixed in uu_chmod 0.6.0.

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Attack profile

How easy it is to exploit

Attack vector
Local
Complexity
Low
Privileges needed
Low
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
High
Availability
None

Exploit likelihood

0.14%Up 0.1 points since Apr 23, 2026
90%50%10%1%

What each source reports

CVE List Score used 5.5

uutils coreutils chmod False Success Exit Code in Recursive Mode

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
CVE-2026-35339
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-253
Updated
2026-11-02
EUVDEUVD-2026-24965 5.5

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
EUVD-2026-24965
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Updated
2026-11-02
GitHub AdvisoriesGHSA-4x34-chg5-mwjj 5.5

chmod: recursive mode returns exit code 0 even when some files fail (last-file-wins)

In Chmoder::chmod() the recursive branch overwrites the running result instead of accumulating it, so the exit code reflects only the last file processed:

if self.recursive {
    r = self.walk_dir_with_context(file, true);   // overwrites r
} else {
    r = self.chmod_file(file).and(r);
}

PoC: GNU returns 1 when a file fails; uutils returns 0 if the last entry succeeds:

$ chmod -R 0755 chmod-bug/root chmod-bug/user  # GNU -> ret=1
$ uutils chmod -R 0755 chmod-bug/root chmod-bug/user  # -> ret=0

Impact: scripts relying on the exit code get a false success signal while some files retained restrictive/unexpected permissions, leading to access-control misconfigurations. Recommendation: accumulate errors during traversal.

Remediation: Acknowledged by Canonical; fixed in commit abd581f6.


Reported by Zellic in the uutils coreutils Program Security Assessment (prepared for Canonical, Jan 20 2026), audited commit 3a07ffc5a9bd4c283e75afa548ba1f1957bad242. Finding 3.2. Credit: Zellic.

Record
GHSA-4x34-chg5-mwjj
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-252, CWE-253, CWE-755
Updated
2026-11-02
GitHub AdvisoriesGHSA-vp6q-mv9j-j428 5.5

Duplicate Advisory: uutils coreutils incorrectly handles exit codes when processing multiple files

Duplicate Advisory

This advisory has been withdrawn because it is a duplicate of GHSA-4x34-chg5-mwjj. This link is maintained to preserve external references.

Original Description

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
GHSA-vp6q-mv9j-j428
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-253
Updated
2026-11-02
NVD 5.5

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
CVE-2026-35339
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-253
Updated
2026-11-02
OSV 5.5

uutils coreutils chmod False Success Exit Code in Recursive Mode

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
CVE-2026-35339
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-253
Updated
2026-11-02
Show 4 moreShow less
OSVDEBIAN-CVE-2026-35339 5.5

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
DEBIAN-CVE-2026-35339
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Updated
2026-11-02
OSVGHSA-4x34-chg5-mwjj 5.5

chmod: recursive mode returns exit code 0 even when some files fail (last-file-wins)

In Chmoder::chmod() the recursive branch overwrites the running result instead of accumulating it, so the exit code reflects only the last file processed:

if self.recursive {
    r = self.walk_dir_with_context(file, true);   // overwrites r
} else {
    r = self.chmod_file(file).and(r);
}

PoC: GNU returns 1 when a file fails; uutils returns 0 if the last entry succeeds:

$ chmod -R 0755 chmod-bug/root chmod-bug/user  # GNU -> ret=1
$ uutils chmod -R 0755 chmod-bug/root chmod-bug/user  # -> ret=0

Impact: scripts relying on the exit code get a false success signal while some files retained restrictive/unexpected permissions, leading to access-control misconfigurations. Recommendation: accumulate errors during traversal.

Remediation: Acknowledged by Canonical; fixed in commit abd581f6.


Reported by Zellic in the uutils coreutils Program Security Assessment (prepared for Canonical, Jan 20 2026), audited commit 3a07ffc5a9bd4c283e75afa548ba1f1957bad242. Finding 3.2. Credit: Zellic.

Record
GHSA-4x34-chg5-mwjj
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-252, CWE-253, CWE-755
Updated
2026-11-02
OSVGHSA-vp6q-mv9j-j428 5.5

Duplicate Advisory: uutils coreutils incorrectly handles exit codes when processing multiple files

Duplicate Advisory

This advisory has been withdrawn because it is a duplicate of GHSA-4x34-chg5-mwjj. This link is maintained to preserve external references.

Original Description

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
GHSA-vp6q-mv9j-j428
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Weakness
CWE-253
Updated
2026-11-02
OSVUBUNTU-CVE-2026-35339 5.5

The recursive mode (-R) of the chmod utility in uutils coreutils incorrectly handles exit codes when processing multiple files. The final return value is determined solely by the success or failure of the last file processed. This allows the command to return an exit code of 0 (success) even if errors were encountered on previous files, such as 'Operation not permitted'. Scripts relying on these exit codes may proceed under a false sense of success while sensitive files remain with restrictive or incorrect permissions.

Record
UBUNTU-CVE-2026-35339
CVSS 3.1
5.5 MediumCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
uu_chmod
crates.io
before 0.6.0
0.6.0
rust-coreutils
Debian:12
All versions, plus listed versions
0.0.17-20.0.17-30.0.17-40.0.17-50.0.17-6
Show 39 moreShow less
0.0.19-10.0.19-20.0.19-30.0.20-10.0.21-10.0.22-10.0.23-10.0.23-20.0.23-30.0.24-10.0.24-20.0.26-10.0.26-20.0.26-30.0.26-40.0.26-50.0.27-10.0.27-20.0.27-30.0.30-10.0.30-20.0.30-30.0.30-3~exp10.0.30-40.10.0-10.11.0-10.11.0-20.12.0-10.6.0-10.7.0-10.8.0-10.8.0-20.8.0-30.8.0-40.8.0-50.8.0-60.9.0-10.9.0-20.9.0-3
None known
rust-coreutils
Debian:13
All versions, plus listed versions
0.0.30-20.0.30-30.0.30-3~exp10.0.30-40.10.0-1
Show 14 moreShow less
0.11.0-10.11.0-20.12.0-10.6.0-10.7.0-10.8.0-10.8.0-20.8.0-30.8.0-40.8.0-50.8.0-60.9.0-10.9.0-20.9.0-3
None known
rust-coreutils
Debian:14
before 0.6.0-1, plus listed versions
0.0.30-20.0.30-30.0.30-3~exp10.0.30-4
0.6.0-1
rust-coreutils
Ubuntu:24.04:LTS
All versions, plus listed versions
0.0.20-10.0.22-10.0.23-10.0.23-20.0.23-30.0.24-10.0.24-2
None known
rust-coreutils
Ubuntu:25.10
All versions, plus listed versions
0.0.30-10.0.30-20.0.30-2ubuntu20.1.0-0ubuntu10.1.0+git20250711.2ba3a33-0ubuntu1
Show 11 moreShow less
0.1.0+git20250711.2ba3a33-0ubuntu20.1.0+git20250711.2ba3a33-0ubuntu30.1.0+git20250711.2ba3a33-0ubuntu40.1.0+git20250801.cf79675-0ubuntu10.1.0+git20250813.4af2a84-0ubuntu20.1.0+git20250813.4af2a84-0ubuntu40.1.0+git20250813.4af2a84-0ubuntu60.1.0+git20250813.4af2a84-0ubuntu70.2.2-0ubuntu10.2.2-0ubuntu20.2.2-0ubuntu2.1
None known

History

History
WhenChangedSources
2026-11-03affected
2026-11-02createdCVE List, EUVD, GitHub Advisories, NVD, OSV

References

Show 7 moreShow less
MoveEnter Open