CVE Explorer
CVE-2025-68146
filelock is a platform-independent file lock for Python. In versions prior to 3.20.1, a Time-of-Check-Time-of-Use (TOCTOU) race condition allows local attackers to corrupt or truncate arbitrary user files through symlink attacks. The vulnerability exists in both Unix and Windows lock file creation where filelock checks if a file exists before opening it with O_TRUNC. An attacker can create a symlink pointing to a victim file in the time gap between the check and open, causing os.open() to follow
Known exploited
Not asserted
Disputed
No
Stale source
No
Conflicts
1
Preserved source conflicts
No provider value was silently selected as the winner.
cwe · 3 assertions
{"cweId":"CWE-367","description":"CWE-367: Time-of-check Time-of-use (TOCTOU) Race Condition","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/0/descriptions/0
{"cweId":"CWE-362","description":"CWE-362: Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/2/descriptions/0
{"cweId":"CWE-59","description":"CWE-59: Improper Link Resolution Before File Access ('Link Following')","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/1/descriptions/0
Affected products and versions
1 source assertion{"product":"filelock","vendor":"tox-dev","versions":[{"status":"affected","version":"< 3.20.1"}]}
- cve_program_cvelist_v5affectedurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/affected/0
Provider-owned CVSS observations
1 source assertion{"metric":{"attackComplexity":"HIGH","attackVector":"LOCAL","availabilityImpact":"HIGH","baseScore":6.3,"baseSeverity":"MEDIUM","confidentialityImpact":"NONE","integrityImpact":"HIGH","privilegesRequired":"LOW","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:H/A:H","version":"3.1"},"metric_type":"cvssV3_1"}
- cve_program_cvelist_v5cvssurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/metrics/0/cvssV3_1
CWE assertions
3 source assertions{"cweId":"CWE-367","description":"CWE-367: Time-of-check Time-of-use (TOCTOU) Race Condition","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/0/descriptions/0
{"cweId":"CWE-362","description":"CWE-362: Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/2/descriptions/0
{"cweId":"CWE-59","description":"CWE-59: Improper Link Resolution Before File Access ('Link Following')","lang":"en","type":"CWE"}
- cve_program_cvelist_v5cweurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/problemTypes/1/descriptions/0
Source references
4 source assertions{"name":"https://github.com/tox-dev/filelock/commit/4724d7f8c3393ec1f048c93933e6e3e6ec321f0e","tags":["x_refsource_MISC"],"url":"https://github.com/tox-dev/filelock/commit/4724d7f8c3393ec1f048c93933e6e3e6ec321f0e"}
- cve_program_cvelist_v5referenceurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/references/2
{"name":"https://github.com/tox-dev/filelock/pull/461","tags":["x_refsource_MISC"],"url":"https://github.com/tox-dev/filelock/pull/461"}
- cve_program_cvelist_v5referenceurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/references/1
{"name":"https://github.com/tox-dev/filelock/releases/tag/3.20.1","tags":["x_refsource_MISC"],"url":"https://github.com/tox-dev/filelock/releases/tag/3.20.1"}
- cve_program_cvelist_v5referenceurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/references/3
{"name":"https://github.com/tox-dev/filelock/security/advisories/GHSA-w853-jp5j-5j7f","tags":["x_refsource_CONFIRM"],"url":"https://github.com/tox-dev/filelock/security/advisories/GHSA-w853-jp5j-5j7f"}
- cve_program_cvelist_v5referenceurn:baitaphish:normalized-source-record:v2:3a8399c822818b68ca644a0d4bc3373ac4b4af74850da8d9d671c175f0953e5e · sha256:af7f27cf803aaac5… · /containers/cna/references/0
Attribution and limitations
- CVE Program CVEList V5: Reproduce the MITRE copyright designation and CVE license in copies. Source →
Provider severity values are preserved separately. Baitaphish does not convert them into a risk rating, infer affected products, or treat EPSS as observed exploitation.