1
0
mirror of https://github.com/winfsp/winfsp.git synced 2026-06-24 21:42:33 -05:00
Commit Graph

3103 Commits

Author SHA1 Message Date
Bill Zissimopoulos 932e52769d Contributors: sort names 2026-06-23 15:27:31 +03:00
Bill Zissimopoulos 9d1b37f0f1 Merge pull request #672 from Maksim-Isakau/test-notify-rename-race
tst: notify_rename_race_test: repro notify/rename deadlock
2026-06-23 15:24:24 +03:00
Bill Zissimopoulos 169eb2c35d Merge pull request #669 from yeonsh/fix-notify-rename-selfdeadlock
sys: fix FileRenameResource self-deadlock between notify session and FspVolumeNotifyWork
2026-06-23 15:21:41 +03:00
Seunghoon Yeon 786b8e2707 Updated Contributors.asciidoc 2026-06-23 20:13:24 +09:00
Max Isakov 2669a86a8e Max Isakov - sign Contributor Agreement 2026-06-23 12:46:23 +02:00
Max Isakov f7b313313f tst: notify_rename_race_test: repro notify/rename deadlock 2026-06-21 09:50:03 +02:00
Bill Zissimopoulos bd8b54c469 sys: FspVolumeNotify: fix integer overflow vulnerability
This vulnerability was reported by:
- Tay Kiat Loong (GitHub: @owl4444)
- uhg (GitHub: @UltimateHG)
2026-06-13 16:41:35 +03:00
Bill Zissimopoulos bdab233e92 doc: add KeibiDrop to known file systems 2026-06-13 15:01:36 +03:00
Bill Zissimopoulos 1ad7d9935f doc: add KeibiDrop to known file systems 2026-06-13 14:59:27 +03:00
yeonsh 82f59837f6 sys: fix FileRenameResource self-deadlock between notify session and FspVolumeNotifyWork
Under heavy concurrent rename + change-notification load a volume can
deadlock permanently: all renames (exclusive) and opens (shared) on the
volume block, freezing the mount.

FspFileSystemNotifyBegin (FspVolumeNotifyLock) acquires the per-volume
FileRenameResource shared via an owner pointer (&VolumeNotifyCount) and
holds it for the whole Begin/End session. If a rename queues as an
exclusive waiter mid-session, the asynchronous FspVolumeNotifyWork then
re-acquires the same resource shared with ExAcquireResourceSharedLite.
Due to ERESOURCE writer-priority that shared acquire blocks behind the
queued exclusive waiter (the worker thread is not the owner -- the owner
is the &VolumeNotifyCount pointer). But that work item is the one that
must process FspFileSystemNotifyEnd to drop VolumeNotifyCount to 0 and
release the session, so it can never run: the session lock is never
released and the rename waits forever, while VolumeNotifyCount runs away
as Begin keeps incrementing it.

Acquire the rename resource in FspVolumeNotifyWork with
ExAcquireSharedStarveExclusive instead. The enclosing Begin/End session
already holds the resource shared and already defers renames until End,
so granting this redundant shared acquire ahead of the queued exclusive
waiter preserves name-stability semantics while breaking the deadlock. A
real exclusive holder still blocks the starve-exclusive acquire, so
correctness is unchanged.
2026-06-05 22:48:47 +09:00
Bill Zissimopoulos ff9e38c82d doc: add 9p-winfsp to known file systems 2026-05-31 21:34:09 +03:00
Bill Zissimopoulos 608e16761e tst: passthrough, passthrough-cpp: fix #662 2026-05-18 12:22:22 +03:00
Bill Zissimopoulos 0a89d2ecaf tools: make-release: add new signatures v2.2B1 2026-04-22 18:21:32 +03:00
Bill Zissimopoulos d9ffc24334 changelog: 2026 Beta1 2026-04-22 18:16:39 +03:00
Bill Zissimopoulos 624f285452 update source copyright for 2026 2026-03-04 15:54:27 +02:00
Bill Zissimopoulos 6ab7532d5b Merge branch 'pvt-np-nolaunch' 2026-03-04 15:25:53 +02:00
Bill Zissimopoulos cc533632a2 build: version 2026 Beta1 2026-03-04 15:23:14 +02:00
Bill Zissimopoulos 8b1e2d3020 build,tools: updates for new EV cert 2026-03-04 15:16:54 +02:00
Bill Zissimopoulos 7f82326454 sys: FspFastIoDeviceControl: add a couple of fixes
- Check that the operation succeeded prior to copying to the output buffer.
- Avoid information leaks by only copying what is necessary to the output
buffer (suggestion by Tay Kiat Loong).
2026-02-17 20:48:01 +02:00
Bill Zissimopoulos 13d306f586 sys: FspFastIoDeviceControl: check input/output buffer lengths 2026-02-17 17:07:28 +02:00
Bill Zissimopoulos ae40f0edb1 sys: FspFastIoDeviceControl: fix exploit reported by Tay Kiat Loong
The WinFsp "transact" protocol is used by user mode file systems to interface
with the FSD. This protocol works via the DeviceIoControl API and uses the
FSP_IOCTL_TRANSACT control code. The FSP_IOCTL_TRANSACT code is marked as
METHOD_BUFFERED.

