CVE-2026-22701
MediumCVSS 5.3Exploitation Probability (EPSS)
Low risk2th percentile - higher than 2% of all known CVEs
Summary
filelock for Python versions prior to 3.20.3 contain a TOCTOU race condition vulnerability in the SoftFileLock implementation. An attacker with local filesystem access and permission to create symlinks can exploit a race condition between permission validation and file creation to cause lock operations to fail or behave unexpectedly. This issue has been patched in version 3.20.3.
Risk Assessment
An attacker could cause the lock to operate on an unintended target file or lead to denial of service, potentially disrupting application operation.
Recommendation
Update filelock to version 3.20.3 or later.
Other vulnerabilities in filelock
See all- CVE-2026-144405Low
filelock versions 3.13.2 through 4.2.12 on Unix lock an existing file that may be owned by another local account in a sticky directory such as /tmp. That account can remove the file while the lock is held, allowing two processes to hold the same exclusive lock. The issue is fixed in version 4.2.12.
- CVE-2026-144404Low
filelock before 4.3.0 on Windows allows a process with read access to strict-lock claims to cause StrictSoftFileLock.release() to fail. A published claim can continue blocking later acquisitions after the reader closes its handle. The issue is fixed in version 4.3.0.
- CVE-2026-144403Low
filelock before 4.3.0 on POSIX allows a StrictSoftFileLock holder and a soft-lock client using the same path to both enter their critical sections if another account owns the sentinel in a shared sticky directory. This compromises mutual exclusion during mixed-client migration. The issue is fixed in version 4.3.0.
- CVE-2026-144395Medium
filelock before 4.3.0 on POSIX allows another account with rename access in a shared non-sticky lock directory to redirect a SQLite-backed ReadWriteLock operation to a file writable by the locking process. A cross-account overwrite was confirmed on Linux. The issue is fixed in version 4.3.0.
- CVE-2026-144394Low
filelock before 4.3.0 on Linux allows two processes to both hold a SoftReadWriteLock write lock after its protocol directory is removed while a lock instance remains alive. This requires another account able to replace directories in the shared location and filesystem reuse of a previously trusted inode number. The issue is fixed in version 4.3.0.
- CVE-2026-144393Low
filelock before 4.3.0 on POSIX allows SoftReadWriteLock to accept a protocol directory whose owner it trusts but whose permissions allow another account to write. In a shared sticky lock location, an account controlling such a directory can cause two processes to hold write locks concurrently without a compromise notification. The issue is fixed in version 4.3.0.
- CVE-2026-144392Low
filelock before 4.3.0 on Windows allows a local account with read access to an idle StrictSoftFileLock sentinel to delay acquisition beyond the requested timeout. A Windows opportunistic lock (oplock) on the sentinel can keep the caller's thread waiting inside the operating system, including during a nonblocking acquisition. The issue is fixed in version 4.3.0.
- CVE-2026-144391Low
In filelock before version 4.3.0 on POSIX, a new StrictSoftFileLock sentinel can inherit group or other write permission. An account with that access can modify the sentinel so that a SoftFileLock client enters the protected section while the strict lock remains held. This affects applications sharing a path between strict and legacy soft locks.
- CVE-2026-144389Low
In filelock before version 4.3.0 on Windows, a local account with read access to a stale soft-lock marker can delay recovery beyond the caller's acquisition timeout. This affects SoftFileLock, MarkerSoftFileLock and SoftFileLease when another process holds a read-handle opportunistic lock on the stale marker. The delay is caused by a Windows opportunistic lock (oplock).
- CVE-2026-144388Low
In filelock for Python prior to 4.3.0, on Unix, temporary-directory exhaustion during filelock import can disable a safeguard in StrictSoftFileLock publication. A local account with rename access to entries in a shared, non-sticky lock directory can gain read access to a file on the same filesystem.
Original NVD description (English source)
filelock is a platform-independent file lock for Python. Prior to version 3.20.3, a TOCTOU race condition vulnerability exists in the SoftFileLock implementation of the filelock package. An attacker with local filesystem access and permission to create symlinks can exploit a race condition between the permission validation and file creation to cause lock operations to fail or behave unexpectedly. The vulnerability occurs in the _acquire() method between raise_on_not_writable_file() (permission check) and os.open() (file creation). During this race window, an attacker can create a symlink at the lock file path, potentially causing the lock to operate on an unintended target file or leading to denial of service. This issue has been patched in version 3.20.3.
Vulnerability data from NVD (NIST) · CISA KEV · EPSS

