Use of Multiple Resources with Duplicate Identifier Affecting filelock package, versions [4.1.0,4.2.1)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.21% (10th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PYTHON-FILELOCK-21280749
  • published20 Oct 2026
  • disclosed20 Oct 2026
  • creditAnthropic's OSS Scanner

Introduced: 20 Oct 2026

NewCVE-2026-112906  (opens in a new tab)
CWE-694  (opens in a new tab)

How to fix?

Upgrade filelock to version 4.2.1 or higher.

Overview

Affected versions of this package are vulnerable to Use of Multiple Resources with Duplicate Identifier via _try_break_expired_lock and _try_break_stale_lock in _api.py and _lease.py, where an attacker with write access to the lock directory can replace a held lock file with a symlink pointing at an older file. This causes stat() to report the target's stale mtime, tricking a waiting process into breaking a live lock and allowing two processes to hold the lock simultaneously, resulting in a loss of mutual exclusion and potential data integrity compromise. The fix pins the inode before reading the marker to detect such replacements before acting on them.

CVSS Base Scores

version 4.0
version 3.1