Loading0%
SUBZER0
LIVE
Alerts

CVE-2026-112940

filelock ReadWriteLock: SQLite reopens the lock database by name, so a planted symlink or journal file makes the lock user's process overwrite or unlink its own files

Archived. This CVE has left SubZer0's live 30-day window. Signals below are as of 2026-11-22; check the references for anything newer.

  • Severity: High
  • CVSS 7.1
  • EPSS 0.19%
  • Public exploit
  • P2 · This week

Why P2: this week.

Description

`ReadWriteLock` and `AsyncReadWriteLock` (the SQLite-backed reader/writer lock) hand SQLite a name they do not control. On Linux the lock validates its database through a descriptor (the number the kernel gives a process for an open file). It then connects SQLite to `/proc/self/fd/<n>`, a Linux path that names the process's own open file `n`. SQLite turns that path back into a plain path and reopens it by name, following symlinks (a symlink is a file that points at another path). On every POSIX route SQLite also acts on `-journal`, `-wal` and `-shm` files it finds beside that name. Those are SQLite's side files: the rollback journal (pages saved to undo an interrupted write), the write-ahead log or WAL (changes kept outside the main file), and the shared-memory index for the WAL. Another local user who can create or rename entries in the directory that holds the lock database can turn this against the user running the lock (below: the lock user). Such a directory is a `0777` or group-writable cache, build or project directory without the sticky bit (a directory flag that lets only a file's owner remove or rename it). That other user can make the lock user's ordinary `read_lock()` or `write_lock()` write bytes of the other user's choosing into the lock user's own files. The same position lets the other user make that call create or unlink files of the lock user, admit a reader beside a writer, or kill the holder. All of this runs with the lock user's privileges. In a sticky …

Affected products

  • pip filelock >= 3.20.4, <= 4.2.0; first patched: 4.2.1

References

Browse more

PyPI (pip) packagesWeek 43, 2026 recap

Published 2026-10-20 · sources: GitHub Advisory Database