Description
filelock is a platform-independent file lock for Python. From 3.30.0 until 4.2.1, StrictSoftFileLock versions from 3.30.0 and SoftReadWriteLock versions from 4.0.0 can adopt a protocol directory created first by another local user in a shared parent directory, allowing that user to alter protocol state and admit concurrent holders. This issue is fixed in version 4.2.1.
Published: 2026-10-20
Score: 6.3 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Loss of mutual exclusion, potential data corruption
Action: Patch
AI Analysis

Impact

The vulnerability in the filelock library allows a local user who can create a directory in a shared parent directory before the lock is acquired to cause the StrictSoftFileLock and SoftReadWriteLock implementations to adopt that directory as their protocol datastore. This results in a loss of mutual exclusion, allowing multiple processes to hold the lock simultaneously. The flaw is a race condition reflected by CWE-283 and CWE-412 and potentially leads to data corruption or unexpected behavior in applications that rely on exclusive file locking.

Affected Systems

Affects the tox-dev/filelock package in versions 3.30.0 through 4.2.1 inclusive. These releases fail to sanitize or validate the location of the protocol directory, allowing an adversarial local user to interfere. The issue was first identified in 3.30.0 and fixed in 4.2.1. Users running earlier or affected versions should be aware that any concurrent access to the same lock path may be compromised.

Risk and Exploitability

The CVSS score of 6.3 indicates a medium severity. EPSS data is not available, and the vulnerability is not listed in the CISA KEV catalog, suggesting limited publicly known exploitation. The attack vector requires local access on the same system; an attacker would simply create a directory with the exact name before the lock is created. Once the lock adopts the outsider’s directory, another process can falsely acquire the lock, leading to race conditions. The exploitability is moderate to high for an insider or compromised process, but it does not enable remote code execution or privilege escalation.

Generated by OpenCVE AI on October 22, 2026 at 20:01 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade tox-dev/filelock to version 4.2.1 or later
  • Ensure that only trusted users can write to directories that may be used as lock protocol directories
  • If upgrade is not feasible immediately, configure the lock to use a dedicated directory within the application’s own data area rather than a shared location

Generated by OpenCVE AI on October 22, 2026 at 20:01 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-9c4x-gm8v-wgc4 filelock: StrictSoftFileLock and SoftReadWriteLock adopt a protocol directory another user created first, losing mutual exclusion
History

Wed, 28 Oct 2026 16:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

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


Wed, 21 Oct 2026 21:30:00 +0000

Type Values Removed Values Added
CPEs cpe:2.3:a:tox-dev:filelock:*:*:*:*:*:python:*:*

Wed, 21 Oct 2026 00:30:00 +0000

Type Values Removed Values Added
Weaknesses CWE-412
References
Metrics threat_severity

None

threat_severity

Moderate


Tue, 20 Oct 2026 16:45:00 +0000

Type Values Removed Values Added
First Time appeared Tox-dev
Tox-dev filelock
Vendors & Products Tox-dev
Tox-dev filelock

Tue, 20 Oct 2026 14:45:00 +0000

Type Values Removed Values Added
Description filelock is a platform-independent file lock for Python. From 3.30.0 until 4.2.1, StrictSoftFileLock versions from 3.30.0 and SoftReadWriteLock versions from 4.0.0 can adopt a protocol directory created first by another local user in a shared parent directory, allowing that user to alter protocol state and admit concurrent holders. This issue is fixed in version 4.2.1.
Title filelock: StrictSoftFileLock and SoftReadWriteLock adopt a protocol directory another user created first, losing mutual exclusion
Weaknesses CWE-283
References
Metrics cvssV3_1

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


Subscriptions

Tox-dev Filelock
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-28T15:09:43.507Z

Reserved: 2026-10-19T20:16:09.858Z

Link: CVE-2026-112911

cve-icon Vulnrichment

Updated: 2026-10-28T15:09:24.031Z

cve-icon NVD

Status : Modified

Published: 2026-10-20T15:17:15.473

Modified: 2026-10-28T16:17:02.690

Link: CVE-2026-112911

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-10-20T14:21:24Z

Links: CVE-2026-112911 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-22T20:15:09Z

Weaknesses
  • CWE-283

    Unverified Ownership

  • CWE-412

    Unrestricted Externally Accessible Lock