Description
Data::Intern::Shared versions before 0.02 for Perl create a world-readable mmap backing file and open it without O_EXCL or O_NOFOLLOW.

The segment is created in intern.h with open(path, O_RDWR|O_CREAT, 0666). The mode is 0666, so under the default umask 022 the file is created mode 0644 (world-readable). O_NOFOLLOW is absent, so a symlink planted at the path is followed, and O_EXCL is absent, so the open silently uses a pre-planted file instead of failing.

A "Shared" segment naturally lives in a shared directory such as /tmp or /dev/shm, where any local user can read the IPC payloads stored in the world-readable segment, and a pre-planted file or symlink at the path lets a local attacker win a pre-creation race or redirect the open.
Published: 2026-07-21
Score: 3.8 Low
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Data::Intern::Shared versions before 0.02 open an mmap backing file with open(path, O_RDWR|O_CREAT, 0666). Under the normal umask of 022 this results in a 0644 world‑readable file. The call also omits O_NOFOLLOW and O_EXCL, so a symlink or pre‑existing file at the expected path is followed or silently reused. The module therefore creates a shared memory area backed by a world‑readable file in a common shared directory such as /tmp or /dev/shm, letting local users read or tamper with any IPC payload stored there. This constitutes an insecure file‑creation weakness (CWE‑732) and a symlink‑based path traversal (CWE‑59).

Affected Systems

The vulnerability affects installations of the Perl distribution EGOR:Data::Intern::Shared, specifically any version earlier than 0.02. Systems that use the module in shared directories such as /tmp or /dev/shm are at risk, as these directories are normally accessible to all local users and are the default locations for the mmap backing file.

Risk and Exploitability

The CVSS score is 3.8 and the EPSS indicates a very low exploitation probability (<1 %). This vulnerability is not listed in CISA’s KEV catalog. The attack vector is local; a user with write access to a shared directory such as /tmp or /dev/shm can create or pre‑plant a symlink or file at the expected path. Because the module uses O_NOFOLLOW and O_EXCL incorrectly, the open silently follows the symlink or reuses the pre‑existing file, creating a race that can be exploited. A victim local user can then read or overwrite the world‑readable backing file, gaining access to IPC payloads or altering program behavior. While the risk remains confined to local users, the race condition and lack of exclusive creation make exploitation easier than in a model that enforced O_EXCL.

Generated by OpenCVE AI on August 3, 2026 at 00:24 UTC.

Remediation

Vendor Solution

Upgrade to Data::Intern::Shared 0.02 or later, which creates the backing file mode 0600 (owner-only) with O_EXCL and O_NOFOLLOW.


Vendor Workaround

For deployments that cannot upgrade to 0.02, set a restrictive umask so the backing file is not world-readable and place it in a directory only the owning user can access.


OpenCVE Recommended Actions

  • Upgrade Data::Intern::Shared to version 0.02 or newer, which sets the backing file mode to 0600 and uses O_EXCL and O_NOFOLLOW.
  • If an upgrade is not immediately possible, configure a restrictive umask (e.g., 077) and place the module’s backing files in a directory that only the owning user can read or write.
  • Ensure that the shared directory used by the module is not accessible to untrusted local users, or consider mounting it with noexec or other restrictive options.

Generated by OpenCVE AI on August 3, 2026 at 00:24 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 23 Jul 2026 21:45:00 +0000

Type Values Removed Values Added
First Time appeared Egor
Egor data::intern::shared
Vendors & Products Egor
Egor data::intern::shared

Thu, 23 Jul 2026 14:30:00 +0000

Type Values Removed Values Added
Metrics cvssV3_1

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

ssvc

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


Tue, 21 Jul 2026 19:45:00 +0000

Type Values Removed Values Added
Description Data::Intern::Shared versions before 0.02 for Perl create a world-readable mmap backing file and open it without O_EXCL or O_NOFOLLOW. The segment is created in intern.h with open(path, O_RDWR|O_CREAT, 0666). The mode is 0666, so under the default umask 022 the file is created mode 0644 (world-readable). O_NOFOLLOW is absent, so a symlink planted at the path is followed, and O_EXCL is absent, so the open silently uses a pre-planted file instead of failing. A "Shared" segment naturally lives in a shared directory such as /tmp or /dev/shm, where any local user can read the IPC payloads stored in the world-readable segment, and a pre-planted file or symlink at the path lets a local attacker win a pre-creation race or redirect the open.
Title Data::Intern::Shared versions before 0.02 for Perl create a world-readable mmap backing file and open it without O_EXCL or O_NOFOLLOW
Weaknesses CWE-59
CWE-732
References

Subscriptions

Egor Data::intern::shared
cve-icon MITRE

Status: PUBLISHED

Assigner: CPANSec

Published:

Updated: 2026-07-23T13:16:50.281Z

Reserved: 2026-07-21T15:29:37.116Z

Link: CVE-2026-65067

cve-icon Vulnrichment

Updated: 2026-07-23T13:15:29.500Z

cve-icon NVD

Status : Deferred

Published: 2026-07-21T20:17:05.733

Modified: 2026-07-23T14:17:45.720

Link: CVE-2026-65067

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-03T00:30:16Z

Weaknesses
  • CWE-59

    Improper Link Resolution Before File Access ('Link Following')

  • CWE-732

    Incorrect Permission Assignment for Critical Resource