Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. filelock
  4. ›
  5. CVE-2026-112906

CVE-2026-112906: filelock: SoftFileLock evicts a fresh lock file whose watched age another local user's pre-dated file passed on through inode reuse

October 23, 2026

SoftFileLock and MarkerSoftFileLock evict an unparsable marker (the lock file at <path>, whose presence says a process holds the lock) once a waiting contender has watched it unchanged for two seconds. SoftFileLease expires a lease the same way. The watch tells two looks apart by the marker’s modification time (mtime) and inode number (the kernel’s identity for a file, independent of its name) alone.

Another local user (the other user below) who can create files in the lock’s directory, a sticky /tmp included (the sticky bit is a directory flag that lets only a file’s owner remove it), parks an empty file of its own at the lock path. It dates that file to a future tick of the kernel’s coarse clock (a clock that advances in steps of 4 ms), lets the waiters of the user running the lock (the lock user below) watch it past two seconds, and unlinks it in that tick. On a filesystem that hands a freed inode number straight back (ext4, overlayfs on ext4) the lock user’s next marker repeats both values. It inherits the time spent watching the other user’s file, and a second waiter removes it while its owner holds the lock.

Two of the lock user’s processes then run the critical section together with no error. A SoftFileLease waiter takes a live lease that its owner wrote moments before, within milliseconds instead of after lease_duration. Affected versions: filelock >= 4.1.0 and <= 4.2.0 (finding ANT-2026-RKC48J5B).

References

  • github.com/advisories/GHSA-2g95-wg33-c5x2
  • github.com/tox-dev/filelock/commit/740ff666b62a88496c8d7394e4e6230605e4d62b
  • github.com/tox-dev/filelock/pull/843
  • github.com/tox-dev/filelock/releases/tag/4.2.1
  • github.com/tox-dev/filelock/security/advisories/GHSA-2g95-wg33-c5x2
  • nvd.nist.gov/vuln/detail/CVE-2026-112906

Code Behaviors & Features

Detect and mitigate CVE-2026-112906 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions starting from 4.1.0 before 4.2.1

Fixed versions

  • 4.2.1

Solution

Upgrade to version 4.2.1 or above.

Impact 4.7 MEDIUM

CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:H/A:N

Learn more about CVSS

Weakness

  • CWE-694: Use of Multiple Resources with Duplicate Identifier

Source file

pypi/filelock/CVE-2026-112906.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:16:18 +0000.