CVE-2026-58094

TOCTOU race in POSIX shared memory large page configuration

Published Aug 26, 2026 CVSS 3.1 · 7.8 High EPSS < 1% KEV · Not listed
Description
The FIOSSHMLPGCNF ioctl(2) operation configures the page size for a largepage shared memory object. This is intended to be used immediately after creating the object, before any memory is allocated for the object. The handler checked whether a page size had already been configured without holding the rangelock. Two concurrent callers could both observe an unconfigured object and set conflicting page sizes, leaving the object in an inconsistent state.

An unprivileged local user can exploit this race to escalate privileges.

Analysis

AI-generated

Technical impact

The ioctl operation used to configure a largepage shared memory object checks for an existing configuration without holding the necessary lock. This race condition allows two concurrent users to see an unconfigured object and set conflicting page sizes, leaving the object in an inconsistent state. The inconsistency can be exploited by an unprivileged local user to gain elevated privileges through manipulation of the shared memory mapping.

Affected Systems

This flaw affects the FreeBSD implementation of POSIX shared memory, specifically the FIOSSHMLPGCNF ioctl defined in the kernel. No version range is given, so all FreeBSD releases that expose this ioctl without the lock fix are vulnerable until a patch is applied.

Risk and Exploitability

The vulnerability is local in nature: it requires an attacker to be able to invoke the ioctl from an unprivileged account on the same system. Because the race can be triggered by two concurrent operations, the exploitation requires precise timing but is otherwise straightforward for a local attacker. The EPSS score is < 1%, and the CVSS score is 7.8. Nevertheless, the potential for privilege escalation categorizes the risk as significant. Attackers should be aware that the absence of a lock may allow privilege escalation if the race is successfully triggered.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply the latest FreeBSD security patch that addresses the race condition in the shared memory ioctl.
  • Verify that the fio shm size configuration is performed immediately after object creation and before any memory is allocated, ensuring no further concurrent configuration attempts.
  • Limit the use of the shared memory ioctl to privileged users by adjusting file system permissions or implementing system‑wide security policies that restrict unprivileged access to shared memory objects.

Generated by OpenCVE AI on August 26, 2026 at 20:46 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
CPEs cpe:2.3:o:freebsd:freebsd:14.4:p1:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p2:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p3:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p4:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p5:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p6:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p7:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:14.4:p8:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p10:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p11:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p12:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p1:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p2:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p3:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p4:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p5:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p6:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p7:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p8:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.0:p9:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.1:p1:*:*:*:*:*:*
cpe:2.3:o:freebsd:freebsd:15.1:p2:*:*:*:*:*:*
Type Values Removed Values Added
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H'}

ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Freebsd
Freebsd freebsd
Vendors & Products Freebsd
Freebsd freebsd
Type Values Removed Values Added
Description The FIOSSHMLPGCNF ioctl(2) operation configures the page size for a largepage shared memory object. This is intended to be used immediately after creating the object, before any memory is allocated for the object. The handler checked whether a page size had already been configured without holding the rangelock. Two concurrent callers could both observe an unconfigured object and set conflicting page sizes, leaving the object in an inconsistent state. An unprivileged local user can exploit this race to escalate privileges.
Title TOCTOU race in POSIX shared memory large page configuration
Weaknesses CWE-367
References
Weaknesses
  • CWE-367

    Time-of-check Time-of-use (TOCTOU) Race Condition

Sources

Status
PUBLISHED
Assigner
freebsd
Published
Updated
Aug 27, 2026, 3:57 AM
Reserved
Jun 29, 2026, 1:40 AM
Status
Analyzed
Published
Aug 26, 2026, 6:16 AM
Modified
Sep 24, 2026, 1:17 PM