CVEFinder.io

CVE-2026-58092

⚠️ high
Summary

In FreeBSD 15.0, the kernel structure used to represent user credentials changed: previously the primary group ID was stored in the first element of the array containing the list of supplementary group IDs, whereas now the primary group ID is stored in a dedicated field. This change was largely internal to the kernel and not user-visible. One function, group_is_primary(), was not properly updated as a part of this transition. This function is used by mac_do to determine the primary group ID o

Description

In FreeBSD 15.0, the kernel structure used to represent user credentials changed: previously the primary group ID was stored in the first element of the array containing the list of supplementary group IDs, whereas now the primary group ID is stored in a dedicated field. This change was largely internal to the kernel and not user-visible.

One function, group_is_primary(), was not properly updated as a part of this transition. This function is used by mac_do to determine the primary group ID of the credential after applying a transition rule, used when the rule target does not explicitly specify a group.

As a result, with certain mac_do rules, it is possible for a credential switch to incorrectly set the primary group ID to the ID stored in the first element of the original credential's supplementary group array.

If the list of supplementary groups is empty, this value will be 0, corresponding to the "wheel" group. For example, a rule such as "uid=1001>uid=1002" can be abused to set the primary group ID to 0 even if the process did not originally belong to group 0.



Certain mac_do rules can be abused to set a process' group ID to 0. Note however, that the rule must apply to the caller in order for the bug to be triggered, e.g., given the ruleset "uid=1001>uid=1002", the user must have user ID 1001 in order to trigger the bug.

Further, logged-in users will in general have a non-empty supplementary group list, in which case the bug can at worst be used to set the credential's first supplementary group ID as its primary group ID. Processes must explicitly remove themselves from all supplementary groups, using the privileged setgroups(2) system call, in order to exploit the bug to set 0 as the primary group ID.

Since membership in group 0 is often used to enable controlled privilege escalation, the bug might be further exploitable to obtain root privileges, depending on the system configuration. For instance, a ruleset such as the following could be exploited by a process running as user 1001 and with an empty supplementary group list: "uid=1001>uid=1002;gid=0>uid=0".

CVSS Score
8.1
High
EPSS Score
0.4
Exploit Probability
Published Date
2026-08-26
First Seen: 2026-08-28
📊 Relative Risk Intelligence

This CVE is High Risk - more severe than 76.7% of all 365,890 vulnerabilities in our database.

#85,383
Top 25% most severe
Severity Percentile
🎯 CISA SSVC Assessment Updated: Aug 27, 2026
🔍 Exploitation Status
None
No known exploits
⚙️ Automatable
NO
Requires human interaction
💥 Technical Impact
Total
Complete system compromise possible
🏆 Discovered By
Hazley Samsudin of GovTech CSG
SSVC data provided by CISA
Last Modified 2026-09-24
Source NVD 🔗
CVSS Vector 3.1 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
CWE IDs (Weakness Types)

📦 Affected Products 2

🔗 References 1

🔗 Related CVEs 6

CVE ID Severity CVSS EPSS Summary Published
CVE-2026-58089 ⚠️ high 7.8 0.1 When a process calls execve(2) to execute a setuid or setgid image, hwpmc(4) is supposed to detach PMCs owned by unprivi... 2026-08-26
CVE-2026-58090 ⚠️ high 7.8 0.2 The SOCK_STREAM receive path in the unix socket implementation failed to fully detach control messages from the socket b... 2026-08-26
CVE-2026-58091 ⚠️ high 7.8 0.2 The implementation of this ioctl attempts to acquire locks on all channels in a sync group. If locking a channel would ... 2026-08-26
CVE-2026-58093 ⚠️ high 7.0 0.1 The TIOCSCTTY ioctl handler drops the tty lock in order to acquire the process tree lock. After reacquiring the tty loc... 2026-08-26
CVE-2026-58094 ⚠️ high 7.8 0.1 The FIOSSHMLPGCNF ioctl(2) operation configures the page size for a largepage shared memory object. This is intended to... 2026-08-26
CVE-2026-58095 ⚠️ high 8.8 0.6 mp_Enddisc() used incorrect length calculations when formatting endpoint discriminator addresses for display, allowing a... 2026-08-26
These CVEs affect the same products