When the DeviceIoControl call is forwarded as an IRP, the METHOD_BUFFERED flag
instructs the kernel to copy user mode buffers to kernel mode buffers (and
vice-versa). However when the DeviceIoControl call is forwarded via the FastIO
mechanism the METHOD_BUFFERED flag is ignored. This means that when WinFsp
added support for DeviceIoControl FastIO, the FSD started accessing user mode
buffers directly.

This means that a malicious file system could attempt exploits like changing
or freeing a buffer while the FSD is reading it. Tay Kiat Loong developed a
POC exploit which demonstrated this vulnerability.

This commit fixes the problem by patching FspFastIoDeviceControl to add the
missing METHOD_BUFFERED handling.
2026-02-17 15:21:35 +02:00
Bill Zissimopoulos aed8bb745f Merge pull request #648 from chenjie4255/add_write_ea_perm
dll & fuse: Added "AddWriteEaPerm" mount option.
2026-02-05 12:07:23 +02:00
ethan 4dbea1f298 dll & fuse: Added "AddWriteEaPerm" mount option. 2026-02-05 12:09:19 +08:00
Bill Zissimopoulos f021496302 np: NPAddConnection: support file systems not managed by the launcher 2026-02-03 21:03:04 +02:00
Bill Zissimopoulos 2aa682ffa1 Merge pull request #626 from chenjie4255/directio
dll: add support for disabling directio.
2025-12-24 11:18:13 +00:00
ethan ccd75d7c47 remove outdated comments 2025-12-24 09:28:37 +08:00
ethan fbbb4c3de1 dll: add fuse directio flag support 2025-12-23 17:05:48 +08:00
Bill Zissimopoulos 4045ce2d19 Merge pull request #625 from tomgr/doc-add-buildbarn
doc: add bb-remote-execution to known file systems
2025-08-21 15:32:40 +03:00
Thomas Gibson-Robinson 5d8c692845 doc: add bb-remote-execution to known file systems 2025-08-20 09:55:16 +01:00
Bill Zissimopoulos 5b429bc445 Merge pull request #614 from chenjie4255/flush_on_cleanup
dll: Added FlushOnCleanup fuse param
2025-08-07 16:55:11 +03:00
Bill Zissimopoulos facd4bb9c4 Merge pull request #613 from chenjie4255/patch-1
Update Contributors.asciidoc
2025-08-07 16:54:31 +03:00
ethan e4ceb9010b moved FlushOnCleanup from VolumeParam to struct fuse 2025-08-07 15:30:07 +08:00
Bill Zissimopoulos d6444da2ef Merge pull request #617 from coderall2/fix_path_convert_bug
Fix: fix FspPosixMapPosixToWindowsPathEx pointer misuse
2025-08-06 18:19:19 +03:00
coderall2 b088221c82 Update Contributors.asciidoc with real name 2025-08-06 10:19:17 +08:00
coderall2 8f01618fad Update Contributors.asciidoc 2025-07-02 13:43:55 +08:00
coderall2 7e861c30ac Fix: fix FspPosixMapPosixToWindowsPathEx pointer misuse 2025-07-02 13:30:12 +08:00
ethan 1e5455653d Added "Ethan Chan" to the Contributors.asciidoc 2025-06-20 15:03:58 +08:00
ethan c8e182e1d4 sys & dll: Added FlushOnCleanup volume param 2025-06-20 14:56:01 +08:00
Bill Zissimopoulos ddca7bd548 sys: driver.inf: PnpLockdown=1 v2.1 2025-06-05 16:02:43 +01:00
Bill Zissimopoulos d3700d3593 build: version: 2025 2025-05-15 20:35:01 +01:00
Bill Zissimopoulos c8366af48c update source copyright for 2025 2025-05-15 20:33:31 +01:00
Bill Zissimopoulos 44c621c0de changelog: 2025 2025-05-15 20:23:06 +01:00
Bill Zissimopoulos a2cd6978be sys: CcDeferWrite fix 2025-05-15 12:46:00 +01:00
Bill Zissimopoulos d75e9f7ee6 sys: oplock fix 2025-05-08 21:47:06 +01:00
Bill Zissimopoulos 6803bb4136 tools: build.bat: fix target SDK for AppVeyor 2025-04-25 20:18:21 +01:00
Bill Zissimopoulos fb14262e43 build: support VS2019 builds and also latest SDK/WDK builds 2025-04-25 19:51:21 +01:00
Bill Zissimopoulos 4fdec4d37f sys: FspFsvolCreate, FspFsvolSetSecurity: absolute security descriptors
Some third party filters send us security descriptors in absolute rather
than self-relative format. Handle this case by converting them to self-
relative format ourselves.
2024-10-10 12:34:04 +01:00
Bill Zissimopoulos 2da97d48f5 tools: make-release: add new signatures v2.1B2 2024-09-11 14:48:55 +01:00
Bill Zissimopoulos 7c5dc48414 build: version: 2024 Beta2 2024-09-11 14:46:38 +01:00
Bill Zissimopoulos 93c057571a changelog: 2024 Beta2 2024-09-11 13:23:41 +01:00